// Code generated by protoc-gen-psrpc v0.7.0, DO NOT EDIT. // source: rpc/sip.proto package rpc import ( "context" "github.com/livekit/psrpc" "github.com/livekit/psrpc/pkg/client" "github.com/livekit/psrpc/pkg/info" "github.com/livekit/psrpc/pkg/rand" "github.com/livekit/psrpc/pkg/server" "github.com/livekit/psrpc/version" ) import google_protobuf "google.golang.org/protobuf/types/known/emptypb" var _ = version.PsrpcVersion_0_7 // ============================ // SIPInternal Client Interface // ============================ type SIPInternalClient interface { CreateSIPParticipant(ctx context.Context, topic string, req *InternalCreateSIPParticipantRequest, opts ...psrpc.RequestOption) (*InternalCreateSIPParticipantResponse, error) TransferSIPParticipant(ctx context.Context, sipCallId string, req *InternalTransferSIPParticipantRequest, opts ...psrpc.RequestOption) (*google_protobuf.Empty, error) // Close immediately, without waiting for pending RPCs Close() } // ================================ // SIPInternal ServerImpl Interface // ================================ type SIPInternalServerImpl interface { CreateSIPParticipant(context.Context, *InternalCreateSIPParticipantRequest) (*InternalCreateSIPParticipantResponse, error) TransferSIPParticipant(context.Context, *InternalTransferSIPParticipantRequest) (*google_protobuf.Empty, error) } // ============================ // SIPInternal Server Interface // ============================ type SIPInternalServer interface { RegisterCreateSIPParticipantTopic(topic string) error DeregisterCreateSIPParticipantTopic(topic string) RegisterTransferSIPParticipantTopic(sipCallId string) error DeregisterTransferSIPParticipantTopic(sipCallId string) // Close and wait for pending RPCs to complete Shutdown() // Close immediately, without waiting for pending RPCs Kill() } // ================== // SIPInternal Client // ================== type sIPInternalClient struct { client *client.RPCClient } // NewSIPInternalClient creates a psrpc client that implements the SIPInternalClient interface. func NewSIPInternalClient(bus psrpc.MessageBus, opts ...psrpc.ClientOption) (SIPInternalClient, error) { sd := &info.ServiceDefinition{ Name: "SIPInternal", ID: rand.NewClientID(), } sd.RegisterMethod("CreateSIPParticipant", false, false, true, true) sd.RegisterMethod("TransferSIPParticipant", false, false, true, true) rpcClient, err := client.NewRPCClient(sd, bus, opts...) if err != nil { return nil, err } return &sIPInternalClient{ client: rpcClient, }, nil } func (c *sIPInternalClient) CreateSIPParticipant(ctx context.Context, topic string, req *InternalCreateSIPParticipantRequest, opts ...psrpc.RequestOption) (*InternalCreateSIPParticipantResponse, error) { return client.RequestSingle[*InternalCreateSIPParticipantResponse](ctx, c.client, "CreateSIPParticipant", []string{topic}, req, opts...) } func (c *sIPInternalClient) TransferSIPParticipant(ctx context.Context, sipCallId string, req *InternalTransferSIPParticipantRequest, opts ...psrpc.RequestOption) (*google_protobuf.Empty, error) { return client.RequestSingle[*google_protobuf.Empty](ctx, c.client, "TransferSIPParticipant", []string{sipCallId}, req, opts...) } func (s *sIPInternalClient) Close() { s.client.Close() } // ================== // SIPInternal Server // ================== type sIPInternalServer struct { svc SIPInternalServerImpl rpc *server.RPCServer } // NewSIPInternalServer builds a RPCServer that will route requests // to the corresponding method in the provided svc implementation. func NewSIPInternalServer(svc SIPInternalServerImpl, bus psrpc.MessageBus, opts ...psrpc.ServerOption) (SIPInternalServer, error) { sd := &info.ServiceDefinition{ Name: "SIPInternal", ID: rand.NewServerID(), } s := server.NewRPCServer(sd, bus, opts...) sd.RegisterMethod("CreateSIPParticipant", false, false, true, true) sd.RegisterMethod("TransferSIPParticipant", false, false, true, true) return &sIPInternalServer{ svc: svc, rpc: s, }, nil } func (s *sIPInternalServer) RegisterCreateSIPParticipantTopic(topic string) error { return server.RegisterHandler(s.rpc, "CreateSIPParticipant", []string{topic}, s.svc.CreateSIPParticipant, nil) } func (s *sIPInternalServer) DeregisterCreateSIPParticipantTopic(topic string) { s.rpc.DeregisterHandler("CreateSIPParticipant", []string{topic}) } func (s *sIPInternalServer) RegisterTransferSIPParticipantTopic(sipCallId string) error { return server.RegisterHandler(s.rpc, "TransferSIPParticipant", []string{sipCallId}, s.svc.TransferSIPParticipant, nil) } func (s *sIPInternalServer) DeregisterTransferSIPParticipantTopic(sipCallId string) { s.rpc.DeregisterHandler("TransferSIPParticipant", []string{sipCallId}) } func (s *sIPInternalServer) Shutdown() { s.rpc.Close(false) } func (s *sIPInternalServer) Kill() { s.rpc.Close(true) } // ================================ // SIPInternal Unimplemented Server // ================================ type UnimplementedSIPInternalServer struct{} func (UnimplementedSIPInternalServer) CreateSIPParticipant(context.Context, *InternalCreateSIPParticipantRequest) (*InternalCreateSIPParticipantResponse, error) { return nil, psrpc.ErrUnimplemented } func (UnimplementedSIPInternalServer) TransferSIPParticipant(context.Context, *InternalTransferSIPParticipantRequest) (*google_protobuf.Empty, error) { return nil, psrpc.ErrUnimplemented } var psrpcFileDescriptor11 = []byte{ // 1208 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x57, 0xcd, 0x6f, 0xdb, 0x36, 0x14, 0x9f, 0xe2, 0x7c, 0xd2, 0x76, 0xec, 0xd0, 0x49, 0xca, 0x3a, 0x5b, 0xeb, 0xa6, 0x1d, 0xe0, 0x6e, 0x83, 0x8c, 0xa5, 0xd8, 0x3a, 0x04, 0x45, 0xb7, 0xe6, 0x0b, 0x35, 0xb0, 0xae, 0x86, 0xe2, 0x62, 0xc0, 0x2e, 0x02, 0x2d, 0xd1, 0x0e, 0x17, 0x49, 0xd4, 0x48, 0xaa, 0xae, 0x57, 0xf4, 0xbe, 0xfe, 0x17, 0x3b, 0xee, 0xdc, 0xd3, 0xd0, 0xd3, 0xfe, 0x9a, 0xfd, 0x0b, 0xbb, 0x0e, 0xa4, 0x24, 0x5b, 0x4e, 0x9c, 0xd4, 0x42, 0x6f, 0x7a, 0x5f, 0x3f, 0xbe, 0xf7, 0xf8, 0x3e, 0x28, 0x50, 0xe6, 0xa1, 0xd3, 0x12, 0x34, 0x34, 0x43, 0xce, 0x24, 0x83, 0x05, 0x1e, 0x3a, 0xf5, 0x9d, 0x01, 0x63, 0x03, 0x8f, 0xb4, 0x34, 0xab, 0x17, 0xf5, 0x5b, 0xc4, 0x0f, 0xe5, 0x28, 0xd6, 0xa8, 0xdf, 0xba, 0x28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