Documentation ¶
Index ¶
- Variables
- func RegisterApprouvezServer(s grpc.ServiceRegistrar, srv ApprouvezServer)
- type ApprouvezClient
- type ApprouvezServer
- type Approuvez_CreateStreamClient
- type Approuvez_CreateStreamServer
- type Empty
- type Session
- type SlackUser
- func (*SlackUser) Descriptor() ([]byte, []int)deprecated
- func (x *SlackUser) GetEmail() string
- func (x *SlackUser) GetId() string
- func (x *SlackUser) GetName() string
- func (*SlackUser) ProtoMessage()
- func (x *SlackUser) ProtoReflect() protoreflect.Message
- func (x *SlackUser) Reset()
- func (x *SlackUser) String() string
- type SlackUserRequest
- func (*SlackUserRequest) Descriptor() ([]byte, []int)deprecated
- func (x *SlackUserRequest) GetLinkName() string
- func (x *SlackUserRequest) GetLinkUrl() string
- func (x *SlackUserRequest) GetMessage() string
- func (x *SlackUserRequest) GetSession() *Session
- func (x *SlackUserRequest) GetUser() string
- func (*SlackUserRequest) ProtoMessage()
- func (x *SlackUserRequest) ProtoReflect() protoreflect.Message
- func (x *SlackUserRequest) Reset()
- func (x *SlackUserRequest) String() string
- type SlackUserResponse
- func (*SlackUserResponse) Descriptor() ([]byte, []int)deprecated
- func (x *SlackUserResponse) GetDecision() SlackUserResponse_Decision
- func (x *SlackUserResponse) GetUser() *SlackUser
- func (*SlackUserResponse) ProtoMessage()
- func (x *SlackUserResponse) ProtoReflect() protoreflect.Message
- func (x *SlackUserResponse) Reset()
- func (x *SlackUserResponse) String() string
- type SlackUserResponse_Decision
- func (SlackUserResponse_Decision) Descriptor() protoreflect.EnumDescriptor
- func (x SlackUserResponse_Decision) Enum() *SlackUserResponse_Decision
- func (SlackUserResponse_Decision) EnumDescriptor() ([]byte, []int)deprecated
- func (x SlackUserResponse_Decision) Number() protoreflect.EnumNumber
- func (x SlackUserResponse_Decision) String() string
- func (SlackUserResponse_Decision) Type() protoreflect.EnumType
- type UnimplementedApprouvezServer
- type UnsafeApprouvezServer
Constants ¶
This section is empty.
Variables ¶
var ( SlackUserResponse_Decision_name = map[int32]string{ 0: "DENY", 1: "APPROVE", } SlackUserResponse_Decision_value = map[string]int32{ "DENY": 0, "APPROVE": 1, } )
Enum value maps for SlackUserResponse_Decision.
var Approuvez_ServiceDesc = grpc.ServiceDesc{ ServiceName: "approuvez.Approuvez", HandlerType: (*ApprouvezServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "NewSession", Handler: _Approuvez_NewSession_Handler, }, }, Streams: []grpc.StreamDesc{ { StreamName: "CreateStream", Handler: _Approuvez_CreateStream_Handler, ServerStreams: true, }, }, Metadata: "pkg/protobuf/approuvez.proto", }
Approuvez_ServiceDesc is the grpc.ServiceDesc for Approuvez service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var File_pkg_protobuf_approuvez_proto protoreflect.FileDescriptor
Functions ¶
func RegisterApprouvezServer ¶
func RegisterApprouvezServer(s grpc.ServiceRegistrar, srv ApprouvezServer)
Types ¶
type ApprouvezClient ¶
type ApprouvezClient interface { NewSession(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Session, error) CreateStream(ctx context.Context, in *SlackUserRequest, opts ...grpc.CallOption) (Approuvez_CreateStreamClient, error) }
ApprouvezClient is the client API for Approuvez service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewApprouvezClient ¶
func NewApprouvezClient(cc grpc.ClientConnInterface) ApprouvezClient
type ApprouvezServer ¶
type ApprouvezServer interface { NewSession(context.Context, *Empty) (*Session, error) CreateStream(*SlackUserRequest, Approuvez_CreateStreamServer) error // contains filtered or unexported methods }
ApprouvezServer is the server API for Approuvez service. All implementations must embed UnimplementedApprouvezServer for forward compatibility
type Approuvez_CreateStreamClient ¶
type Approuvez_CreateStreamClient interface { Recv() (*SlackUserResponse, error) grpc.ClientStream }
type Approuvez_CreateStreamServer ¶
type Approuvez_CreateStreamServer interface { Send(*SlackUserResponse) error grpc.ServerStream }
type Empty ¶
type Empty struct {
// contains filtered or unexported fields
}
func (*Empty) Descriptor
deprecated
func (*Empty) ProtoMessage ¶
func (*Empty) ProtoMessage()
func (*Empty) ProtoReflect ¶
func (x *Empty) ProtoReflect() protoreflect.Message
type Session ¶
type Session struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*Session) Descriptor
deprecated
func (*Session) ProtoMessage ¶
func (*Session) ProtoMessage()
func (*Session) ProtoReflect ¶
func (x *Session) ProtoReflect() protoreflect.Message
type SlackUser ¶
type SlackUser struct { Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` Email string `protobuf:"bytes,2,opt,name=email,proto3" json:"email,omitempty"` Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"` // contains filtered or unexported fields }
func (*SlackUser) Descriptor
deprecated
func (*SlackUser) ProtoMessage ¶
func (*SlackUser) ProtoMessage()
func (*SlackUser) ProtoReflect ¶
func (x *SlackUser) ProtoReflect() protoreflect.Message
type SlackUserRequest ¶
type SlackUserRequest struct { Session *Session `protobuf:"bytes,1,opt,name=session,proto3" json:"session,omitempty"` User string `protobuf:"bytes,2,opt,name=user,proto3" json:"user,omitempty"` Message string `protobuf:"bytes,3,opt,name=message,proto3" json:"message,omitempty"` LinkName string `protobuf:"bytes,4,opt,name=link_name,json=linkName,proto3" json:"link_name,omitempty"` LinkUrl string `protobuf:"bytes,5,opt,name=link_url,json=linkUrl,proto3" json:"link_url,omitempty"` // contains filtered or unexported fields }
func (*SlackUserRequest) Descriptor
deprecated
func (*SlackUserRequest) Descriptor() ([]byte, []int)
Deprecated: Use SlackUserRequest.ProtoReflect.Descriptor instead.
func (*SlackUserRequest) GetLinkName ¶
func (x *SlackUserRequest) GetLinkName() string
func (*SlackUserRequest) GetLinkUrl ¶
func (x *SlackUserRequest) GetLinkUrl() string
func (*SlackUserRequest) GetMessage ¶
func (x *SlackUserRequest) GetMessage() string
func (*SlackUserRequest) GetSession ¶
func (x *SlackUserRequest) GetSession() *Session
func (*SlackUserRequest) GetUser ¶
func (x *SlackUserRequest) GetUser() string
func (*SlackUserRequest) ProtoMessage ¶
func (*SlackUserRequest) ProtoMessage()
func (*SlackUserRequest) ProtoReflect ¶
func (x *SlackUserRequest) ProtoReflect() protoreflect.Message
func (*SlackUserRequest) Reset ¶
func (x *SlackUserRequest) Reset()
func (*SlackUserRequest) String ¶
func (x *SlackUserRequest) String() string
type SlackUserResponse ¶
type SlackUserResponse struct { User *SlackUser `protobuf:"bytes,2,opt,name=user,proto3" json:"user,omitempty"` Decision SlackUserResponse_Decision `protobuf:"varint,3,opt,name=decision,proto3,enum=approuvez.SlackUserResponse_Decision" json:"decision,omitempty"` // contains filtered or unexported fields }
func (*SlackUserResponse) Descriptor
deprecated
func (*SlackUserResponse) Descriptor() ([]byte, []int)
Deprecated: Use SlackUserResponse.ProtoReflect.Descriptor instead.
func (*SlackUserResponse) GetDecision ¶
func (x *SlackUserResponse) GetDecision() SlackUserResponse_Decision
func (*SlackUserResponse) GetUser ¶
func (x *SlackUserResponse) GetUser() *SlackUser
func (*SlackUserResponse) ProtoMessage ¶
func (*SlackUserResponse) ProtoMessage()
func (*SlackUserResponse) ProtoReflect ¶
func (x *SlackUserResponse) ProtoReflect() protoreflect.Message
func (*SlackUserResponse) Reset ¶
func (x *SlackUserResponse) Reset()
func (*SlackUserResponse) String ¶
func (x *SlackUserResponse) String() string
type SlackUserResponse_Decision ¶
type SlackUserResponse_Decision int32
const ( SlackUserResponse_DENY SlackUserResponse_Decision = 0 SlackUserResponse_APPROVE SlackUserResponse_Decision = 1 )
func (SlackUserResponse_Decision) Descriptor ¶
func (SlackUserResponse_Decision) Descriptor() protoreflect.EnumDescriptor
func (SlackUserResponse_Decision) Enum ¶
func (x SlackUserResponse_Decision) Enum() *SlackUserResponse_Decision
func (SlackUserResponse_Decision) EnumDescriptor
deprecated
func (SlackUserResponse_Decision) EnumDescriptor() ([]byte, []int)
Deprecated: Use SlackUserResponse_Decision.Descriptor instead.
func (SlackUserResponse_Decision) Number ¶
func (x SlackUserResponse_Decision) Number() protoreflect.EnumNumber
func (SlackUserResponse_Decision) String ¶
func (x SlackUserResponse_Decision) String() string
func (SlackUserResponse_Decision) Type ¶
func (SlackUserResponse_Decision) Type() protoreflect.EnumType
type UnimplementedApprouvezServer ¶
type UnimplementedApprouvezServer struct { }
UnimplementedApprouvezServer must be embedded to have forward compatible implementations.
func (UnimplementedApprouvezServer) CreateStream ¶
func (UnimplementedApprouvezServer) CreateStream(*SlackUserRequest, Approuvez_CreateStreamServer) error
func (UnimplementedApprouvezServer) NewSession ¶
type UnsafeApprouvezServer ¶
type UnsafeApprouvezServer interface {
// contains filtered or unexported methods
}
UnsafeApprouvezServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ApprouvezServer will result in compilation errors.