Google.Protobuf.ProtoPreconditions

Helper methods for throwing exceptions when preconditions are not met.

Summary

This class is used internally and by generated code; it is not particularly expected to be used from application code, although nothing prevents it from being used that way.

Public static functions

CheckNotNull< T >(T value, string name)
T
Throws an ArgumentNullException if the given value is null, otherwise return the value to the caller.

Public static functions

CheckNotNull< T >

T CheckNotNull< T >(
  T value,
  string name
)

Throws an ArgumentNullException if the given value is null, otherwise return the value to the caller.