Reads header from stream and stores to the specified storeStream.

C# | Visual Basic | Visual C++ | F# |
public int ReadHeader( Stream storeStream, int maxCount, SizeExceededAction exceededAction )
Public Function ReadHeader ( storeStream As Stream, maxCount As Integer, exceededAction As SizeExceededAction ) As Integer
public: int ReadHeader( Stream^ storeStream, int maxCount, SizeExceededAction exceededAction )
member ReadHeader : storeStream : Stream * maxCount : int * exceededAction : SizeExceededAction -> int

- storeStream (Stream)
- Stream where to store readed header.
- maxCount (Int32)
- Maximum number of bytes to read. Value 0 means not limited.
- exceededAction (SizeExceededAction)
- Specifies action what is done if maxCount number of bytes has exceeded.

Int32
Returns how many bytes readed from source stream.
Returns how many bytes readed from source stream.

Exception | Condition |
---|---|
ObjectDisposedException | Is raised when this object is disposed and this method is accessed. |
ArgumentNullException | Is raised when storeStream is null. |
ArgumentException | Is raised when any of the arguments has invalid value. |
LineSizeExceededException | Is raised when source stream has too big line. |
DataSizeExceededException | Is raised when reading exceeds maxCount specified value. |
IncompleteDataException | Is raised when source stream closed before header-terminator reached. |
Assembly: LumiSoft.Net (Module: LumiSoft.Net.dll) Version: 4.5.5510.19119