config

package
v0.10.5 Latest Latest
Warning

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

Go to latest
Published: Jul 28, 2022 License: MIT Imports: 29 Imported by: 0

Documentation

Overview

Package config contains

  • chaincode methods names {service_name}Chaincode_{method_name}
  • chaincode interface definition {service_name}Chaincode
  • chaincode gateway definition {service_name}}Gateway
  • chaincode service to cckit router registration func

Package config is a reverse proxy.

It translates gRPC into RESTful JSON APIs.

Index

Constants

View Source
const (

	// ConfigServiceChaincodeMethodPrefix allows to use multiple services with same method names in one chaincode
	ConfigServiceChaincodeMethodPrefix = ""

	ConfigServiceChaincode_GetConfig = ConfigServiceChaincodeMethodPrefix + "GetConfig"

	ConfigServiceChaincode_SetConfig = ConfigServiceChaincodeMethodPrefix + "SetConfig"

	ConfigServiceChaincode_GetToken = ConfigServiceChaincodeMethodPrefix + "GetToken"

	ConfigServiceChaincode_GetDefaultToken = ConfigServiceChaincodeMethodPrefix + "GetDefaultToken"

	ConfigServiceChaincode_CreateTokenType = ConfigServiceChaincodeMethodPrefix + "CreateTokenType"

	ConfigServiceChaincode_GetTokenType = ConfigServiceChaincodeMethodPrefix + "GetTokenType"

	ConfigServiceChaincode_ListTokenTypes = ConfigServiceChaincodeMethodPrefix + "ListTokenTypes"

	ConfigServiceChaincode_UpdateTokenType = ConfigServiceChaincodeMethodPrefix + "UpdateTokenType"

	ConfigServiceChaincode_DeleteTokenType = ConfigServiceChaincodeMethodPrefix + "DeleteTokenType"

	ConfigServiceChaincode_GetTokenGroups = ConfigServiceChaincodeMethodPrefix + "GetTokenGroups"

	ConfigServiceChaincode_CreateTokenGroup = ConfigServiceChaincodeMethodPrefix + "CreateTokenGroup"

	ConfigServiceChaincode_GetTokenGroup = ConfigServiceChaincodeMethodPrefix + "GetTokenGroup"

	ConfigServiceChaincode_DeleteTokenGroup = ConfigServiceChaincodeMethodPrefix + "DeleteTokenGroup"
)

ConfigServiceChaincode method names

Variables

View Source
var (
	TokenGroupType_name = map[int32]string{
		0: "OPTIONAL",
		1: "REQUIRED",
		3: "NOT_ALLOWED",
	}
	TokenGroupType_value = map[string]int32{
		"OPTIONAL":    0,
		"REQUIRED":    1,
		"NOT_ALLOWED": 3,
	}
)

Enum value maps for TokenGroupType.

View Source
var (
	StateMappings = m.StateMappings{}.
					Add(&TokenType{},
			m.PKeySchema(&TokenTypeId{}),
			m.List(&TokenTypes{})).
		Add(&TokenGroup{},
			m.PKeySchema(&TokenGroupId{}),
			m.List(&TokenGroups{})).
		Add(&Config{},
			m.WithConstPKey())

	EventMappings = m.EventMappings{}.
					Add(&TokenTypeCreated{}).
					Add(&TokenGroupCreated{})
)
View Source
var ConfigServiceSwagger []byte
View Source
var (
	ErrTokenAlreadyExists = errors.New(`token already exists`)
)
View Source
var File_token_service_config_config_proto protoreflect.FileDescriptor

Functions

func CreateDefaultToken

func CreateDefaultToken(
	ctx router.Context, configSvc ConfigServiceChaincode, createToken *CreateTokenTypeRequest) ([]string, error)

func Event

func Event(ctx router.Context) state.Event

Event with chaincode mappings

func RegisterConfigServiceChaincode

func RegisterConfigServiceChaincode(r *cckit_router.Group, cc ConfigServiceChaincode) error

RegisterConfigServiceChaincode registers service methods as chaincode router handlers

func RegisterConfigServiceHandler

func RegisterConfigServiceHandler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error

RegisterConfigServiceHandler registers the http handlers for service ConfigService to "mux". The handlers forward requests to the grpc endpoint over "conn".

func RegisterConfigServiceHandlerClient

func RegisterConfigServiceHandlerClient(ctx context.Context, mux *runtime.ServeMux, client ConfigServiceClient) error

RegisterConfigServiceHandlerClient registers the http handlers for service ConfigService to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "ConfigServiceClient". Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "ConfigServiceClient" doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in "ConfigServiceClient" to call the correct interceptors.

func RegisterConfigServiceHandlerFromEndpoint

func RegisterConfigServiceHandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error)

RegisterConfigServiceHandlerFromEndpoint is same as RegisterConfigServiceHandler but automatically dials to "endpoint" and closes the connection when "ctx" gets done.

func RegisterConfigServiceHandlerServer

func RegisterConfigServiceHandlerServer(ctx context.Context, mux *runtime.ServeMux, server ConfigServiceServer) error

RegisterConfigServiceHandlerServer registers the http handlers for service ConfigService to "mux". UnaryRPC :call ConfigServiceServer directly. StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906. Note that using this registration option will cause many gRPC library features to stop working. Consider using RegisterConfigServiceHandlerFromEndpoint instead.

func RegisterConfigServiceServer

func RegisterConfigServiceServer(s *grpc.Server, srv ConfigServiceServer)

func State

func State(ctx router.Context) m.MappedState

State with chaincode mappings

func TokenByTypeGroup

func TokenByTypeGroup(tokenType *TokenType, tokenGroup *TokenGroup) []string

Types

type Config

type Config struct {
	DefaultToken      []string `protobuf:"bytes,1,rep,name=default_token,json=defaultToken,proto3" json:"default_token,omitempty"`
	MaxTokenTypesNum  int32    `protobuf:"varint,2,opt,name=max_token_types_num,json=maxTokenTypesNum,proto3" json:"max_token_types_num,omitempty"`
	MaxTokenGroupsNum int32    `protobuf:"varint,3,opt,name=max_token_groups_num,json=maxTokenGroupsNum,proto3" json:"max_token_groups_num,omitempty"`
	// contains filtered or unexported fields
}

func (*Config) Descriptor deprecated

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

Deprecated: Use Config.ProtoReflect.Descriptor instead.

func (*Config) GetDefaultToken

func (x *Config) GetDefaultToken() []string

func (*Config) GetMaxTokenGroupsNum

func (x *Config) GetMaxTokenGroupsNum() int32

func (*Config) GetMaxTokenTypesNum

func (x *Config) GetMaxTokenTypesNum() int32

func (*Config) ProtoMessage

func (*Config) ProtoMessage()

func (*Config) ProtoReflect

func (x *Config) ProtoReflect() protoreflect.Message

func (*Config) Reset

func (x *Config) Reset()

func (*Config) String

func (x *Config) String() string

func (*Config) Validate

func (this *Config) Validate() error

type ConfigServiceChaincode

ConfigServiceChaincode chaincode methods interface

type ConfigServiceChaincodeLocalResolver

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

ConfigServiceChaincodeResolver interface for service resolver

func (*ConfigServiceChaincodeLocalResolver) Resolve

type ConfigServiceChaincodeLocatorResolver

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

ConfigServiceChaincodeResolver interface for service resolver

func (*ConfigServiceChaincodeLocatorResolver) Resolve

type ConfigServiceChaincodeResolver

type ConfigServiceChaincodeResolver interface {
	Resolve(ctx cckit_router.Context) (ConfigServiceChaincode, error)
}

ConfigServiceChaincodeResolver interface for service resolver

type ConfigServiceChaincodeStubInvoker

type ConfigServiceChaincodeStubInvoker struct {
	Invoker cckit_gateway.ChaincodeStubInvoker
}

func (*ConfigServiceChaincodeStubInvoker) CreateTokenGroup

func (*ConfigServiceChaincodeStubInvoker) CreateTokenType

func (*ConfigServiceChaincodeStubInvoker) DeleteTokenGroup

func (*ConfigServiceChaincodeStubInvoker) DeleteTokenType

func (*ConfigServiceChaincodeStubInvoker) GetConfig

func (*ConfigServiceChaincodeStubInvoker) GetDefaultToken

func (*ConfigServiceChaincodeStubInvoker) GetToken

func (*ConfigServiceChaincodeStubInvoker) GetTokenGroup

func (*ConfigServiceChaincodeStubInvoker) GetTokenGroups

func (*ConfigServiceChaincodeStubInvoker) GetTokenType

func (*ConfigServiceChaincodeStubInvoker) ListTokenTypes

func (*ConfigServiceChaincodeStubInvoker) SetConfig

func (*ConfigServiceChaincodeStubInvoker) UpdateTokenType

type ConfigServiceClient

