summaryrefslogtreecommitdiff
path: root/src/mscorlib/src/System/IO/__Error.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/mscorlib/src/System/IO/__Error.cs')
-rw-r--r--src/mscorlib/src/System/IO/__Error.cs28
1 files changed, 0 insertions, 28 deletions
diff --git a/src/mscorlib/src/System/IO/__Error.cs b/src/mscorlib/src/System/IO/__Error.cs
index ad4972d..955ddbe 100644
--- a/src/mscorlib/src/System/IO/__Error.cs
+++ b/src/mscorlib/src/System/IO/__Error.cs
@@ -21,7 +21,6 @@ using Win32Native = Microsoft.Win32.Win32Native;
using System.Text;
using System.Globalization;
using System.Security;
-using System.Security.Permissions;
using System.Diagnostics.Contracts;
namespace System.IO {
@@ -51,10 +50,6 @@ namespace System.IO {
internal static void ReadNotSupported() {
throw new NotSupportedException(Environment.GetResourceString("NotSupported_UnreadableStream"));
}
-
- internal static void SeekNotSupported() {
- throw new NotSupportedException(Environment.GetResourceString("NotSupported_UnseekableStream"));
- }
internal static void WrongAsyncResult() {
throw new ArgumentException(Environment.GetResourceString("Arg_WrongAsyncResult"));
@@ -187,34 +182,11 @@ namespace System.IO {
throw new IOException(Win32Native.GetMessage(errorCode), Win32Native.MakeHRFromErrorCode(errorCode), maybeFullPath);
}
}
-
- // An alternative to WinIOError with friendlier messages for drives
- internal static void WinIODriveError(String driveName) {
- int errorCode = Marshal.GetLastWin32Error();
- WinIODriveError(driveName, errorCode);
- }
-
- internal static void WinIODriveError(String driveName, int errorCode)
- {
- switch (errorCode) {
- case Win32Native.ERROR_PATH_NOT_FOUND:
- case Win32Native.ERROR_INVALID_DRIVE:
- throw new DriveNotFoundException(Environment.GetResourceString("IO.DriveNotFound_Drive", driveName));
-
- default:
- WinIOError(errorCode, driveName);
- break;
- }
- }
internal static void WriteNotSupported() {
throw new NotSupportedException(Environment.GetResourceString("NotSupported_UnwritableStream"));
}
- internal static void WriterClosed() {
- throw new ObjectDisposedException(null, Environment.GetResourceString("ObjectDisposed_WriterClosed"));
- }
-
// From WinError.h
internal const int ERROR_FILE_NOT_FOUND = Win32Native.ERROR_FILE_NOT_FOUND;
internal const int ERROR_PATH_NOT_FOUND = Win32Native.ERROR_PATH_NOT_FOUND;