Beispiel #1
0
 internal static void ThrowArgumentException(ExceptionResource resource, ExceptionArgument argument)
 {
     throw new ArgumentException(MyEnvironment.GetResourceString(GetResourceName(resource)), GetArgumentName(argument));
 }
Beispiel #2
0
 internal static void ThrowWrongKeyTypeArgumentException(object key, Type targetType)
 {
     throw new ArgumentException(MyEnvironment.GetResourceString("Arg_WrongType", key, targetType), "key");
 }
Beispiel #3
0
 internal static void ThrowWrongValueTypeArgumentException(object value, Type targetType)
 {
     throw new ArgumentException(MyEnvironment.GetResourceString("Arg_WrongType", value, targetType), "value");
 }
Beispiel #4
0
 internal static void ThrowObjectDisposedException(string objectName, ExceptionResource resource)
 {
     throw new ObjectDisposedException(objectName, MyEnvironment.GetResourceString(GetResourceName(resource)));
 }
Beispiel #5
0
 internal static void ThrowUnauthorizedAccessException(ExceptionResource resource)
 {
     throw new UnauthorizedAccessException(MyEnvironment.GetResourceString(GetResourceName(resource)));
 }
Beispiel #6
0
 internal static void ThrowNotSupportedException(ExceptionResource resource)
 {
     throw new NotSupportedException(MyEnvironment.GetResourceString(GetResourceName(resource)));
 }
Beispiel #7
0
 internal static void ThrowSecurityException(ExceptionResource resource)
 {
     throw new SecurityException(MyEnvironment.GetResourceString(GetResourceName(resource)));
 }
Beispiel #8
0
 internal static void ThrowInvalidOperationException(ExceptionResource resource)
 {
     throw new InvalidOperationException(MyEnvironment.GetResourceString(GetResourceName(resource)));
 }