type ConfigServiceClient interface {
	GetConfig(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*Config, error)
	SetConfig(ctx context.Context, in *Config, opts ...grpc.CallOption) (*Config, error)
	GetToken(ctx context.Context, in *TokenId, opts ...grpc.CallOption) (*Token, error)
	GetDefaultToken(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*Token, error)
	CreateTokenType(ctx context.Context, in *CreateTokenTypeRequest, opts ...grpc.CallOption) (*TokenType, error)
	GetTokenType(ctx context.Context, in *TokenTypeId, opts ...grpc.CallOption) (*TokenType, error)
	ListTokenTypes(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*TokenTypes, error)
	UpdateTokenType(ctx context.Context, in *UpdateTokenTypeRequest, opts ...grpc.CallOption) (*TokenType, error)
	DeleteTokenType(ctx context.Context, in *TokenTypeId, opts ...grpc.CallOption) (*TokenType, error)
	GetTokenGroups(ctx context.Context, in *TokenTypeId, opts ...grpc.CallOption) (*TokenGroups, error)
	CreateTokenGroup(ctx context.Context, in *CreateTokenGroupRequest, opts ...grpc.CallOption) (*TokenGroup, error)
	GetTokenGroup(ctx context.Context, in *TokenGroupId, opts ...grpc.CallOption) (*TokenGroup, error)
	DeleteTokenGroup(ctx context.Context, in *TokenGroupId, opts ...grpc.CallOption) (*Token, error)
}

ConfigServiceClient is the client API for ConfigService service.

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

type ConfigServiceGateway

type ConfigServiceGateway struct {
	ChaincodeInstance cckit_gateway.ChaincodeInstance
}

gateway implementation gateway can be used as kind of SDK, GRPC or REST server ( via grpc-gateway or clay )

func NewConfigServiceGateway

func NewConfigServiceGateway(sdk cckit_sdk.SDK, channel, chaincode string, opts ...cckit_gateway.Opt) *ConfigServiceGateway

NewConfigServiceGateway creates gateway to access chaincode method via chaincode service

func NewConfigServiceGatewayFromInstance

func NewConfigServiceGatewayFromInstance(chaincodeInstance cckit_gateway.ChaincodeInstance) *ConfigServiceGateway

func (*ConfigServiceGateway) CreateTokenGroup

func (c *ConfigServiceGateway) CreateTokenGroup(ctx context.Context, in *CreateTokenGroupRequest) (*TokenGroup, error)

func (*ConfigServiceGateway) CreateTokenType

func (c *ConfigServiceGateway) CreateTokenType(ctx context.Context, in *CreateTokenTypeRequest) (*TokenType, error)

func (*ConfigServiceGateway) DeleteTokenGroup

func (c *ConfigServiceGateway) DeleteTokenGroup(ctx context.Context, in *TokenGroupId) (*Token, error)

func (*ConfigServiceGateway) DeleteTokenType

func (c *ConfigServiceGateway) DeleteTokenType(ctx context.Context, in *TokenTypeId) (*TokenType, error)

func (*ConfigServiceGateway) GetConfig

func (c *ConfigServiceGateway) GetConfig(ctx context.Context, in *emptypb.Empty) (*Config, error)

func (*ConfigServiceGateway) GetDefaultToken

func (c *ConfigServiceGateway) GetDefaultToken(ctx context.Context, in *emptypb.Empty) (*Token, error)

func (*ConfigServiceGateway) GetToken

func (c *ConfigServiceGateway) GetToken(ctx context.Context, in *TokenId) (*Token, error)

func (*ConfigServiceGateway) GetTokenGroup

func (c *ConfigServiceGateway) GetTokenGroup(ctx context.Context, in *TokenGroupId) (*TokenGroup, error)

func (*ConfigServiceGateway) GetTokenGroups

func (c *ConfigServiceGateway) GetTokenGroups(ctx context.Context, in *TokenTypeId) (*TokenGroups, error)

func (*ConfigServiceGateway) GetTokenType

func (c *ConfigServiceGateway) GetTokenType(ctx context.Context, in *TokenTypeId) (*TokenType, error)

func (*ConfigServiceGateway) Invoker

func (*ConfigServiceGateway) ListTokenTypes

func (c *ConfigServiceGateway) ListTokenTypes(ctx context.Context, in *emptypb.Empty) (*TokenTypes, error)

func (*ConfigServiceGateway) ServiceDef

ServiceDef returns service definition

func (*ConfigServiceGateway) SetConfig

func (c *ConfigServiceGateway) SetConfig(ctx context.Context, in *Config) (*Config, error)

func (*ConfigServiceGateway) UpdateTokenType

func (c *ConfigServiceGateway) UpdateTokenType(ctx context.Context, in *UpdateTokenTypeRequest) (*TokenType, error)

type ConfigServiceServer

