Show / Hide Table of Contents

    Class BindServiceMethodAttribute

    Specifies the location of the service bind method for a gRPC service. The bind method is typically generated code and is used to register a service's methods with the server on startup.

    The bind method signature takes a ServiceBinderBase and an optional instance of the service base class, e.g. static void BindService(ServiceBinderBase, GreeterService).

    Inheritance
    Attribute
    BindServiceMethodAttribute
    Namespace: Grpc.Core
    Assembly: Grpc.Core.Api.dll
    Syntax
    public class BindServiceMethodAttribute : Attribute

    Constructors

    BindServiceMethodAttribute(Type, String)

    Initializes a new instance of the BindServiceMethodAttribute class.

    Declaration
    public BindServiceMethodAttribute(Type bindType, string bindMethodName)
    Parameters
    Type Name Description
    Type bindType

    The type the service bind method is defined on.

    System.String bindMethodName

    The name of the service bind method.

    Properties

    BindMethodName

    Gets the name of the service bind method.

    Declaration
    public string BindMethodName { get; }
    Property Value
    Type Description
    System.String

    BindType

    Gets the type the service bind method is defined on.

    Declaration
    public Type BindType { get; }
    Property Value
    Type Description
    Type
    Back to top Generated by DocFX