aboutsummaryrefslogtreecommitdiffhomepage
path: root/csharp/src/ProtocolBuffers/ThrowHelper.cs
diff options
context:
space:
mode:
Diffstat (limited to 'csharp/src/ProtocolBuffers/ThrowHelper.cs')
-rw-r--r--csharp/src/ProtocolBuffers/ThrowHelper.cs17
1 files changed, 4 insertions, 13 deletions
diff --git a/csharp/src/ProtocolBuffers/ThrowHelper.cs b/csharp/src/ProtocolBuffers/ThrowHelper.cs
index 097b5032..c12a48a3 100644
--- a/csharp/src/ProtocolBuffers/ThrowHelper.cs
+++ b/csharp/src/ProtocolBuffers/ThrowHelper.cs
@@ -42,12 +42,12 @@ namespace Google.Protobuf
/// <summary>
/// Helper methods for throwing exceptions
/// </summary>
- public static class ThrowHelper
+ internal static class ThrowHelper
{
/// <summary>
/// Throws an ArgumentNullException if the given value is null.
/// </summary>
- public static void ThrowIfNull(object value, string name)
+ internal static void ThrowIfNull(object value, string name)
{
if (value == null)
{
@@ -58,7 +58,7 @@ namespace Google.Protobuf
/// <summary>
/// Throws an ArgumentNullException if the given value is null.
/// </summary>
- public static void ThrowIfNull(object value)
+ internal static void ThrowIfNull(object value)
{
if (value == null)
{
@@ -69,7 +69,7 @@ namespace Google.Protobuf
/// <summary>
/// Throws an ArgumentNullException if the given value or any element within it is null.
/// </summary>
- public static void ThrowIfAnyNull<T>(IEnumerable<T> sequence)
+ internal static void ThrowIfAnyNull<T>(IEnumerable<T> sequence)
{
foreach (T t in sequence)
{
@@ -79,14 +79,5 @@ namespace Google.Protobuf
}
}
}
-
- public static Exception CreateMissingMethod(Type type, string methodName)
- {
-#if CLIENTPROFILE
- return new System.MissingMethodException(type.FullName, methodName);
-#else
- return new System.ArgumentException(String.Format("The method '{0}' was not found on type {1}.", methodName, type));
-#endif
- }
}
} \ No newline at end of file