type ConfigServiceServer interface {
	GetConfig(context.Context, *emptypb.Empty) (*Config, error)
	SetConfig(context.Context, *Config) (*Config, error)
	GetToken(context.Context, *TokenId) (*Token, error)
	GetDefaultToken(context.Context, *emptypb.Empty) (*Token, error)
	CreateTokenType(context.Context, *CreateTokenTypeRequest) (*TokenType, error)
	GetTokenType(context.Context, *TokenTypeId) (*TokenType, error)
	ListTokenTypes(context.Context, *emptypb.Empty) (*TokenTypes, error)
	UpdateTokenType(context.Context, *UpdateTokenTypeRequest) (*TokenType, error)
	DeleteTokenType(context.Context, *TokenTypeId) (*TokenType, error)
	GetTokenGroups(context.Context, *TokenTypeId) (*TokenGroups, error)
	CreateTokenGroup(context.Context, *CreateTokenGroupRequest) (*TokenGroup, error)
	GetTokenGroup(context.Context, *TokenGroupId) (*TokenGroup, error)
	DeleteTokenGroup(context.Context, *TokenGroupId) (*Token, error)
}

ConfigServiceServer is the server API for ConfigService service.

type CreateTokenGroupRequest

type CreateTokenGroupRequest struct {
	Name        []string            `protobuf:"bytes,1,rep,name=name,proto3" json:"name,omitempty"`
	TokenType   string              `protobuf:"bytes,2,opt,name=token_type,json=tokenType,proto3" json:"token_type,omitempty"`
	TotalSupply uint64              `protobuf:"varint,3,opt,name=total_supply,json=totalSupply,proto3" json:"total_supply,omitempty"`
	Meta        []*TokenMetaRequest `protobuf:"bytes,4,rep,name=meta,proto3" json:"meta,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateTokenGroupRequest) Descriptor deprecated

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

Deprecated: Use CreateTokenGroupRequest.ProtoReflect.Descriptor instead.

func (*CreateTokenGroupRequest) GetMeta

func (x *CreateTokenGroupRequest) GetMeta() []*TokenMetaRequest

func (*CreateTokenGroupRequest) GetName

func (x *CreateTokenGroupRequest) GetName() []string

func (*CreateTokenGroupRequest) GetTokenType

func (x *CreateTokenGroupRequest) GetTokenType() string

func (*CreateTokenGroupRequest) GetTotalSupply

func (x *CreateTokenGroupRequest) GetTotalSupply() uint64

func (*CreateTokenGroupRequest) ProtoMessage

func (*CreateTokenGroupRequest) ProtoMessage()

func (*CreateTokenGroupRequest) ProtoReflect

func (x *CreateTokenGroupRequest) ProtoReflect() protoreflect.Message

func (*CreateTokenGroupRequest) Reset

func (x *CreateTokenGroupRequest) Reset()

func (*CreateTokenGroupRequest) String

func (x *CreateTokenGroupRequest) String() string

func (*CreateTokenGroupRequest) Validate

func (this *CreateTokenGroupRequest) Validate() error

type CreateTokenTypeRequest

type CreateTokenTypeRequest struct {
	Name        string              `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Symbol      string              `protobuf:"bytes,2,opt,name=symbol,proto3" json:"symbol,omitempty"`
	Decimals    uint32              `protobuf:"varint,3,opt,name=decimals,proto3" json:"decimals,omitempty"` // from 0 to 8
	GroupType   TokenGroupType      ``                                                                       /* 148-byte string literal not displayed */
	TotalSupply uint64              `protobuf:"varint,5,opt,name=total_supply,json=totalSupply,proto3" json:"total_supply,omitempty"`
	Meta        []*TokenMetaRequest `protobuf:"bytes,6,rep,name=meta,proto3" json:"meta,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateTokenTypeRequest) Descriptor deprecated

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

Deprecated: Use CreateTokenTypeRequest.ProtoReflect.Descriptor instead.

func (*CreateTokenTypeRequest) GetDecimals

func (x *CreateTokenTypeRequest) GetDecimals() uint32

func (*CreateTokenTypeRequest) GetGroupType

func (x *CreateTokenTypeRequest) GetGroupType() TokenGroupType

func (*CreateTokenTypeRequest) GetMeta

func (x *CreateTokenTypeRequest) GetMeta() []*TokenMetaRequest

func (*CreateTokenTypeRequest) GetName

func (x *CreateTokenTypeRequest) GetName() string

func (*CreateTokenTypeRequest) GetSymbol

func (x *CreateTokenTypeRequest) GetSymbol() string

func (*CreateTokenTypeRequest) GetTotalSupply

func (x *CreateTokenTypeRequest) GetTotalSupply() uint64

func (*CreateTokenTypeRequest) ProtoMessage

func (*CreateTokenTypeRequest) ProtoMessage()

func (*CreateTokenTypeRequest) ProtoReflect

func (x *CreateTokenTypeRequest) ProtoReflect() protoreflect.Message

func (*CreateTokenTypeRequest) Reset

func (x *CreateTokenTypeRequest) Reset()

func (*CreateTokenTypeRequest) String

func (x *CreateTokenTypeRequest) String() string

func (*CreateTokenTypeRequest) Validate

func (this *CreateTokenTypeRequest) Validate() error

type StateService

type StateService struct {
}

func NewStateService

func NewStateService() *StateService

func (*StateService) CreateTokenGroup

func (s *StateService) CreateTokenGroup(ctx router.Context, req *CreateTokenGroupRequest) (*TokenGroup, error)

func (*StateService) CreateTokenType

func (s *StateService) CreateTokenType(ctx router.Context, req *CreateTokenTypeRequest) (*TokenType, error)

func (*StateService) DeleteTokenGroup

func (s *StateService) DeleteTokenGroup(ctx router.Context, id *TokenGroupId) (*Token, error)

func (*StateService) DeleteTokenType

func (s *StateService) DeleteTokenType(ctx router.Context, id *TokenTypeId) (*TokenType, error)

func (*StateService) GetConfig

func (s *StateService) GetConfig(ctx router.Context, _ *emptypb.Empty) (*Config, error)

func (*StateService) GetDefaultToken

func (s *StateService) GetDefaultToken(ctx router.Context, _ *emptypb.Empty) (*Token, error)

func (*StateService) GetToken

func (s *StateService) GetToken(ctx router.Context, id *TokenId) (*Token, error)

GetToken naming for token is[{TokenType}, {GroupIdPart1}, {GroupIdPart2}]

func (*StateService) GetTokenGroup

func (s *StateService) GetTokenGroup(ctx router.Context, id *TokenGroupId) (*TokenGroup, error)

func (*StateService) GetTokenGroups

func (s *StateService) GetTokenGroups(ctx router.Context, id *TokenTypeId) (*TokenGroups, error)

func (*StateService) GetTokenType

func (s *StateService) GetTokenType(ctx router.Context, id *TokenTypeId) (*TokenType, error)

func (*StateService) ListTokenTypes

func (s *StateService) ListTokenTypes(ctx router.Context, _ *emptypb.Empty) (*TokenTypes, error)

func (*StateService) SetConfig

func (s *StateService) SetConfig(ctx router.Context, config *Config) (*Config, error)

func (*StateService) UpdateTokenType

func (s *StateService) UpdateTokenType(ctx router.Context, request *UpdateTokenTypeRequest) (*TokenType, error)

type Token

type Token struct {
	Token []string    `protobuf:"bytes,1,rep,name=token,proto3" json:"token,omitempty"`
	Type  *TokenType  `protobuf:"bytes,2,opt,name=type,proto3" json:"type,omitempty"`
	Group *TokenGroup `protobuf:"bytes,3,opt,name=group,proto3" json:"group,omitempty"`
	// contains filtered or unexported fields
}

func (*Token) Descriptor deprecated

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

Deprecated: Use Token.ProtoReflect.Descriptor instead.

func (*Token) GetGroup

func (x *Token) GetGroup() *TokenGroup

func (*Token) GetToken

func (x *Token) GetToken() []string

func (*Token) GetType

func (x *Token) GetType() *TokenType

func (*Token) ProtoMessage

func (*Token) ProtoMessage()

func (*Token) ProtoReflect

func (x *Token) ProtoReflect() protoreflect.Message

func (*Token) Reset

func (x *Token) Reset()

func (*Token) String

func (x *Token) String() string

func (*Token) Validate

func (this *Token) Validate() error

type TokenGetter

type TokenGetter interface {
	GetToken(router.Context, *TokenId) (*Token, error)
	GetDefaultToken(router.Context, *emptypb.Empty) (*Token, error)
}

type TokenGroup

type TokenGroup struct {
	Name        []string     `protobuf:"bytes,1,rep,name=name,proto3" json:"name,omitempty"`
	TokenType   string       `protobuf:"bytes,2,opt,name=token_type,json=tokenType,proto3" json:"token_type,omitempty"`
	TotalSupply uint64       `protobuf:"varint,3,opt,name=total_supply,json=totalSupply,proto3" json:"total_supply,omitempty"`
	Meta        []*TokenMeta `protobuf:"bytes,4,rep,name=meta,proto3" json:"meta,omitempty"`
	// contains filtered or unexported fields
}

State: TokenGroup

func (*TokenGroup) Descriptor deprecated

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

Deprecated: Use TokenGroup.ProtoReflect.Descriptor instead.

func (*TokenGroup) GetMeta

func (x *TokenGroup) GetMeta() []*TokenMeta

func (*TokenGroup) GetName

func (x *TokenGroup) GetName() []string

func (*TokenGroup) GetTokenType

func (x *TokenGroup) GetTokenType() string

func (*TokenGroup) GetTotalSupply

func (x *TokenGroup) GetTotalSupply() uint64

func (*TokenGroup) ProtoMessage

func (*TokenGroup) ProtoMessage()

func (*TokenGroup) ProtoReflect

func (x *TokenGroup) ProtoReflect() protoreflect.Message

func (*TokenGroup) Reset

func (x *TokenGroup) Reset()

func (*TokenGroup) String

func (x *TokenGroup) String() string

func (*TokenGroup) Validate

func (this *TokenGroup) Validate() error

type TokenGroupCreated

type TokenGroupCreated struct {
	TokenType string   `protobuf:"bytes,1,opt,name=token_type,json=tokenType,proto3" json:"token_type,omitempty"`
	Name      []string `protobuf:"bytes,2,rep,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*TokenGroupCreated) Descriptor deprecated

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

Deprecated: Use TokenGroupCreated.ProtoReflect.Descriptor instead.

func (*TokenGroupCreated) GetName

func (x *TokenGroupCreated) GetName() []string

func (*TokenGroupCreated) GetTokenType

func (x *TokenGroupCreated) GetTokenType() string

func (*TokenGroupCreated) ProtoMessage

func (*TokenGroupCreated) ProtoMessage()

func (*TokenGroupCreated) ProtoReflect

func (x *TokenGroupCreated) ProtoReflect() protoreflect.Message

func (*TokenGroupCreated) Reset

func (x *TokenGroupCreated) Reset()

func (*TokenGroupCreated) String

func (x *TokenGroupCreated) String() string

func (*TokenGroupCreated) Validate

func (this *TokenGroupCreated) Validate() error

type TokenGroupId

type TokenGroupId struct {
	TokenName string   `protobuf:"bytes,1,opt,name=token_name,json=tokenName,proto3" json:"token_name,omitempty"`
	Name      []string `protobuf:"bytes,2,rep,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*TokenGroupId) Descriptor deprecated

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

Deprecated: Use TokenGroupId.ProtoReflect.Descriptor instead.

func (*TokenGroupId) GetName

func (x *TokenGroupId) GetName() []string

func (*TokenGroupId) GetTokenName

func (x *TokenGroupId) GetTokenName() string

func (*TokenGroupId) ProtoMessage

func (*TokenGroupId) ProtoMessage()

func (*TokenGroupId) ProtoReflect

func (x *TokenGroupId) ProtoReflect() protoreflect.Message

func (*TokenGroupId) Reset

func (x *TokenGroupId) Reset()

func (*TokenGroupId) String

func (x *TokenGroupId) String() string

func (*TokenGroupId) Validate

func (this *TokenGroupId) Validate() error

type TokenGroupType

type TokenGroupType int32
const (
	TokenGroupType_OPTIONAL    TokenGroupType = 0
	TokenGroupType_REQUIRED    TokenGroupType = 1
	TokenGroupType_NOT_ALLOWED TokenGroupType = 3
)

func (TokenGroupType) Descriptor

func (TokenGroupType) Enum

func (x TokenGroupType) Enum() *TokenGroupType

func (TokenGroupType) EnumDescriptor deprecated

func (TokenGroupType) EnumDescriptor() ([]byte, []int)

Deprecated: Use TokenGroupType.Descriptor instead.

func (TokenGroupType) Number

func (TokenGroupType) String

func (x TokenGroupType) String() string

func (TokenGroupType) Type

type TokenGroups

type TokenGroups struct {
	Groups []*TokenGroup `protobuf:"bytes,1,rep,name=groups,proto3" json:"groups,omitempty"`
	// contains filtered or unexported fields
}

func (*TokenGroups) Descriptor deprecated

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

Deprecated: Use TokenGroups.ProtoReflect.Descriptor instead.

func (*TokenGroups) GetGroups

func (x *TokenGroups) GetGroups() []*TokenGroup

func (*TokenGroups) ProtoMessage

func (*TokenGroups) ProtoMessage()

func (*TokenGroups) ProtoReflect

func (x *TokenGroups) ProtoReflect() protoreflect.Message

func (*TokenGroups) Reset

func (x *TokenGroups) Reset()

func (*TokenGroups) String

func (x *TokenGroups) String() string

func (*TokenGroups) Validate

func (this *TokenGroups) Validate() error

type TokenId

type TokenId struct {
	Token []string `protobuf:"bytes,1,rep,name=token,proto3" json:"token,omitempty"`
	// contains filtered or unexported fields
}

func (*TokenId) Descriptor deprecated

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

Deprecated: Use TokenId.ProtoReflect.Descriptor instead.

func (*TokenId) GetToken

func (x *TokenId) GetToken() []string

func (*TokenId) ProtoMessage

func (*TokenId) ProtoMessage()

func (*TokenId) ProtoReflect

func (x *TokenId) ProtoReflect() protoreflect.Message

func (*TokenId) Reset

func (x *TokenId) Reset()

func (*TokenId) String

func (x *TokenId) String() string

func (*TokenId) Validate

func (this *TokenId) Validate() error

type TokenMeta

type TokenMeta struct {
	Key   string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

func (*TokenMeta) Descriptor deprecated

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

Deprecated: Use TokenMeta.ProtoReflect.Descriptor instead.

func (*TokenMeta) GetKey

func (x *TokenMeta) GetKey() string

func (*TokenMeta) GetValue

func (x *TokenMeta) GetValue() string

func (*TokenMeta) ProtoMessage

func (*TokenMeta) ProtoMessage()

func (*TokenMeta) ProtoReflect

func (x *TokenMeta) ProtoReflect() protoreflect.Message

func (*TokenMeta) Reset

func (x *TokenMeta) Reset()

func (*TokenMeta) String

func (x *TokenMeta) String() string

func (*TokenMeta) Validate

func (this *TokenMeta) Validate() error

type TokenMetaRequest

type TokenMetaRequest struct {
	Key   string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
	Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	// contains filtered or unexported fields
}

func (*TokenMetaRequest) Descriptor deprecated

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

Deprecated: Use TokenMetaRequest.ProtoReflect.Descriptor instead.

func (*TokenMetaRequest) GetKey

func (x *TokenMetaRequest) GetKey() string

func (*TokenMetaRequest) GetValue

func (x *TokenMetaRequest) GetValue() string

func (*TokenMetaRequest) ProtoMessage

func (*TokenMetaRequest) ProtoMessage()

func (*TokenMetaRequest) ProtoReflect

func (x *TokenMetaRequest) ProtoReflect() protoreflect.Message

func (*TokenMetaRequest) Reset

func (x *TokenMetaRequest) Reset()

func (*TokenMetaRequest) String

func (x *TokenMetaRequest) String() string

func (*TokenMetaRequest) Validate

func (this *TokenMetaRequest) Validate() error

type TokenType

type TokenType struct {
	Name        string         `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Symbol      string         `protobuf:"bytes,2,opt,name=symbol,proto3" json:"symbol,omitempty"`
	Decimals    uint32         `protobuf:"varint,3,opt,name=decimals,proto3" json:"decimals,omitempty"`
	TotalSupply uint64         `protobuf:"varint,4,opt,name=total_supply,json=totalSupply,proto3" json:"total_supply,omitempty"`
	GroupType   TokenGroupType `` /* 148-byte string literal not displayed */
	Meta        []*TokenMeta   `protobuf:"bytes,6,rep,name=meta,proto3" json:"meta,omitempty"`
	// contains filtered or unexported fields
}

State: TokenType

func (*TokenType) Descriptor deprecated

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

Deprecated: Use TokenType.ProtoReflect.Descriptor instead.

func (*TokenType) GetDecimals

func (x *TokenType) GetDecimals() uint32

func (*TokenType) GetGroupType

func (x *TokenType) GetGroupType() TokenGroupType

func (*TokenType) GetMeta

func (x *TokenType) GetMeta() []*TokenMeta

func (*TokenType) GetName

func (x *TokenType) GetName() string

func (*TokenType) GetSymbol

func (x *TokenType) GetSymbol() string

func (*TokenType) GetTotalSupply

func (x *TokenType) GetTotalSupply() uint64

func (*TokenType) ProtoMessage

func (*TokenType) ProtoMessage()

func (*TokenType) ProtoReflect

func (x *TokenType) ProtoReflect() protoreflect.Message

func (*TokenType) Reset

func (x *TokenType) Reset()

func (*TokenType) String

func (x *TokenType) String() string

func (*TokenType) Validate

func (this *TokenType) Validate() error

type TokenTypeCreated

type TokenTypeCreated struct {
	Name   string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Symbol string `protobuf:"bytes,2,opt,name=symbol,proto3" json:"symbol,omitempty"`
	// contains filtered or unexported fields
}

func (*TokenTypeCreated) Descriptor deprecated

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

Deprecated: Use TokenTypeCreated.ProtoReflect.Descriptor instead.

func (*TokenTypeCreated) GetName

func (x *TokenTypeCreated) GetName() string

func (*TokenTypeCreated) GetSymbol

func (x *TokenTypeCreated) GetSymbol() string

func (*TokenTypeCreated) ProtoMessage

func (*TokenTypeCreated) ProtoMessage()

func (*TokenTypeCreated) ProtoReflect

func (x *TokenTypeCreated) ProtoReflect() protoreflect.Message

func (*TokenTypeCreated) Reset

func (x *TokenTypeCreated) Reset()

func (*TokenTypeCreated) String

func (x *TokenTypeCreated) String() string

func (*TokenTypeCreated) Validate

func (this *TokenTypeCreated) Validate() error

type TokenTypeId

type TokenTypeId struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

Id: toke type id

func (*TokenTypeId) Descriptor deprecated

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

Deprecated: Use TokenTypeId.ProtoReflect.Descriptor instead.

func (*TokenTypeId) GetName

func (x *TokenTypeId) GetName() string

func (*TokenTypeId) ProtoMessage

func (*TokenTypeId) ProtoMessage()

func (*TokenTypeId) ProtoReflect

func (x *TokenTypeId) ProtoReflect() protoreflect.Message

func (*TokenTypeId) Reset

func (x *TokenTypeId) Reset()

func (*TokenTypeId) String

func (x *TokenTypeId) String() string

func (*TokenTypeId) Validate

func (this *TokenTypeId) Validate() error

type TokenTypes

type TokenTypes struct {
	Types []*TokenType `protobuf:"bytes,1,rep,name=types,proto3" json:"types,omitempty"`
	// contains filtered or unexported fields
}

func (*TokenTypes) Descriptor deprecated

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

Deprecated: Use TokenTypes.ProtoReflect.Descriptor instead.

func (*TokenTypes) GetTypes

func (x *TokenTypes) GetTypes() []*TokenType

func (*TokenTypes) ProtoMessage

func (*TokenTypes) ProtoMessage()

func (*TokenTypes) ProtoReflect

func (x *TokenTypes) ProtoReflect() protoreflect.Message

func (*TokenTypes) Reset

func (x *TokenTypes) Reset()

func (*TokenTypes) String

func (x *TokenTypes) String() string

func (*TokenTypes) Validate

func (this *TokenTypes) Validate() error

type UnimplementedConfigServiceServer

type UnimplementedConfigServiceServer struct {
}

UnimplementedConfigServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedConfigServiceServer) CreateTokenGroup

