Class MethodDescriptor
Describes a single method in a service.
Implements
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: Google.Protobuf.Reflection
Assembly: Google.Protobuf.dll
Syntax
public sealed class MethodDescriptor : DescriptorBase, IDescriptor
Properties
CustomOptions
The (possibly empty) set of custom options for this method.
Declaration
[Obsolete("CustomOptions are obsolete. Use GetOption")]
public CustomOptions CustomOptions { get; }
Property Value
Type | Description |
---|---|
CustomOptions |
InputType
Declaration
public MessageDescriptor InputType { get; }
Property Value
Type | Description |
---|---|
MessageDescriptor | The method's input type. |
IsClientStreaming
Declaration
public bool IsClientStreaming { get; }
Property Value
Type | Description |
---|---|
System.Boolean | Indicates if client streams multiple requests. |
IsServerStreaming
Declaration
public bool IsServerStreaming { get; }
Property Value
Type | Description |
---|---|
System.Boolean | Indicates if server streams multiple responses. |
Name
The brief name of the descriptor's target.
Declaration
public override string Name { get; }
Property Value
Type | Description |
---|---|
System.String |
Overrides
OutputType
Declaration
public MessageDescriptor OutputType { get; }
Property Value
Type | Description |
---|---|
MessageDescriptor | The method's input type. |
Service
Declaration
public ServiceDescriptor Service { get; }
Property Value
Type | Description |
---|---|
ServiceDescriptor | The service this method belongs to. |
Methods
GetOption<T>(Extension<MethodOptions, T>)
Gets a single value method option for this descriptor
Declaration
public T GetOption<T>(Extension<MethodOptions, T> extension)
Parameters
Type | Name | Description |
---|---|---|
Extension<MethodOptions, T> | extension |
Returns
Type | Description |
---|---|
T |
Type Parameters
Name | Description |
---|---|
T |
GetOption<T>(RepeatedExtension<MethodOptions, T>)
Gets a repeated value method option for this descriptor
Declaration
public RepeatedField<T> GetOption<T>(RepeatedExtension<MethodOptions, T> extension)
Parameters
Type | Name | Description |
---|---|---|
RepeatedExtension<MethodOptions, T> | extension |
Returns
Type | Description |
---|---|
RepeatedField<T> |
Type Parameters
Name | Description |
---|---|
T |