pkg/daemon/rpc/daemon_grpc.pb.go
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
// versions:
// - protoc-gen-go-grpc v1.3.0
// - protoc v3.21.2
// source: daemon.proto
package rpc
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
const (
Daemon_Connect_FullMethodName = "/rpc.Daemon/Connect"
Daemon_ConnectFork_FullMethodName = "/rpc.Daemon/ConnectFork"
Daemon_Disconnect_FullMethodName = "/rpc.Daemon/Disconnect"
Daemon_Proxy_FullMethodName = "/rpc.Daemon/Proxy"
Daemon_Leave_FullMethodName = "/rpc.Daemon/Leave"
Daemon_Clone_FullMethodName = "/rpc.Daemon/Clone"
Daemon_Remove_FullMethodName = "/rpc.Daemon/Remove"
Daemon_ConfigAdd_FullMethodName = "/rpc.Daemon/ConfigAdd"
Daemon_ConfigRemove_FullMethodName = "/rpc.Daemon/ConfigRemove"
Daemon_SshStart_FullMethodName = "/rpc.Daemon/SshStart"
Daemon_SshStop_FullMethodName = "/rpc.Daemon/SshStop"
Daemon_SshConnect_FullMethodName = "/rpc.Daemon/SshConnect"
Daemon_Logs_FullMethodName = "/rpc.Daemon/Logs"
Daemon_List_FullMethodName = "/rpc.Daemon/List"
Daemon_Get_FullMethodName = "/rpc.Daemon/Get"
Daemon_Upgrade_FullMethodName = "/rpc.Daemon/Upgrade"
Daemon_Status_FullMethodName = "/rpc.Daemon/Status"
Daemon_Version_FullMethodName = "/rpc.Daemon/Version"
Daemon_Reset_FullMethodName = "/rpc.Daemon/Reset"
Daemon_Quit_FullMethodName = "/rpc.Daemon/Quit"
Daemon_Identify_FullMethodName = "/rpc.Daemon/Identify"
)
// DaemonClient is the client API for Daemon 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 DaemonClient interface {
Connect(ctx context.Context, in *ConnectRequest, opts ...grpc.CallOption) (Daemon_ConnectClient, error)
ConnectFork(ctx context.Context, in *ConnectRequest, opts ...grpc.CallOption) (Daemon_ConnectForkClient, error)
Disconnect(ctx context.Context, in *DisconnectRequest, opts ...grpc.CallOption) (Daemon_DisconnectClient, error)
Proxy(ctx context.Context, in *ConnectRequest, opts ...grpc.CallOption) (Daemon_ProxyClient, error)
Leave(ctx context.Context, in *LeaveRequest, opts ...grpc.CallOption) (Daemon_LeaveClient, error)
Clone(ctx context.Context, in *CloneRequest, opts ...grpc.CallOption) (Daemon_CloneClient, error)
Remove(ctx context.Context, in *RemoveRequest, opts ...grpc.CallOption) (Daemon_RemoveClient, error)
ConfigAdd(ctx context.Context, in *ConfigAddRequest, opts ...grpc.CallOption) (*ConfigAddResponse, error)
ConfigRemove(ctx context.Context, in *ConfigRemoveRequest, opts ...grpc.CallOption) (*ConfigRemoveResponse, error)
SshStart(ctx context.Context, in *SshStartRequest, opts ...grpc.CallOption) (*SshStartResponse, error)
SshStop(ctx context.Context, in *SshStopRequest, opts ...grpc.CallOption) (*SshStopResponse, error)
SshConnect(ctx context.Context, opts ...grpc.CallOption) (Daemon_SshConnectClient, error)
Logs(ctx context.Context, in *LogRequest, opts ...grpc.CallOption) (Daemon_LogsClient, error)
List(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*ListResponse, error)
Get(ctx context.Context, in *GetRequest, opts ...grpc.CallOption) (*GetResponse, error)
Upgrade(ctx context.Context, in *UpgradeRequest, opts ...grpc.CallOption) (*UpgradeResponse, error)
Status(ctx context.Context, in *StatusRequest, opts ...grpc.CallOption) (*StatusResponse, error)
Version(ctx context.Context, in *VersionRequest, opts ...grpc.CallOption) (*VersionResponse, error)
Reset(ctx context.Context, in *ResetRequest, opts ...grpc.CallOption) (Daemon_ResetClient, error)
Quit(ctx context.Context, in *QuitRequest, opts ...grpc.CallOption) (Daemon_QuitClient, error)
Identify(ctx context.Context, in *IdentifyRequest, opts ...grpc.CallOption) (*IdentifyResponse, error)
}
type daemonClient struct {
cc grpc.ClientConnInterface
}
func NewDaemonClient(cc grpc.ClientConnInterface) DaemonClient {
return &daemonClient{cc}
}
func (c *daemonClient) Connect(ctx context.Context, in *ConnectRequest, opts ...grpc.CallOption) (Daemon_ConnectClient, error) {
stream, err := c.cc.NewStream(ctx, &Daemon_ServiceDesc.Streams[0], Daemon_Connect_FullMethodName, opts...)
if err != nil {
return nil, err
}
x := &daemonConnectClient{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 Daemon_ConnectClient interface {
Recv() (*ConnectResponse, error)
grpc.ClientStream
}
type daemonConnectClient struct {
grpc.ClientStream
}
func (x *daemonConnectClient) Recv() (*ConnectResponse, error) {
m := new(ConnectResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *daemonClient) ConnectFork(ctx context.Context, in *ConnectRequest, opts ...grpc.CallOption) (Daemon_ConnectForkClient, error) {
stream, err := c.cc.NewStream(ctx, &Daemon_ServiceDesc.Streams[1], Daemon_ConnectFork_FullMethodName, opts...)
if err != nil {
return nil, err
}
x := &daemonConnectForkClient{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 Daemon_ConnectForkClient interface {
Recv() (*ConnectResponse, error)
grpc.ClientStream
}
type daemonConnectForkClient struct {
grpc.ClientStream
}
func (x *daemonConnectForkClient) Recv() (*ConnectResponse, error) {
m := new(ConnectResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *daemonClient) Disconnect(ctx context.Context, in *DisconnectRequest, opts ...grpc.CallOption) (Daemon_DisconnectClient, error) {
stream, err := c.cc.NewStream(ctx, &Daemon_ServiceDesc.Streams[2], Daemon_Disconnect_FullMethodName, opts...)
if err != nil {
return nil, err
}
x := &daemonDisconnectClient{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 Daemon_DisconnectClient interface {
Recv() (*DisconnectResponse, error)
grpc.ClientStream
}
type daemonDisconnectClient struct {
grpc.ClientStream
}
func (x *daemonDisconnectClient) Recv() (*DisconnectResponse, error) {
m := new(DisconnectResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *daemonClient) Proxy(ctx context.Context, in *ConnectRequest, opts ...grpc.CallOption) (Daemon_ProxyClient, error) {
stream, err := c.cc.NewStream(ctx, &Daemon_ServiceDesc.Streams[3], Daemon_Proxy_FullMethodName, opts...)
if err != nil {
return nil, err
}
x := &daemonProxyClient{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 Daemon_ProxyClient interface {
Recv() (*ConnectResponse, error)
grpc.ClientStream
}
type daemonProxyClient struct {
grpc.ClientStream
}
func (x *daemonProxyClient) Recv() (*ConnectResponse, error) {
m := new(ConnectResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *daemonClient) Leave(ctx context.Context, in *LeaveRequest, opts ...grpc.CallOption) (Daemon_LeaveClient, error) {
stream, err := c.cc.NewStream(ctx, &Daemon_ServiceDesc.Streams[4], Daemon_Leave_FullMethodName, opts...)
if err != nil {
return nil, err
}
x := &daemonLeaveClient{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 Daemon_LeaveClient interface {
Recv() (*LeaveResponse, error)
grpc.ClientStream
}
type daemonLeaveClient struct {
grpc.ClientStream
}
func (x *daemonLeaveClient) Recv() (*LeaveResponse, error) {
m := new(LeaveResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *daemonClient) Clone(ctx context.Context, in *CloneRequest, opts ...grpc.CallOption) (Daemon_CloneClient, error) {
stream, err := c.cc.NewStream(ctx, &Daemon_ServiceDesc.Streams[5], Daemon_Clone_FullMethodName, opts...)
if err != nil {
return nil, err
}
x := &daemonCloneClient{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 Daemon_CloneClient interface {
Recv() (*CloneResponse, error)
grpc.ClientStream
}
type daemonCloneClient struct {
grpc.ClientStream
}
func (x *daemonCloneClient) Recv() (*CloneResponse, error) {
m := new(CloneResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *daemonClient) Remove(ctx context.Context, in *RemoveRequest, opts ...grpc.CallOption) (Daemon_RemoveClient, error) {
stream, err := c.cc.NewStream(ctx, &Daemon_ServiceDesc.Streams[6], Daemon_Remove_FullMethodName, opts...)
if err != nil {
return nil, err
}
x := &daemonRemoveClient{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 Daemon_RemoveClient interface {
Recv() (*RemoveResponse, error)
grpc.ClientStream
}
type daemonRemoveClient struct {
grpc.ClientStream
}
func (x *daemonRemoveClient) Recv() (*RemoveResponse, error) {
m := new(RemoveResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *daemonClient) ConfigAdd(ctx context.Context, in *ConfigAddRequest, opts ...grpc.CallOption) (*ConfigAddResponse, error) {
out := new(ConfigAddResponse)
err := c.cc.Invoke(ctx, Daemon_ConfigAdd_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *daemonClient) ConfigRemove(ctx context.Context, in *ConfigRemoveRequest, opts ...grpc.CallOption) (*ConfigRemoveResponse, error) {
out := new(ConfigRemoveResponse)
err := c.cc.Invoke(ctx, Daemon_ConfigRemove_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *daemonClient) SshStart(ctx context.Context, in *SshStartRequest, opts ...grpc.CallOption) (*SshStartResponse, error) {
out := new(SshStartResponse)
err := c.cc.Invoke(ctx, Daemon_SshStart_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *daemonClient) SshStop(ctx context.Context, in *SshStopRequest, opts ...grpc.CallOption) (*SshStopResponse, error) {
out := new(SshStopResponse)
err := c.cc.Invoke(ctx, Daemon_SshStop_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *daemonClient) SshConnect(ctx context.Context, opts ...grpc.CallOption) (Daemon_SshConnectClient, error) {
stream, err := c.cc.NewStream(ctx, &Daemon_ServiceDesc.Streams[7], Daemon_SshConnect_FullMethodName, opts...)
if err != nil {
return nil, err
}
x := &daemonSshConnectClient{stream}
return x, nil
}
type Daemon_SshConnectClient interface {
Send(*SshConnectRequest) error
Recv() (*SshConnectResponse, error)
grpc.ClientStream
}
type daemonSshConnectClient struct {
grpc.ClientStream
}
func (x *daemonSshConnectClient) Send(m *SshConnectRequest) error {
return x.ClientStream.SendMsg(m)
}
func (x *daemonSshConnectClient) Recv() (*SshConnectResponse, error) {
m := new(SshConnectResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *daemonClient) Logs(ctx context.Context, in *LogRequest, opts ...grpc.CallOption) (Daemon_LogsClient, error) {
stream, err := c.cc.NewStream(ctx, &Daemon_ServiceDesc.Streams[8], Daemon_Logs_FullMethodName, opts...)
if err != nil {
return nil, err
}
x := &daemonLogsClient{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 Daemon_LogsClient interface {
Recv() (*LogResponse, error)
grpc.ClientStream
}
type daemonLogsClient struct {
grpc.ClientStream
}
func (x *daemonLogsClient) Recv() (*LogResponse, error) {
m := new(LogResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *daemonClient) List(ctx context.Context, in *ListRequest, opts ...grpc.CallOption) (*ListResponse, error) {
out := new(ListResponse)
err := c.cc.Invoke(ctx, Daemon_List_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *daemonClient) Get(ctx context.Context, in *GetRequest, opts ...grpc.CallOption) (*GetResponse, error) {
out := new(GetResponse)
err := c.cc.Invoke(ctx, Daemon_Get_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *daemonClient) Upgrade(ctx context.Context, in *UpgradeRequest, opts ...grpc.CallOption) (*UpgradeResponse, error) {
out := new(UpgradeResponse)
err := c.cc.Invoke(ctx, Daemon_Upgrade_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *daemonClient) Status(ctx context.Context, in *StatusRequest, opts ...grpc.CallOption) (*StatusResponse, error) {
out := new(StatusResponse)
err := c.cc.Invoke(ctx, Daemon_Status_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *daemonClient) Version(ctx context.Context, in *VersionRequest, opts ...grpc.CallOption) (*VersionResponse, error) {
out := new(VersionResponse)
err := c.cc.Invoke(ctx, Daemon_Version_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
func (c *daemonClient) Reset(ctx context.Context, in *ResetRequest, opts ...grpc.CallOption) (Daemon_ResetClient, error) {
stream, err := c.cc.NewStream(ctx, &Daemon_ServiceDesc.Streams[9], Daemon_Reset_FullMethodName, opts...)
if err != nil {
return nil, err
}
x := &daemonResetClient{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 Daemon_ResetClient interface {
Recv() (*ResetResponse, error)
grpc.ClientStream
}
type daemonResetClient struct {
grpc.ClientStream
}
func (x *daemonResetClient) Recv() (*ResetResponse, error) {
m := new(ResetResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *daemonClient) Quit(ctx context.Context, in *QuitRequest, opts ...grpc.CallOption) (Daemon_QuitClient, error) {
stream, err := c.cc.NewStream(ctx, &Daemon_ServiceDesc.Streams[10], Daemon_Quit_FullMethodName, opts...)
if err != nil {
return nil, err
}
x := &daemonQuitClient{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 Daemon_QuitClient interface {
Recv() (*QuitResponse, error)
grpc.ClientStream
}
type daemonQuitClient struct {
grpc.ClientStream
}
func (x *daemonQuitClient) Recv() (*QuitResponse, error) {
m := new(QuitResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *daemonClient) Identify(ctx context.Context, in *IdentifyRequest, opts ...grpc.CallOption) (*IdentifyResponse, error) {
out := new(IdentifyResponse)
err := c.cc.Invoke(ctx, Daemon_Identify_FullMethodName, in, out, opts...)
if err != nil {
return nil, err
}
return out, nil
}
// DaemonServer is the server API for Daemon service.
// All implementations must embed UnimplementedDaemonServer
// for forward compatibility
type DaemonServer interface {
Connect(*ConnectRequest, Daemon_ConnectServer) error
ConnectFork(*ConnectRequest, Daemon_ConnectForkServer) error
Disconnect(*DisconnectRequest, Daemon_DisconnectServer) error
Proxy(*ConnectRequest, Daemon_ProxyServer) error
Leave(*LeaveRequest, Daemon_LeaveServer) error
Clone(*CloneRequest, Daemon_CloneServer) error
Remove(*RemoveRequest, Daemon_RemoveServer) error
ConfigAdd(context.Context, *ConfigAddRequest) (*ConfigAddResponse, error)
ConfigRemove(context.Context, *ConfigRemoveRequest) (*ConfigRemoveResponse, error)
SshStart(context.Context, *SshStartRequest) (*SshStartResponse, error)
SshStop(context.Context, *SshStopRequest) (*SshStopResponse, error)
SshConnect(Daemon_SshConnectServer) error
Logs(*LogRequest, Daemon_LogsServer) error
List(context.Context, *ListRequest) (*ListResponse, error)
Get(context.Context, *GetRequest) (*GetResponse, error)
Upgrade(context.Context, *UpgradeRequest) (*UpgradeResponse, error)
Status(context.Context, *StatusRequest) (*StatusResponse, error)
Version(context.Context, *VersionRequest) (*VersionResponse, error)
Reset(*ResetRequest, Daemon_ResetServer) error
Quit(*QuitRequest, Daemon_QuitServer) error
Identify(context.Context, *IdentifyRequest) (*IdentifyResponse, error)
mustEmbedUnimplementedDaemonServer()
}
// UnimplementedDaemonServer must be embedded to have forward compatible implementations.
type UnimplementedDaemonServer struct {
}
func (UnimplementedDaemonServer) Connect(*ConnectRequest, Daemon_ConnectServer) error {
return status.Errorf(codes.Unimplemented, "method Connect not implemented")
}
func (UnimplementedDaemonServer) ConnectFork(*ConnectRequest, Daemon_ConnectForkServer) error {
return status.Errorf(codes.Unimplemented, "method ConnectFork not implemented")
}
func (UnimplementedDaemonServer) Disconnect(*DisconnectRequest, Daemon_DisconnectServer) error {
return status.Errorf(codes.Unimplemented, "method Disconnect not implemented")
}
func (UnimplementedDaemonServer) Proxy(*ConnectRequest, Daemon_ProxyServer) error {
return status.Errorf(codes.Unimplemented, "method Proxy not implemented")
}
func (UnimplementedDaemonServer) Leave(*LeaveRequest, Daemon_LeaveServer) error {
return status.Errorf(codes.Unimplemented, "method Leave not implemented")
}
func (UnimplementedDaemonServer) Clone(*CloneRequest, Daemon_CloneServer) error {
return status.Errorf(codes.Unimplemented, "method Clone not implemented")
}
func (UnimplementedDaemonServer) Remove(*RemoveRequest, Daemon_RemoveServer) error {
return status.Errorf(codes.Unimplemented, "method Remove not implemented")
}
func (UnimplementedDaemonServer) ConfigAdd(context.Context, *ConfigAddRequest) (*ConfigAddResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method ConfigAdd not implemented")
}
func (UnimplementedDaemonServer) ConfigRemove(context.Context, *ConfigRemoveRequest) (*ConfigRemoveResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method ConfigRemove not implemented")
}
func (UnimplementedDaemonServer) SshStart(context.Context, *SshStartRequest) (*SshStartResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method SshStart not implemented")
}
func (UnimplementedDaemonServer) SshStop(context.Context, *SshStopRequest) (*SshStopResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method SshStop not implemented")
}
func (UnimplementedDaemonServer) SshConnect(Daemon_SshConnectServer) error {
return status.Errorf(codes.Unimplemented, "method SshConnect not implemented")
}
func (UnimplementedDaemonServer) Logs(*LogRequest, Daemon_LogsServer) error {
return status.Errorf(codes.Unimplemented, "method Logs not implemented")
}
func (UnimplementedDaemonServer) List(context.Context, *ListRequest) (*ListResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method List not implemented")
}
func (UnimplementedDaemonServer) Get(context.Context, *GetRequest) (*GetResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method Get not implemented")
}
func (UnimplementedDaemonServer) Upgrade(context.Context, *UpgradeRequest) (*UpgradeResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method Upgrade not implemented")
}
func (UnimplementedDaemonServer) Status(context.Context, *StatusRequest) (*StatusResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method Status not implemented")
}
func (UnimplementedDaemonServer) Version(context.Context, *VersionRequest) (*VersionResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method Version not implemented")
}
func (UnimplementedDaemonServer) Reset(*ResetRequest, Daemon_ResetServer) error {
return status.Errorf(codes.Unimplemented, "method Reset not implemented")
}
func (UnimplementedDaemonServer) Quit(*QuitRequest, Daemon_QuitServer) error {
return status.Errorf(codes.Unimplemented, "method Quit not implemented")
}
func (UnimplementedDaemonServer) Identify(context.Context, *IdentifyRequest) (*IdentifyResponse, error) {
return nil, status.Errorf(codes.Unimplemented, "method Identify not implemented")
}
func (UnimplementedDaemonServer) mustEmbedUnimplementedDaemonServer() {}
// UnsafeDaemonServer may be embedded to opt out of forward compatibility for this service.
// Use of this interface is not recommended, as added methods to DaemonServer will
// result in compilation errors.
type UnsafeDaemonServer interface {
mustEmbedUnimplementedDaemonServer()
}
func RegisterDaemonServer(s grpc.ServiceRegistrar, srv DaemonServer) {
s.RegisterService(&Daemon_ServiceDesc, srv)
}
func _Daemon_Connect_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(ConnectRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(DaemonServer).Connect(m, &daemonConnectServer{stream})
}
type Daemon_ConnectServer interface {
Send(*ConnectResponse) error
grpc.ServerStream
}
type daemonConnectServer struct {
grpc.ServerStream
}
func (x *daemonConnectServer) Send(m *ConnectResponse) error {
return x.ServerStream.SendMsg(m)
}
func _Daemon_ConnectFork_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(ConnectRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(DaemonServer).ConnectFork(m, &daemonConnectForkServer{stream})
}
type Daemon_ConnectForkServer interface {
Send(*ConnectResponse) error
grpc.ServerStream
}
type daemonConnectForkServer struct {
grpc.ServerStream
}
func (x *daemonConnectForkServer) Send(m *ConnectResponse) error {
return x.ServerStream.SendMsg(m)
}
func _Daemon_Disconnect_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(DisconnectRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(DaemonServer).Disconnect(m, &daemonDisconnectServer{stream})
}
type Daemon_DisconnectServer interface {
Send(*DisconnectResponse) error
grpc.ServerStream
}
type daemonDisconnectServer struct {
grpc.ServerStream
}
func (x *daemonDisconnectServer) Send(m *DisconnectResponse) error {
return x.ServerStream.SendMsg(m)
}
func _Daemon_Proxy_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(ConnectRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(DaemonServer).Proxy(m, &daemonProxyServer{stream})
}
type Daemon_ProxyServer interface {
Send(*ConnectResponse) error
grpc.ServerStream
}
type daemonProxyServer struct {
grpc.ServerStream
}
func (x *daemonProxyServer) Send(m *ConnectResponse) error {
return x.ServerStream.SendMsg(m)
}
func _Daemon_Leave_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(LeaveRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(DaemonServer).Leave(m, &daemonLeaveServer{stream})
}
type Daemon_LeaveServer interface {
Send(*LeaveResponse) error
grpc.ServerStream
}
type daemonLeaveServer struct {
grpc.ServerStream
}
func (x *daemonLeaveServer) Send(m *LeaveResponse) error {
return x.ServerStream.SendMsg(m)
}
func _Daemon_Clone_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(CloneRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(DaemonServer).Clone(m, &daemonCloneServer{stream})
}
type Daemon_CloneServer interface {
Send(*CloneResponse) error
grpc.ServerStream
}
type daemonCloneServer struct {
grpc.ServerStream
}
func (x *daemonCloneServer) Send(m *CloneResponse) error {
return x.ServerStream.SendMsg(m)
}
func _Daemon_Remove_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(RemoveRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(DaemonServer).Remove(m, &daemonRemoveServer{stream})
}
type Daemon_RemoveServer interface {
Send(*RemoveResponse) error
grpc.ServerStream
}
type daemonRemoveServer struct {
grpc.ServerStream
}
func (x *daemonRemoveServer) Send(m *RemoveResponse) error {
return x.ServerStream.SendMsg(m)
}
func _Daemon_ConfigAdd_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(ConfigAddRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(DaemonServer).ConfigAdd(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: Daemon_ConfigAdd_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(DaemonServer).ConfigAdd(ctx, req.(*ConfigAddRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Daemon_ConfigRemove_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(ConfigRemoveRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(DaemonServer).ConfigRemove(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: Daemon_ConfigRemove_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(DaemonServer).ConfigRemove(ctx, req.(*ConfigRemoveRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Daemon_SshStart_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SshStartRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(DaemonServer).SshStart(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: Daemon_SshStart_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(DaemonServer).SshStart(ctx, req.(*SshStartRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Daemon_SshStop_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(SshStopRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(DaemonServer).SshStop(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: Daemon_SshStop_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(DaemonServer).SshStop(ctx, req.(*SshStopRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Daemon_SshConnect_Handler(srv interface{}, stream grpc.ServerStream) error {
return srv.(DaemonServer).SshConnect(&daemonSshConnectServer{stream})
}
type Daemon_SshConnectServer interface {
Send(*SshConnectResponse) error
Recv() (*SshConnectRequest, error)
grpc.ServerStream
}
type daemonSshConnectServer struct {
grpc.ServerStream
}
func (x *daemonSshConnectServer) Send(m *SshConnectResponse) error {
return x.ServerStream.SendMsg(m)
}
func (x *daemonSshConnectServer) Recv() (*SshConnectRequest, error) {
m := new(SshConnectRequest)
if err := x.ServerStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func _Daemon_Logs_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(LogRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(DaemonServer).Logs(m, &daemonLogsServer{stream})
}
type Daemon_LogsServer interface {
Send(*LogResponse) error
grpc.ServerStream
}
type daemonLogsServer struct {
grpc.ServerStream
}
func (x *daemonLogsServer) Send(m *LogResponse) error {
return x.ServerStream.SendMsg(m)
}
func _Daemon_List_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(ListRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(DaemonServer).List(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: Daemon_List_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(DaemonServer).List(ctx, req.(*ListRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Daemon_Get_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(GetRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(DaemonServer).Get(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: Daemon_Get_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(DaemonServer).Get(ctx, req.(*GetRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Daemon_Upgrade_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(UpgradeRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(DaemonServer).Upgrade(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: Daemon_Upgrade_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(DaemonServer).Upgrade(ctx, req.(*UpgradeRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Daemon_Status_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(StatusRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(DaemonServer).Status(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: Daemon_Status_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(DaemonServer).Status(ctx, req.(*StatusRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Daemon_Version_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(VersionRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(DaemonServer).Version(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: Daemon_Version_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(DaemonServer).Version(ctx, req.(*VersionRequest))
}
return interceptor(ctx, in, info, handler)
}
func _Daemon_Reset_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(ResetRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(DaemonServer).Reset(m, &daemonResetServer{stream})
}
type Daemon_ResetServer interface {
Send(*ResetResponse) error
grpc.ServerStream
}
type daemonResetServer struct {
grpc.ServerStream
}
func (x *daemonResetServer) Send(m *ResetResponse) error {
return x.ServerStream.SendMsg(m)
}
func _Daemon_Quit_Handler(srv interface{}, stream grpc.ServerStream) error {
m := new(QuitRequest)
if err := stream.RecvMsg(m); err != nil {
return err
}
return srv.(DaemonServer).Quit(m, &daemonQuitServer{stream})
}
type Daemon_QuitServer interface {
Send(*QuitResponse) error
grpc.ServerStream
}
type daemonQuitServer struct {
grpc.ServerStream
}
func (x *daemonQuitServer) Send(m *QuitResponse) error {
return x.ServerStream.SendMsg(m)
}
func _Daemon_Identify_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
in := new(IdentifyRequest)
if err := dec(in); err != nil {
return nil, err
}
if interceptor == nil {
return srv.(DaemonServer).Identify(ctx, in)
}
info := &grpc.UnaryServerInfo{
Server: srv,
FullMethod: Daemon_Identify_FullMethodName,
}
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
return srv.(DaemonServer).Identify(ctx, req.(*IdentifyRequest))
}
return interceptor(ctx, in, info, handler)
}
// Daemon_ServiceDesc is the grpc.ServiceDesc for Daemon service.
// It's only intended for direct use with grpc.RegisterService,
// and not to be introspected or modified (even as a copy)
var Daemon_ServiceDesc = grpc.ServiceDesc{
ServiceName: "rpc.Daemon",
HandlerType: (*DaemonServer)(nil),
Methods: []grpc.MethodDesc{
{
MethodName: "ConfigAdd",
Handler: _Daemon_ConfigAdd_Handler,
},
{
MethodName: "ConfigRemove",
Handler: _Daemon_ConfigRemove_Handler,
},
{
MethodName: "SshStart",
Handler: _Daemon_SshStart_Handler,
},
{
MethodName: "SshStop",
Handler: _Daemon_SshStop_Handler,
},
{
MethodName: "List",
Handler: _Daemon_List_Handler,
},
{
MethodName: "Get",
Handler: _Daemon_Get_Handler,
},
{
MethodName: "Upgrade",
Handler: _Daemon_Upgrade_Handler,
},
{
MethodName: "Status",
Handler: _Daemon_Status_Handler,
},
{
MethodName: "Version",
Handler: _Daemon_Version_Handler,
},
{
MethodName: "Identify",
Handler: _Daemon_Identify_Handler,
},
},
Streams: []grpc.StreamDesc{
{
StreamName: "Connect",
Handler: _Daemon_Connect_Handler,
ServerStreams: true,
},
{
StreamName: "ConnectFork",
Handler: _Daemon_ConnectFork_Handler,
ServerStreams: true,
},
{
StreamName: "Disconnect",
Handler: _Daemon_Disconnect_Handler,
ServerStreams: true,
},
{
StreamName: "Proxy",
Handler: _Daemon_Proxy_Handler,
ServerStreams: true,
},
{
StreamName: "Leave",
Handler: _Daemon_Leave_Handler,
ServerStreams: true,
},
{
StreamName: "Clone",
Handler: _Daemon_Clone_Handler,
ServerStreams: true,
},
{
StreamName: "Remove",
Handler: _Daemon_Remove_Handler,
ServerStreams: true,
},
{
StreamName: "SshConnect",
Handler: _Daemon_SshConnect_Handler,
ServerStreams: true,
ClientStreams: true,
},
{
StreamName: "Logs",
Handler: _Daemon_Logs_Handler,
ServerStreams: true,
},
{
StreamName: "Reset",
Handler: _Daemon_Reset_Handler,
ServerStreams: true,
},
{
StreamName: "Quit",
Handler: _Daemon_Quit_Handler,
ServerStreams: true,
},
},
Metadata: "daemon.proto",
}