func (*UnimplementedConfigServiceServer) CreateTokenType

func (*UnimplementedConfigServiceServer) DeleteTokenGroup

func (*UnimplementedConfigServiceServer) DeleteTokenType

func (*UnimplementedConfigServiceServer) GetConfig

func (*UnimplementedConfigServiceServer) GetDefaultToken

func (*UnimplementedConfigServiceServer) GetToken

func (*UnimplementedConfigServiceServer) GetTokenGroup

func (*UnimplementedConfigServiceServer) GetTokenGroups

func (*UnimplementedConfigServiceServer) GetTokenType

func (*UnimplementedConfigServiceServer) ListTokenTypes

func (*UnimplementedConfigServiceServer) SetConfig

func (*UnimplementedConfigServiceServer) UpdateTokenType

type UpdateTokenTypeRequest

type UpdateTokenTypeRequest struct {
	Name        string              `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Symbol      string              `protobuf:"bytes,2,opt,name=symbol,proto3" json:"symbol,omitempty"`
	TotalSupply uint64              `protobuf:"varint,3,opt,name=total_supply,json=totalSupply,proto3" json:"total_supply,omitempty"`
	Meta        []*TokenMetaRequest `protobuf:"bytes,4,rep,name=meta,proto3" json:"meta,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateTokenTypeRequest) Descriptor deprecated

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

Deprecated: Use UpdateTokenTypeRequest.ProtoReflect.Descriptor instead.

func (*UpdateTokenTypeRequest) GetMeta

func (x *UpdateTokenTypeRequest) GetMeta() []*TokenMetaRequest

func (*UpdateTokenTypeRequest) GetName

func (x *UpdateTokenTypeRequest) GetName() string

func (*UpdateTokenTypeRequest) GetSymbol

func (x *UpdateTokenTypeRequest) GetSymbol() string

func (*UpdateTokenTypeRequest) GetTotalSupply

func (x *UpdateTokenTypeRequest) GetTotalSupply() uint64

func (*UpdateTokenTypeRequest) ProtoMessage

func (*UpdateTokenTypeRequest) ProtoMessage()

func (*UpdateTokenTypeRequest) ProtoReflect

func (x *UpdateTokenTypeRequest) ProtoReflect() protoreflect.Message

func (*UpdateTokenTypeRequest) Reset

func (x *UpdateTokenTypeRequest) Reset()

func (*UpdateTokenTypeRequest) String

func (x *UpdateTokenTypeRequest) String() string

func (*UpdateTokenTypeRequest) Validate

func (this *UpdateTokenTypeRequest) Validate() error

Jump to

Keyboard shortcuts

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