2022-03-22 11:03:15 -04:00
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
package pubproto
import (
context "context"
grpc "google.golang.org/grpc"
codes "google.golang.org/grpc/codes"
status "google.golang.org/grpc/status"
)
// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
// Requires gRPC-Go v1.32.0 or later.
const _ = grpc . SupportPackageIsVersion7
// APIClient is the client API for API 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.
type APIClient interface {
GetState ( ctx context . Context , in * GetStateRequest , opts ... grpc . CallOption ) ( * GetStateResponse , error )
ActivateAsCoordinator ( ctx context . Context , in * ActivateAsCoordinatorRequest , opts ... grpc . CallOption ) ( API_ActivateAsCoordinatorClient , error )
2022-04-20 11:06:47 -04:00
ActivateAsNode ( ctx context . Context , opts ... grpc . CallOption ) ( API_ActivateAsNodeClient , error )
2022-03-22 11:03:15 -04:00
ActivateAdditionalNodes ( ctx context . Context , in * ActivateAdditionalNodesRequest , opts ... grpc . CallOption ) ( API_ActivateAdditionalNodesClient , error )
2022-04-13 06:39:55 -04:00
ActivateAsAdditionalCoordinator ( ctx context . Context , in * ActivateAsAdditionalCoordinatorRequest , opts ... grpc . CallOption ) ( * ActivateAsAdditionalCoordinatorResponse , error )
ActivateAdditionalCoordinator ( ctx context . Context , in * ActivateAdditionalCoordinatorRequest , opts ... grpc . CallOption ) ( * ActivateAdditionalCoordinatorResponse , error )
2022-03-22 11:03:15 -04:00
JoinCluster ( ctx context . Context , in * JoinClusterRequest , opts ... grpc . CallOption ) ( * JoinClusterResponse , error )
TriggerNodeUpdate ( ctx context . Context , in * TriggerNodeUpdateRequest , opts ... grpc . CallOption ) ( * TriggerNodeUpdateResponse , error )
2022-04-13 06:39:55 -04:00
TriggerCoordinatorUpdate ( ctx context . Context , in * TriggerCoordinatorUpdateRequest , opts ... grpc . CallOption ) ( * TriggerCoordinatorUpdateResponse , error )
2022-04-25 11:21:09 -04:00
GetPeerVPNPublicKey ( ctx context . Context , in * GetPeerVPNPublicKeyRequest , opts ... grpc . CallOption ) ( * GetPeerVPNPublicKeyResponse , error )
2022-04-28 04:11:09 -04:00
GetVPNPeers ( ctx context . Context , in * GetVPNPeersRequest , opts ... grpc . CallOption ) ( * GetVPNPeersResponse , error )
2022-04-12 08:24:36 -04:00
RequestStateDiskKey ( ctx context . Context , in * RequestStateDiskKeyRequest , opts ... grpc . CallOption ) ( * RequestStateDiskKeyResponse , error )
2022-03-22 11:03:15 -04:00
}
type aPIClient struct {
cc grpc . ClientConnInterface
}
func NewAPIClient ( cc grpc . ClientConnInterface ) APIClient {
return & aPIClient { cc }
}
func ( c * aPIClient ) GetState ( ctx context . Context , in * GetStateRequest , opts ... grpc . CallOption ) ( * GetStateResponse , error ) {
out := new ( GetStateResponse )
err := c . cc . Invoke ( ctx , "/pubapi.API/GetState" , in , out , opts ... )
if err != nil {
return nil , err
}
return out , nil
}
func ( c * aPIClient ) ActivateAsCoordinator ( ctx context . Context , in * ActivateAsCoordinatorRequest , opts ... grpc . CallOption ) ( API_ActivateAsCoordinatorClient , error ) {
stream , err := c . cc . NewStream ( ctx , & API_ServiceDesc . Streams [ 0 ] , "/pubapi.API/ActivateAsCoordinator" , opts ... )
if err != nil {
return nil , err
}
x := & aPIActivateAsCoordinatorClient { stream }
if err := x . ClientStream . SendMsg ( in ) ; err != nil {
return nil , err
}
if err := x . ClientStream . CloseSend ( ) ; err != nil {
return nil , err
}
return x , nil
}
type API_ActivateAsCoordinatorClient interface {
Recv ( ) ( * ActivateAsCoordinatorResponse , error )
grpc . ClientStream
}
type aPIActivateAsCoordinatorClient struct {
grpc . ClientStream
}
func ( x * aPIActivateAsCoordinatorClient ) Recv ( ) ( * ActivateAsCoordinatorResponse , error ) {
m := new ( ActivateAsCoordinatorResponse )
if err := x . ClientStream . RecvMsg ( m ) ; err != nil {
return nil , err
}
return m , nil
}
2022-04-20 11:06:47 -04:00
func ( c * aPIClient ) ActivateAsNode ( ctx context . Context , opts ... grpc . CallOption ) ( API_ActivateAsNodeClient , error ) {
stream , err := c . cc . NewStream ( ctx , & API_ServiceDesc . Streams [ 1 ] , "/pubapi.API/ActivateAsNode" , opts ... )
2022-03-22 11:03:15 -04:00
if err != nil {
return nil , err
}
2022-04-20 11:06:47 -04:00
x := & aPIActivateAsNodeClient { stream }
return x , nil
}
type API_ActivateAsNodeClient interface {
Send ( * ActivateAsNodeRequest ) error
Recv ( ) ( * ActivateAsNodeResponse , error )
grpc . ClientStream
}
type aPIActivateAsNodeClient struct {
grpc . ClientStream
}
func ( x * aPIActivateAsNodeClient ) Send ( m * ActivateAsNodeRequest ) error {
return x . ClientStream . SendMsg ( m )
}
func ( x * aPIActivateAsNodeClient ) Recv ( ) ( * ActivateAsNodeResponse , error ) {
m := new ( ActivateAsNodeResponse )
if err := x . ClientStream . RecvMsg ( m ) ; err != nil {
return nil , err
}
return m , nil
2022-03-22 11:03:15 -04:00
}
func ( c * aPIClient ) ActivateAdditionalNodes ( ctx context . Context , in * ActivateAdditionalNodesRequest , opts ... grpc . CallOption ) ( API_ActivateAdditionalNodesClient , error ) {
2022-04-20 11:06:47 -04:00
stream , err := c . cc . NewStream ( ctx , & API_ServiceDesc . Streams [ 2 ] , "/pubapi.API/ActivateAdditionalNodes" , opts ... )
2022-03-22 11:03:15 -04:00
if err != nil {
return nil , err
}
x := & aPIActivateAdditionalNodesClient { stream }
if err := x . ClientStream . SendMsg ( in ) ; err != nil {
return nil , err
}
if err := x . ClientStream . CloseSend ( ) ; err != nil {
return nil , err
}
return x , nil
}
type API_ActivateAdditionalNodesClient interface {
Recv ( ) ( * ActivateAdditionalNodesResponse , error )
grpc . ClientStream
}
type aPIActivateAdditionalNodesClient struct {
grpc . ClientStream
}
func ( x * aPIActivateAdditionalNodesClient ) Recv ( ) ( * ActivateAdditionalNodesResponse , error ) {
m := new ( ActivateAdditionalNodesResponse )
if err := x . ClientStream . RecvMsg ( m ) ; err != nil {
return nil , err
}
return m , nil
}
2022-04-13 06:39:55 -04:00
func ( c * aPIClient ) ActivateAsAdditionalCoordinator ( ctx context . Context , in * ActivateAsAdditionalCoordinatorRequest , opts ... grpc . CallOption ) ( * ActivateAsAdditionalCoordinatorResponse , error ) {
out := new ( ActivateAsAdditionalCoordinatorResponse )
err := c . cc . Invoke ( ctx , "/pubapi.API/ActivateAsAdditionalCoordinator" , in , out , opts ... )
if err != nil {
return nil , err
}
return out , nil
}
func ( c * aPIClient ) ActivateAdditionalCoordinator ( ctx context . Context , in * ActivateAdditionalCoordinatorRequest , opts ... grpc . CallOption ) ( * ActivateAdditionalCoordinatorResponse , error ) {
out := new ( ActivateAdditionalCoordinatorResponse )
err := c . cc . Invoke ( ctx , "/pubapi.API/ActivateAdditionalCoordinator" , in , out , opts ... )
if err != nil {
return nil , err
}
return out , nil
}
2022-03-22 11:03:15 -04:00
func ( c * aPIClient ) JoinCluster ( ctx context . Context , in * JoinClusterRequest , opts ... grpc . CallOption ) ( * JoinClusterResponse , error ) {
out := new ( JoinClusterResponse )
err := c . cc . Invoke ( ctx , "/pubapi.API/JoinCluster" , in , out , opts ... )
if err != nil {
return nil , err
}
return out , nil
}
func ( c * aPIClient ) TriggerNodeUpdate ( ctx context . Context , in * TriggerNodeUpdateRequest , opts ... grpc . CallOption ) ( * TriggerNodeUpdateResponse , error ) {
out := new ( TriggerNodeUpdateResponse )
err := c . cc . Invoke ( ctx , "/pubapi.API/TriggerNodeUpdate" , in , out , opts ... )
if err != nil {
return nil , err
}
return out , nil
}
2022-04-13 06:39:55 -04:00
func ( c * aPIClient ) TriggerCoordinatorUpdate ( ctx context . Context , in * TriggerCoordinatorUpdateRequest , opts ... grpc . CallOption ) ( * TriggerCoordinatorUpdateResponse , error ) {
out := new ( TriggerCoordinatorUpdateResponse )
err := c . cc . Invoke ( ctx , "/pubapi.API/TriggerCoordinatorUpdate" , in , out , opts ... )
if err != nil {
return nil , err
}
return out , nil
}
2022-04-25 11:21:09 -04:00
func ( c * aPIClient ) GetPeerVPNPublicKey ( ctx context . Context , in * GetPeerVPNPublicKeyRequest , opts ... grpc . CallOption ) ( * GetPeerVPNPublicKeyResponse , error ) {
out := new ( GetPeerVPNPublicKeyResponse )
err := c . cc . Invoke ( ctx , "/pubapi.API/GetPeerVPNPublicKey" , in , out , opts ... )
if err != nil {
return nil , err
}
return out , nil
}
2022-04-28 04:11:09 -04:00
func ( c * aPIClient ) GetVPNPeers ( ctx context . Context , in * GetVPNPeersRequest , opts ... grpc . CallOption ) ( * GetVPNPeersResponse , error ) {
out := new ( GetVPNPeersResponse )
err := c . cc . Invoke ( ctx , "/pubapi.API/GetVPNPeers" , in , out , opts ... )
if err != nil {
return nil , err
}
return out , nil
}
2022-04-12 08:24:36 -04:00
func ( c * aPIClient ) RequestStateDiskKey ( ctx context . Context , in * RequestStateDiskKeyRequest , opts ... grpc . CallOption ) ( * RequestStateDiskKeyResponse , error ) {
out := new ( RequestStateDiskKeyResponse )
err := c . cc . Invoke ( ctx , "/pubapi.API/RequestStateDiskKey" , in , out , opts ... )
if err != nil {
return nil , err
}
return out , nil
}
2022-03-22 11:03:15 -04:00
// APIServer is the server API for API service.
// All implementations must embed UnimplementedAPIServer
// for forward compatibility
type APIServer interface {
GetState ( context . Context , * GetStateRequest ) ( * GetStateResponse , error )
ActivateAsCoordinator ( * ActivateAsCoordinatorRequest , API_ActivateAsCoordinatorServer ) error
2022-04-20 11:06:47 -04:00
ActivateAsNode ( API_ActivateAsNodeServer ) error
2022-03-22 11:03:15 -04:00
ActivateAdditionalNodes ( * ActivateAdditionalNodesRequest , API_ActivateAdditionalNodesServer ) error
2022-04-13 06:39:55 -04:00
ActivateAsAdditionalCoordinator ( context . Context , * ActivateAsAdditionalCoordinatorRequest ) ( * ActivateAsAdditionalCoordinatorResponse , error )
ActivateAdditionalCoordinator ( context . Context , * ActivateAdditionalCoordinatorRequest ) ( * ActivateAdditionalCoordinatorResponse , error )
2022-03-22 11:03:15 -04:00
JoinCluster ( context . Context , * JoinClusterRequest ) ( * JoinClusterResponse , error )
TriggerNodeUpdate ( context . Context , * TriggerNodeUpdateRequest ) ( * TriggerNodeUpdateResponse , error )
2022-04-13 06:39:55 -04:00
TriggerCoordinatorUpdate ( context . Context , * TriggerCoordinatorUpdateRequest ) ( * TriggerCoordinatorUpdateResponse , error )
2022-04-25 11:21:09 -04:00
GetPeerVPNPublicKey ( context . Context , * GetPeerVPNPublicKeyRequest ) ( * GetPeerVPNPublicKeyResponse , error )
2022-04-28 04:11:09 -04:00
GetVPNPeers ( context . Context , * GetVPNPeersRequest ) ( * GetVPNPeersResponse , error )
2022-04-12 08:24:36 -04:00
RequestStateDiskKey ( context . Context , * RequestStateDiskKeyRequest ) ( * RequestStateDiskKeyResponse , error )
2022-03-22 11:03:15 -04:00
mustEmbedUnimplementedAPIServer ( )
}
// UnimplementedAPIServer must be embedded to have forward compatible implementations.
type UnimplementedAPIServer struct {
}
func ( UnimplementedAPIServer ) GetState ( context . Context , * GetStateRequest ) ( * GetStateResponse , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method GetState not implemented" )
}
func ( UnimplementedAPIServer ) ActivateAsCoordinator ( * ActivateAsCoordinatorRequest , API_ActivateAsCoordinatorServer ) error {
return status . Errorf ( codes . Unimplemented , "method ActivateAsCoordinator not implemented" )
}
2022-04-20 11:06:47 -04:00
func ( UnimplementedAPIServer ) ActivateAsNode ( API_ActivateAsNodeServer ) error {
return status . Errorf ( codes . Unimplemented , "method ActivateAsNode not implemented" )
2022-03-22 11:03:15 -04:00
}
func ( UnimplementedAPIServer ) ActivateAdditionalNodes ( * ActivateAdditionalNodesRequest , API_ActivateAdditionalNodesServer ) error {
return status . Errorf ( codes . Unimplemented , "method ActivateAdditionalNodes not implemented" )
}
2022-04-13 06:39:55 -04:00
func ( UnimplementedAPIServer ) ActivateAsAdditionalCoordinator ( context . Context , * ActivateAsAdditionalCoordinatorRequest ) ( * ActivateAsAdditionalCoordinatorResponse , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method ActivateAsAdditionalCoordinator not implemented" )
}
func ( UnimplementedAPIServer ) ActivateAdditionalCoordinator ( context . Context , * ActivateAdditionalCoordinatorRequest ) ( * ActivateAdditionalCoordinatorResponse , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method ActivateAdditionalCoordinator not implemented" )
}
2022-03-22 11:03:15 -04:00
func ( UnimplementedAPIServer ) JoinCluster ( context . Context , * JoinClusterRequest ) ( * JoinClusterResponse , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method JoinCluster not implemented" )
}
func ( UnimplementedAPIServer ) TriggerNodeUpdate ( context . Context , * TriggerNodeUpdateRequest ) ( * TriggerNodeUpdateResponse , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method TriggerNodeUpdate not implemented" )
}
2022-04-13 06:39:55 -04:00
func ( UnimplementedAPIServer ) TriggerCoordinatorUpdate ( context . Context , * TriggerCoordinatorUpdateRequest ) ( * TriggerCoordinatorUpdateResponse , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method TriggerCoordinatorUpdate not implemented" )
}
2022-04-25 11:21:09 -04:00
func ( UnimplementedAPIServer ) GetPeerVPNPublicKey ( context . Context , * GetPeerVPNPublicKeyRequest ) ( * GetPeerVPNPublicKeyResponse , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method GetPeerVPNPublicKey not implemented" )
}
2022-04-28 04:11:09 -04:00
func ( UnimplementedAPIServer ) GetVPNPeers ( context . Context , * GetVPNPeersRequest ) ( * GetVPNPeersResponse , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method GetVPNPeers not implemented" )
}
2022-04-12 08:24:36 -04:00
func ( UnimplementedAPIServer ) RequestStateDiskKey ( context . Context , * RequestStateDiskKeyRequest ) ( * RequestStateDiskKeyResponse , error ) {
return nil , status . Errorf ( codes . Unimplemented , "method RequestStateDiskKey not implemented" )
}
2022-03-22 11:03:15 -04:00
func ( UnimplementedAPIServer ) mustEmbedUnimplementedAPIServer ( ) { }
// UnsafeAPIServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to APIServer will
// result in compilation errors.
type UnsafeAPIServer interface {
mustEmbedUnimplementedAPIServer ( )
}
func RegisterAPIServer ( s grpc . ServiceRegistrar , srv APIServer ) {
s . RegisterService ( & API_ServiceDesc , srv )
}
func _API_GetState_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( GetStateRequest )
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
return srv . ( APIServer ) . GetState ( ctx , in )
}
info := & grpc . UnaryServerInfo {
Server : srv ,
FullMethod : "/pubapi.API/GetState" ,
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
return srv . ( APIServer ) . GetState ( ctx , req . ( * GetStateRequest ) )
}
return interceptor ( ctx , in , info , handler )
}
func _API_ActivateAsCoordinator_Handler ( srv interface { } , stream grpc . ServerStream ) error {
m := new ( ActivateAsCoordinatorRequest )
if err := stream . RecvMsg ( m ) ; err != nil {
return err
}
return srv . ( APIServer ) . ActivateAsCoordinator ( m , & aPIActivateAsCoordinatorServer { stream } )
}
type API_ActivateAsCoordinatorServer interface {
Send ( * ActivateAsCoordinatorResponse ) error
grpc . ServerStream
}
type aPIActivateAsCoordinatorServer struct {
grpc . ServerStream
}
func ( x * aPIActivateAsCoordinatorServer ) Send ( m * ActivateAsCoordinatorResponse ) error {
return x . ServerStream . SendMsg ( m )
}
2022-04-20 11:06:47 -04:00
func _API_ActivateAsNode_Handler ( srv interface { } , stream grpc . ServerStream ) error {
return srv . ( APIServer ) . ActivateAsNode ( & aPIActivateAsNodeServer { stream } )
}
type API_ActivateAsNodeServer interface {
Send ( * ActivateAsNodeResponse ) error
Recv ( ) ( * ActivateAsNodeRequest , error )
grpc . ServerStream
}
type aPIActivateAsNodeServer struct {
grpc . ServerStream
}
func ( x * aPIActivateAsNodeServer ) Send ( m * ActivateAsNodeResponse ) error {
return x . ServerStream . SendMsg ( m )
}
func ( x * aPIActivateAsNodeServer ) Recv ( ) ( * ActivateAsNodeRequest , error ) {
m := new ( ActivateAsNodeRequest )
if err := x . ServerStream . RecvMsg ( m ) ; err != nil {
2022-03-22 11:03:15 -04:00
return nil , err
}
2022-04-20 11:06:47 -04:00
return m , nil
2022-03-22 11:03:15 -04:00
}
func _API_ActivateAdditionalNodes_Handler ( srv interface { } , stream grpc . ServerStream ) error {
m := new ( ActivateAdditionalNodesRequest )
if err := stream . RecvMsg ( m ) ; err != nil {
return err
}
return srv . ( APIServer ) . ActivateAdditionalNodes ( m , & aPIActivateAdditionalNodesServer { stream } )
}
type API_ActivateAdditionalNodesServer interface {
Send ( * ActivateAdditionalNodesResponse ) error
grpc . ServerStream
}
type aPIActivateAdditionalNodesServer struct {
grpc . ServerStream
}
func ( x * aPIActivateAdditionalNodesServer ) Send ( m * ActivateAdditionalNodesResponse ) error {
return x . ServerStream . SendMsg ( m )
}
2022-04-13 06:39:55 -04:00
func _API_ActivateAsAdditionalCoordinator_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( ActivateAsAdditionalCoordinatorRequest )
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
return srv . ( APIServer ) . ActivateAsAdditionalCoordinator ( ctx , in )
}
info := & grpc . UnaryServerInfo {
Server : srv ,
FullMethod : "/pubapi.API/ActivateAsAdditionalCoordinator" ,
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
return srv . ( APIServer ) . ActivateAsAdditionalCoordinator ( ctx , req . ( * ActivateAsAdditionalCoordinatorRequest ) )
}
return interceptor ( ctx , in , info , handler )
}
func _API_ActivateAdditionalCoordinator_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( ActivateAdditionalCoordinatorRequest )
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
return srv . ( APIServer ) . ActivateAdditionalCoordinator ( ctx , in )
}
info := & grpc . UnaryServerInfo {
Server : srv ,
FullMethod : "/pubapi.API/ActivateAdditionalCoordinator" ,
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
return srv . ( APIServer ) . ActivateAdditionalCoordinator ( ctx , req . ( * ActivateAdditionalCoordinatorRequest ) )
}
return interceptor ( ctx , in , info , handler )
}
2022-03-22 11:03:15 -04:00
func _API_JoinCluster_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( JoinClusterRequest )
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
return srv . ( APIServer ) . JoinCluster ( ctx , in )
}
info := & grpc . UnaryServerInfo {
Server : srv ,
FullMethod : "/pubapi.API/JoinCluster" ,
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
return srv . ( APIServer ) . JoinCluster ( ctx , req . ( * JoinClusterRequest ) )
}
return interceptor ( ctx , in , info , handler )
}
func _API_TriggerNodeUpdate_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( TriggerNodeUpdateRequest )
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
return srv . ( APIServer ) . TriggerNodeUpdate ( ctx , in )
}
info := & grpc . UnaryServerInfo {
Server : srv ,
FullMethod : "/pubapi.API/TriggerNodeUpdate" ,
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
return srv . ( APIServer ) . TriggerNodeUpdate ( ctx , req . ( * TriggerNodeUpdateRequest ) )
}
return interceptor ( ctx , in , info , handler )
}
2022-04-13 06:39:55 -04:00
func _API_TriggerCoordinatorUpdate_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( TriggerCoordinatorUpdateRequest )
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
return srv . ( APIServer ) . TriggerCoordinatorUpdate ( ctx , in )
}
info := & grpc . UnaryServerInfo {
Server : srv ,
FullMethod : "/pubapi.API/TriggerCoordinatorUpdate" ,
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
return srv . ( APIServer ) . TriggerCoordinatorUpdate ( ctx , req . ( * TriggerCoordinatorUpdateRequest ) )
}
return interceptor ( ctx , in , info , handler )
}
2022-04-25 11:21:09 -04:00
func _API_GetPeerVPNPublicKey_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( GetPeerVPNPublicKeyRequest )
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
return srv . ( APIServer ) . GetPeerVPNPublicKey ( ctx , in )
}
info := & grpc . UnaryServerInfo {
Server : srv ,
FullMethod : "/pubapi.API/GetPeerVPNPublicKey" ,
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
return srv . ( APIServer ) . GetPeerVPNPublicKey ( ctx , req . ( * GetPeerVPNPublicKeyRequest ) )
}
return interceptor ( ctx , in , info , handler )
}
2022-04-28 04:11:09 -04:00
func _API_GetVPNPeers_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( GetVPNPeersRequest )
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
return srv . ( APIServer ) . GetVPNPeers ( ctx , in )
}
info := & grpc . UnaryServerInfo {
Server : srv ,
FullMethod : "/pubapi.API/GetVPNPeers" ,
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
return srv . ( APIServer ) . GetVPNPeers ( ctx , req . ( * GetVPNPeersRequest ) )
}
return interceptor ( ctx , in , info , handler )
}
2022-04-12 08:24:36 -04:00
func _API_RequestStateDiskKey_Handler ( srv interface { } , ctx context . Context , dec func ( interface { } ) error , interceptor grpc . UnaryServerInterceptor ) ( interface { } , error ) {
in := new ( RequestStateDiskKeyRequest )
if err := dec ( in ) ; err != nil {
return nil , err
}
if interceptor == nil {
return srv . ( APIServer ) . RequestStateDiskKey ( ctx , in )
}
info := & grpc . UnaryServerInfo {
Server : srv ,
FullMethod : "/pubapi.API/RequestStateDiskKey" ,
}
handler := func ( ctx context . Context , req interface { } ) ( interface { } , error ) {
return srv . ( APIServer ) . RequestStateDiskKey ( ctx , req . ( * RequestStateDiskKeyRequest ) )
}
return interceptor ( ctx , in , info , handler )
}
2022-03-22 11:03:15 -04:00
// API_ServiceDesc is the grpc.ServiceDesc for API service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var API_ServiceDesc = grpc . ServiceDesc {
ServiceName : "pubapi.API" ,
HandlerType : ( * APIServer ) ( nil ) ,
Methods : [ ] grpc . MethodDesc {
{
MethodName : "GetState" ,
Handler : _API_GetState_Handler ,
} ,
2022-04-13 06:39:55 -04:00
{
MethodName : "ActivateAsAdditionalCoordinator" ,
Handler : _API_ActivateAsAdditionalCoordinator_Handler ,
} ,
{
MethodName : "ActivateAdditionalCoordinator" ,
Handler : _API_ActivateAdditionalCoordinator_Handler ,
} ,
2022-03-22 11:03:15 -04:00
{
MethodName : "JoinCluster" ,
Handler : _API_JoinCluster_Handler ,
} ,
{
MethodName : "TriggerNodeUpdate" ,
Handler : _API_TriggerNodeUpdate_Handler ,
} ,
2022-04-13 06:39:55 -04:00
{
MethodName : "TriggerCoordinatorUpdate" ,
Handler : _API_TriggerCoordinatorUpdate_Handler ,
} ,
2022-04-25 11:21:09 -04:00
{
MethodName : "GetPeerVPNPublicKey" ,
Handler : _API_GetPeerVPNPublicKey_Handler ,
} ,
2022-04-28 04:11:09 -04:00
{
MethodName : "GetVPNPeers" ,
Handler : _API_GetVPNPeers_Handler ,
} ,
2022-04-12 08:24:36 -04:00
{
MethodName : "RequestStateDiskKey" ,
Handler : _API_RequestStateDiskKey_Handler ,
} ,
2022-03-22 11:03:15 -04:00
} ,
Streams : [ ] grpc . StreamDesc {
{
StreamName : "ActivateAsCoordinator" ,
Handler : _API_ActivateAsCoordinator_Handler ,
ServerStreams : true ,
} ,
2022-04-20 11:06:47 -04:00
{
StreamName : "ActivateAsNode" ,
Handler : _API_ActivateAsNode_Handler ,
ServerStreams : true ,
ClientStreams : true ,
} ,
2022-03-22 11:03:15 -04:00
{
StreamName : "ActivateAdditionalNodes" ,
Handler : _API_ActivateAdditionalNodes_Handler ,
ServerStreams : true ,
} ,
} ,
Metadata : "pubapi.proto" ,
}