v1

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Jul 2, 2024 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrorReason_name = map[int32]string{
		0: "PageNotFound",
	}
	ErrorReason_value = map[string]int32{
		"PageNotFound": 0,
	}
)

Enum value maps for ErrorReason.

View Source
var File_toyblc_v1_errors_proto protoreflect.FileDescriptor
View Source
var File_toyblc_v1_toyblc_proto protoreflect.FileDescriptor

Functions

func ErrorPageNotFound

func ErrorPageNotFound(format string, args ...interface{}) *errors.Error

页面未找到错误,请求的页面不存在

func IsPageNotFound

func IsPageNotFound(err error) bool

页面未找到错误,请求的页面不存在

Types

type CreateBlockRequest

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

func (*CreateBlockRequest) Descriptor deprecated

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

Deprecated: Use CreateBlockRequest.ProtoReflect.Descriptor instead.

func (*CreateBlockRequest) GetData

func (x *CreateBlockRequest) GetData() string

func (*CreateBlockRequest) ProtoMessage

func (*CreateBlockRequest) ProtoMessage()

func (*CreateBlockRequest) ProtoReflect

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

func (*CreateBlockRequest) Reset

func (x *CreateBlockRequest) Reset()

func (*CreateBlockRequest) String

func (x *CreateBlockRequest) String() string

func (*CreateBlockRequest) Validate

func (m *CreateBlockRequest) Validate() error

Validate checks the field values on CreateBlockRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*CreateBlockRequest) ValidateAll

func (m *CreateBlockRequest) ValidateAll() error

ValidateAll checks the field values on CreateBlockRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CreateBlockRequestMultiError, or nil if none found.

type CreateBlockRequestMultiError

type CreateBlockRequestMultiError []error

CreateBlockRequestMultiError is an error wrapping multiple validation errors returned by CreateBlockRequest.ValidateAll() if the designated constraints aren't met.

func (CreateBlockRequestMultiError) AllErrors

func (m CreateBlockRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (CreateBlockRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type CreateBlockRequestValidationError

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

CreateBlockRequestValidationError is the validation error returned by CreateBlockRequest.Validate if the designated constraints aren't met.

func (CreateBlockRequestValidationError) Cause

Cause function returns cause value.

func (CreateBlockRequestValidationError) Error

Error satisfies the builtin error interface

func (CreateBlockRequestValidationError) ErrorName

ErrorName returns error name.

func (CreateBlockRequestValidationError) Field

Field function returns field value.

func (CreateBlockRequestValidationError) Key

Key function returns key value.

func (CreateBlockRequestValidationError) Reason

Reason function returns reason value.

type CreatePeerRequest

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

func (*CreatePeerRequest) Descriptor deprecated

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

Deprecated: Use CreatePeerRequest.ProtoReflect.Descriptor instead.

func (*CreatePeerRequest) GetPeer

func (x *CreatePeerRequest) GetPeer() string

func (*CreatePeerRequest) ProtoMessage

func (*CreatePeerRequest) ProtoMessage()

func (*CreatePeerRequest) ProtoReflect

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

func (*CreatePeerRequest) Reset

func (x *CreatePeerRequest) Reset()

func (*CreatePeerRequest) String

func (x *CreatePeerRequest) String() string

func (*CreatePeerRequest) Validate

func (m *CreatePeerRequest) Validate() error

Validate checks the field values on CreatePeerRequest with the rules defined in the proto definition for this message. If any rules are violated, the first error encountered is returned, or nil if there are no violations.

func (*CreatePeerRequest) ValidateAll

func (m *CreatePeerRequest) ValidateAll() error

ValidateAll checks the field values on CreatePeerRequest with the rules defined in the proto definition for this message. If any rules are violated, the result is a list of violation errors wrapped in CreatePeerRequestMultiError, or nil if none found.

type CreatePeerRequestMultiError

type CreatePeerRequestMultiError []error

CreatePeerRequestMultiError is an error wrapping multiple validation errors returned by CreatePeerRequest.ValidateAll() if the designated constraints aren't met.

func (CreatePeerRequestMultiError) AllErrors

func (m CreatePeerRequestMultiError) AllErrors() []error

AllErrors returns a list of validation violation errors.

func (CreatePeerRequestMultiError) Error

Error returns a concatenation of all the error messages it wraps.

type CreatePeerRequestValidationError

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

CreatePeerRequestValidationError is the validation error returned by CreatePeerRequest.Validate if the designated constraints aren't met.

func (CreatePeerRequestValidationError) Cause

Cause function returns cause value.

func (CreatePeerRequestValidationError) Error

Error satisfies the builtin error interface

func (CreatePeerRequestValidationError) ErrorName

ErrorName returns error name.

func (CreatePeerRequestValidationError) Field

Field function returns field value.

func (CreatePeerRequestValidationError) Key

Key function returns key value.

func (CreatePeerRequestValidationError) Reason

Reason function returns reason value.

type ErrorReason

type ErrorReason int32
const (
	// 页面未找到错误,请求的页面不存在
	ErrorReason_PageNotFound ErrorReason = 0
)

func (ErrorReason) Descriptor

func (ErrorReason) Enum

func (x ErrorReason) Enum() *ErrorReason

func (ErrorReason) EnumDescriptor deprecated

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

Deprecated: Use ErrorReason.Descriptor instead.

func (ErrorReason) Number

func (x ErrorReason) Number() protoreflect.EnumNumber

func (ErrorReason) String

func (x ErrorReason) String() string

func (ErrorReason) Type

Jump to

Keyboard shortcuts

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