3 // Copyright (c) Microsoft Corporation. All rights reserved.
6 /*============================================================
8 ** Class: EndOfStreamException
10 ** <OWNER>Microsoft</OWNER>
13 ** Purpose: Exception to be thrown when reading past end-of-file.
16 ===========================================================*/
19 using System
.Runtime
.Serialization
;
23 [System
.Runtime
.InteropServices
.ComVisible(true)]
24 public class EndOfStreamException
: IOException
26 public EndOfStreamException()
27 : base(Environment
.GetResourceString("Arg_EndOfStreamException")) {
28 SetErrorCode(__HResults
.COR_E_ENDOFSTREAM
);
31 public EndOfStreamException(String message
)
33 SetErrorCode(__HResults
.COR_E_ENDOFSTREAM
);
36 public EndOfStreamException(String message
, Exception innerException
)
37 : base(message
, innerException
) {
38 SetErrorCode(__HResults
.COR_E_ENDOFSTREAM
);
41 protected EndOfStreamException(SerializationInfo info
, StreamingContext context
) : base (info
, context
) {