mirror of
https://github.com/sonr-io/sonr.git
synced 2026-08-02 09:21:39 +00:00
352 lines
14 KiB
Go
352 lines
14 KiB
Go
// Code generated by protoc-gen-go-grpc. DO NOT EDIT.
|
|
// versions:
|
|
// - protoc-gen-go-grpc v1.3.0
|
|
// - protoc (unknown)
|
|
// source: dwn/v1/tx.proto
|
|
|
|
package dwnv1
|
|
|
|
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 (
|
|
Msg_UpdateParams_FullMethodName = "/dwn.v1.Msg/UpdateParams"
|
|
Msg_RecordsWrite_FullMethodName = "/dwn.v1.Msg/RecordsWrite"
|
|
Msg_RecordsDelete_FullMethodName = "/dwn.v1.Msg/RecordsDelete"
|
|
Msg_ProtocolsConfigure_FullMethodName = "/dwn.v1.Msg/ProtocolsConfigure"
|
|
Msg_PermissionsGrant_FullMethodName = "/dwn.v1.Msg/PermissionsGrant"
|
|
Msg_PermissionsRevoke_FullMethodName = "/dwn.v1.Msg/PermissionsRevoke"
|
|
Msg_RotateVaultKeys_FullMethodName = "/dwn.v1.Msg/RotateVaultKeys"
|
|
)
|
|
|
|
// MsgClient is the client API for Msg 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 MsgClient interface {
|
|
// UpdateParams defines a governance operation for updating the parameters.
|
|
UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error)
|
|
// DWN Records Operations
|
|
//
|
|
// {{.MethodDescriptorProto.Name}} is a call with the method(s) {{$first := true}}{{range .Bindings}}{{if $first}}{{$first = false}}{{else}}, {{end}}{{.HTTPMethod}}{{end}} within the "{{.Service.Name}}" service.
|
|
// It takes in "{{.RequestType.Name}}" and returns a "{{.ResponseType.Name}}".
|
|
//
|
|
// {{import "dwn_docs.md"}}
|
|
RecordsWrite(ctx context.Context, in *MsgRecordsWrite, opts ...grpc.CallOption) (*MsgRecordsWriteResponse, error)
|
|
RecordsDelete(ctx context.Context, in *MsgRecordsDelete, opts ...grpc.CallOption) (*MsgRecordsDeleteResponse, error)
|
|
// DWN Protocols Operations
|
|
ProtocolsConfigure(ctx context.Context, in *MsgProtocolsConfigure, opts ...grpc.CallOption) (*MsgProtocolsConfigureResponse, error)
|
|
// DWN Permissions Operations
|
|
PermissionsGrant(ctx context.Context, in *MsgPermissionsGrant, opts ...grpc.CallOption) (*MsgPermissionsGrantResponse, error)
|
|
PermissionsRevoke(ctx context.Context, in *MsgPermissionsRevoke, opts ...grpc.CallOption) (*MsgPermissionsRevokeResponse, error)
|
|
// DWN Vault Operations
|
|
RotateVaultKeys(ctx context.Context, in *MsgRotateVaultKeys, opts ...grpc.CallOption) (*MsgRotateVaultKeysResponse, error)
|
|
}
|
|
|
|
type msgClient struct {
|
|
cc grpc.ClientConnInterface
|
|
}
|
|
|
|
func NewMsgClient(cc grpc.ClientConnInterface) MsgClient {
|
|
return &msgClient{cc}
|
|
}
|
|
|
|
func (c *msgClient) UpdateParams(ctx context.Context, in *MsgUpdateParams, opts ...grpc.CallOption) (*MsgUpdateParamsResponse, error) {
|
|
out := new(MsgUpdateParamsResponse)
|
|
err := c.cc.Invoke(ctx, Msg_UpdateParams_FullMethodName, in, out, opts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
func (c *msgClient) RecordsWrite(ctx context.Context, in *MsgRecordsWrite, opts ...grpc.CallOption) (*MsgRecordsWriteResponse, error) {
|
|
out := new(MsgRecordsWriteResponse)
|
|
err := c.cc.Invoke(ctx, Msg_RecordsWrite_FullMethodName, in, out, opts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
func (c *msgClient) RecordsDelete(ctx context.Context, in *MsgRecordsDelete, opts ...grpc.CallOption) (*MsgRecordsDeleteResponse, error) {
|
|
out := new(MsgRecordsDeleteResponse)
|
|
err := c.cc.Invoke(ctx, Msg_RecordsDelete_FullMethodName, in, out, opts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
func (c *msgClient) ProtocolsConfigure(ctx context.Context, in *MsgProtocolsConfigure, opts ...grpc.CallOption) (*MsgProtocolsConfigureResponse, error) {
|
|
out := new(MsgProtocolsConfigureResponse)
|
|
err := c.cc.Invoke(ctx, Msg_ProtocolsConfigure_FullMethodName, in, out, opts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
func (c *msgClient) PermissionsGrant(ctx context.Context, in *MsgPermissionsGrant, opts ...grpc.CallOption) (*MsgPermissionsGrantResponse, error) {
|
|
out := new(MsgPermissionsGrantResponse)
|
|
err := c.cc.Invoke(ctx, Msg_PermissionsGrant_FullMethodName, in, out, opts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
func (c *msgClient) PermissionsRevoke(ctx context.Context, in *MsgPermissionsRevoke, opts ...grpc.CallOption) (*MsgPermissionsRevokeResponse, error) {
|
|
out := new(MsgPermissionsRevokeResponse)
|
|
err := c.cc.Invoke(ctx, Msg_PermissionsRevoke_FullMethodName, in, out, opts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
func (c *msgClient) RotateVaultKeys(ctx context.Context, in *MsgRotateVaultKeys, opts ...grpc.CallOption) (*MsgRotateVaultKeysResponse, error) {
|
|
out := new(MsgRotateVaultKeysResponse)
|
|
err := c.cc.Invoke(ctx, Msg_RotateVaultKeys_FullMethodName, in, out, opts...)
|
|
if err != nil {
|
|
return nil, err
|
|
}
|
|
return out, nil
|
|
}
|
|
|
|
// MsgServer is the server API for Msg service.
|
|
// All implementations must embed UnimplementedMsgServer
|
|
// for forward compatibility
|
|
type MsgServer interface {
|
|
// UpdateParams defines a governance operation for updating the parameters.
|
|
UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error)
|
|
// DWN Records Operations
|
|
//
|
|
// {{.MethodDescriptorProto.Name}} is a call with the method(s) {{$first := true}}{{range .Bindings}}{{if $first}}{{$first = false}}{{else}}, {{end}}{{.HTTPMethod}}{{end}} within the "{{.Service.Name}}" service.
|
|
// It takes in "{{.RequestType.Name}}" and returns a "{{.ResponseType.Name}}".
|
|
//
|
|
// {{import "dwn_docs.md"}}
|
|
RecordsWrite(context.Context, *MsgRecordsWrite) (*MsgRecordsWriteResponse, error)
|
|
RecordsDelete(context.Context, *MsgRecordsDelete) (*MsgRecordsDeleteResponse, error)
|
|
// DWN Protocols Operations
|
|
ProtocolsConfigure(context.Context, *MsgProtocolsConfigure) (*MsgProtocolsConfigureResponse, error)
|
|
// DWN Permissions Operations
|
|
PermissionsGrant(context.Context, *MsgPermissionsGrant) (*MsgPermissionsGrantResponse, error)
|
|
PermissionsRevoke(context.Context, *MsgPermissionsRevoke) (*MsgPermissionsRevokeResponse, error)
|
|
// DWN Vault Operations
|
|
RotateVaultKeys(context.Context, *MsgRotateVaultKeys) (*MsgRotateVaultKeysResponse, error)
|
|
mustEmbedUnimplementedMsgServer()
|
|
}
|
|
|
|
// UnimplementedMsgServer must be embedded to have forward compatible implementations.
|
|
type UnimplementedMsgServer struct {
|
|
}
|
|
|
|
func (UnimplementedMsgServer) UpdateParams(context.Context, *MsgUpdateParams) (*MsgUpdateParamsResponse, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method UpdateParams not implemented")
|
|
}
|
|
func (UnimplementedMsgServer) RecordsWrite(context.Context, *MsgRecordsWrite) (*MsgRecordsWriteResponse, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method RecordsWrite not implemented")
|
|
}
|
|
func (UnimplementedMsgServer) RecordsDelete(context.Context, *MsgRecordsDelete) (*MsgRecordsDeleteResponse, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method RecordsDelete not implemented")
|
|
}
|
|
func (UnimplementedMsgServer) ProtocolsConfigure(context.Context, *MsgProtocolsConfigure) (*MsgProtocolsConfigureResponse, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method ProtocolsConfigure not implemented")
|
|
}
|
|
func (UnimplementedMsgServer) PermissionsGrant(context.Context, *MsgPermissionsGrant) (*MsgPermissionsGrantResponse, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method PermissionsGrant not implemented")
|
|
}
|
|
func (UnimplementedMsgServer) PermissionsRevoke(context.Context, *MsgPermissionsRevoke) (*MsgPermissionsRevokeResponse, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method PermissionsRevoke not implemented")
|
|
}
|
|
func (UnimplementedMsgServer) RotateVaultKeys(context.Context, *MsgRotateVaultKeys) (*MsgRotateVaultKeysResponse, error) {
|
|
return nil, status.Errorf(codes.Unimplemented, "method RotateVaultKeys not implemented")
|
|
}
|
|
func (UnimplementedMsgServer) mustEmbedUnimplementedMsgServer() {}
|
|
|
|
// UnsafeMsgServer may be embedded to opt out of forward compatibility for this service.
|
|
// Use of this interface is not recommended, as added methods to MsgServer will
|
|
// result in compilation errors.
|
|
type UnsafeMsgServer interface {
|
|
mustEmbedUnimplementedMsgServer()
|
|
}
|
|
|
|
func RegisterMsgServer(s grpc.ServiceRegistrar, srv MsgServer) {
|
|
s.RegisterService(&Msg_ServiceDesc, srv)
|
|
}
|
|
|
|
func _Msg_UpdateParams_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(MsgUpdateParams)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(MsgServer).UpdateParams(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: Msg_UpdateParams_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(MsgServer).UpdateParams(ctx, req.(*MsgUpdateParams))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
func _Msg_RecordsWrite_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(MsgRecordsWrite)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(MsgServer).RecordsWrite(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: Msg_RecordsWrite_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(MsgServer).RecordsWrite(ctx, req.(*MsgRecordsWrite))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
func _Msg_RecordsDelete_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(MsgRecordsDelete)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(MsgServer).RecordsDelete(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: Msg_RecordsDelete_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(MsgServer).RecordsDelete(ctx, req.(*MsgRecordsDelete))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
func _Msg_ProtocolsConfigure_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(MsgProtocolsConfigure)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(MsgServer).ProtocolsConfigure(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: Msg_ProtocolsConfigure_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(MsgServer).ProtocolsConfigure(ctx, req.(*MsgProtocolsConfigure))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
func _Msg_PermissionsGrant_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(MsgPermissionsGrant)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(MsgServer).PermissionsGrant(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: Msg_PermissionsGrant_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(MsgServer).PermissionsGrant(ctx, req.(*MsgPermissionsGrant))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
func _Msg_PermissionsRevoke_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(MsgPermissionsRevoke)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(MsgServer).PermissionsRevoke(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: Msg_PermissionsRevoke_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(MsgServer).PermissionsRevoke(ctx, req.(*MsgPermissionsRevoke))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
func _Msg_RotateVaultKeys_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
|
|
in := new(MsgRotateVaultKeys)
|
|
if err := dec(in); err != nil {
|
|
return nil, err
|
|
}
|
|
if interceptor == nil {
|
|
return srv.(MsgServer).RotateVaultKeys(ctx, in)
|
|
}
|
|
info := &grpc.UnaryServerInfo{
|
|
Server: srv,
|
|
FullMethod: Msg_RotateVaultKeys_FullMethodName,
|
|
}
|
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) {
|
|
return srv.(MsgServer).RotateVaultKeys(ctx, req.(*MsgRotateVaultKeys))
|
|
}
|
|
return interceptor(ctx, in, info, handler)
|
|
}
|
|
|
|
// Msg_ServiceDesc is the grpc.ServiceDesc for Msg service.
|
|
// It's only intended for direct use with grpc.RegisterService,
|
|
// and not to be introspected or modified (even as a copy)
|
|
var Msg_ServiceDesc = grpc.ServiceDesc{
|
|
ServiceName: "dwn.v1.Msg",
|
|
HandlerType: (*MsgServer)(nil),
|
|
Methods: []grpc.MethodDesc{
|
|
{
|
|
MethodName: "UpdateParams",
|
|
Handler: _Msg_UpdateParams_Handler,
|
|
},
|
|
{
|
|
MethodName: "RecordsWrite",
|
|
Handler: _Msg_RecordsWrite_Handler,
|
|
},
|
|
{
|
|
MethodName: "RecordsDelete",
|
|
Handler: _Msg_RecordsDelete_Handler,
|
|
},
|
|
{
|
|
MethodName: "ProtocolsConfigure",
|
|
Handler: _Msg_ProtocolsConfigure_Handler,
|
|
},
|
|
{
|
|
MethodName: "PermissionsGrant",
|
|
Handler: _Msg_PermissionsGrant_Handler,
|
|
},
|
|
{
|
|
MethodName: "PermissionsRevoke",
|
|
Handler: _Msg_PermissionsRevoke_Handler,
|
|
},
|
|
{
|
|
MethodName: "RotateVaultKeys",
|
|
Handler: _Msg_RotateVaultKeys_Handler,
|
|
},
|
|
},
|
|
Streams: []grpc.StreamDesc{},
|
|
Metadata: "dwn/v1/tx.proto",
|
|
}
|