applications

package
v0.0.0-...-545bd39 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 28, 2023 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthService        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowService          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupService = fmt.Errorf("proto: unexpected end of group")
)

Functions

func RegisterApplicationServiceServer

func RegisterApplicationServiceServer(s grpc1.Server, srv ApplicationServiceServer)

Types

type ApplicationServer

type ApplicationServer struct {
	// contains filtered or unexported fields
}

func NewServer

func NewServer(handler *Handler) *ApplicationServer

func NewServerFromEnvVariables

func NewServerFromEnvVariables(db Database) *ApplicationServer

func (ApplicationServer) DeleteApp

func (a ApplicationServer) DeleteApp(ctx context.Context, request *DeleteAppRequest) (*emptypb.Empty, error)

type ApplicationServiceClient

type ApplicationServiceClient interface {
	// DeleteApp allows to delete an application
	DeleteApp(ctx context.Context, in *DeleteAppRequest, opts ...grpc.CallOption) (*emptypb.Empty, error)
}

ApplicationServiceClient is the client API for ApplicationService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewApplicationServiceClient

func NewApplicationServiceClient(cc grpc1.ClientConn) ApplicationServiceClient

type ApplicationServiceServer

type ApplicationServiceServer interface {
	// DeleteApp allows to delete an application
	DeleteApp(context.Context, *DeleteAppRequest) (*emptypb.Empty, error)
}

ApplicationServiceServer is the server API for ApplicationService service.

type Database

type Database interface {
	IsUserAdminOfApp(desmosAddress string, appID string) (bool, error)
	DeleteApp(appID string) error
}

type DeleteAppRequest

type DeleteAppRequest struct {
	AppId string `protobuf:"bytes,1,opt,name=app_id,json=appId,proto3" json:"app_id,omitempty"`
}

func (*DeleteAppRequest) Descriptor

func (*DeleteAppRequest) Descriptor() ([]byte, []int)

func (*DeleteAppRequest) GetAppId

func (m *DeleteAppRequest) GetAppId() string

func (*DeleteAppRequest) Marshal

func (m *DeleteAppRequest) Marshal() (dAtA []byte, err error)

func (*DeleteAppRequest) MarshalTo

func (m *DeleteAppRequest) MarshalTo(dAtA []byte) (int, error)

func (*DeleteAppRequest) MarshalToSizedBuffer

func (m *DeleteAppRequest) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*DeleteAppRequest) ProtoMessage

func (*DeleteAppRequest) ProtoMessage()

func (*DeleteAppRequest) Reset

func (m *DeleteAppRequest) Reset()

func (*DeleteAppRequest) Size

func (m *DeleteAppRequest) Size() (n int)

func (*DeleteAppRequest) String

func (m *DeleteAppRequest) String() string

func (*DeleteAppRequest) Unmarshal

func (m *DeleteAppRequest) Unmarshal(dAtA []byte) error

func (*DeleteAppRequest) XXX_DiscardUnknown

func (m *DeleteAppRequest) XXX_DiscardUnknown()

func (*DeleteAppRequest) XXX_Marshal

func (m *DeleteAppRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DeleteAppRequest) XXX_Merge

func (m *DeleteAppRequest) XXX_Merge(src proto.Message)

func (*DeleteAppRequest) XXX_Size

func (m *DeleteAppRequest) XXX_Size() int

func (*DeleteAppRequest) XXX_Unmarshal

func (m *DeleteAppRequest) XXX_Unmarshal(b []byte) error

type DeleteApplicationRequest

type DeleteApplicationRequest struct {
	UserAddress string
	AppID       string
}

func NewDeleteApplicationRequest

func NewDeleteApplicationRequest(desmosAddress string, appID string) *DeleteApplicationRequest

type Handler

type Handler struct {
	// contains filtered or unexported fields
}

func NewHandler

func NewHandler(db Database) *Handler

NewHandler allows to build a new Handler instance

func (*Handler) HandleDeleteApplicationRequest

func (h *Handler) HandleDeleteApplicationRequest(req *DeleteApplicationRequest) error

HandleDeleteApplicationRequest handles the request to delete an application

type UnimplementedApplicationServiceServer

type UnimplementedApplicationServiceServer struct {
}

UnimplementedApplicationServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedApplicationServiceServer) DeleteApp

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL