models

package
v0.0.0-...-8e6e3bb Latest Latest
Warning

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

Go to latest
Published: Sep 17, 2026 License: MIT Imports: 6 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ChannelTransferErrorResponse

type ChannelTransferErrorResponse struct {

	// error message
	Error string `json:"error,omitempty"`
}

ChannelTransferErrorResponse ErrorResponse response with an error

swagger:model channel_transferErrorResponse

func (*ChannelTransferErrorResponse) MarshalBinary

func (m *ChannelTransferErrorResponse) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ChannelTransferErrorResponse) UnmarshalBinary

func (m *ChannelTransferErrorResponse) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ChannelTransferErrorResponse) Validate

func (m *ChannelTransferErrorResponse) Validate(formats strfmt.Registry) error

Validate validates this channel transfer error response

type ChannelTransferGeneralParams

type ChannelTransferGeneralParams struct {

	// chaincode name
	Chaincode string `json:"chaincode,omitempty"`

	// channel name
	Channel string `json:"channel,omitempty"`

	// method name
	MethodName string `json:"methodName,omitempty"`

	// request nonce
	Nonce string `json:"nonce,omitempty"`

	// options
	Options []*ProtobufOption `json:"options"`

	// public key of user, signed the request
	PublicKey string `json:"publicKey,omitempty"`

	// request ID (may be empty)
	RequestID string `json:"requestId,omitempty"`

	// request sign
	Sign string `json:"sign,omitempty"`
}

ChannelTransferGeneralParams GeneralParams general parameters for every request

swagger:model channel_transferGeneralParams

func (*ChannelTransferGeneralParams) MarshalBinary

func (m *ChannelTransferGeneralParams) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ChannelTransferGeneralParams) UnmarshalBinary

func (m *ChannelTransferGeneralParams) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ChannelTransferGeneralParams) Validate

func (m *ChannelTransferGeneralParams) Validate(formats strfmt.Registry) error

Validate validates this channel transfer general params

type ChannelTransferMultiTransferBeginAdminRequest

type ChannelTransferMultiTransferBeginAdminRequest struct {

	// token's owner address (deprecated)
	Address string `json:"address,omitempty"`

	// destination channel
	ChannelTo string `json:"channelTo,omitempty"`

	// general parameters
	Generals *ChannelTransferGeneralParams `json:"generals,omitempty"`

	// transfer ID (should be unique)
	IDTransfer string `json:"idTransfer,omitempty"`

	// items to transfer
	Items []*ChannelTransferTransferItem `json:"items"`

	// options
	Options []*ProtobufOption `json:"options"`
}

ChannelTransferMultiTransferBeginAdminRequest MultiTransferBeginAdminRequest request for tokens transfer by platform administrator

swagger:model channel_transferMultiTransferBeginAdminRequest

func (*ChannelTransferMultiTransferBeginAdminRequest) MarshalBinary

MarshalBinary interface implementation

func (*ChannelTransferMultiTransferBeginAdminRequest) UnmarshalBinary

UnmarshalBinary interface implementation

func (*ChannelTransferMultiTransferBeginAdminRequest) Validate

Validate validates this channel transfer multi transfer begin admin request

type ChannelTransferMultiTransferBeginCustomerRequest

type ChannelTransferMultiTransferBeginCustomerRequest struct {

	// destination channel
	ChannelTo string `json:"channelTo,omitempty"`

	// general parameters
	Generals *ChannelTransferGeneralParams `json:"generals,omitempty"`

	// transfer ID (should be unique)
	IDTransfer string `json:"idTransfer,omitempty"`

	// items to transfer
	Items []*ChannelTransferTransferItem `json:"items"`

	// options
	Options []*ProtobufOption `json:"options"`
}

ChannelTransferMultiTransferBeginCustomerRequest MultiTransferBeginAdminRequest request for tokens transfer by tokens owner

swagger:model channel_transferMultiTransferBeginCustomerRequest

func (*ChannelTransferMultiTransferBeginCustomerRequest) MarshalBinary

MarshalBinary interface implementation

func (*ChannelTransferMultiTransferBeginCustomerRequest) UnmarshalBinary

UnmarshalBinary interface implementation

func (*ChannelTransferMultiTransferBeginCustomerRequest) Validate

Validate validates this channel transfer multi transfer begin customer request

type ChannelTransferTransferBeginAdminRequest

type ChannelTransferTransferBeginAdminRequest struct {

	// token's owner address
	Address string `json:"address,omitempty"`

	// amount of tokens to transfer
	Amount string `json:"amount,omitempty"`

	// destination channel
	ChannelTo string `json:"channelTo,omitempty"`

	// general parameters
	Generals *ChannelTransferGeneralParams `json:"generals,omitempty"`

	// transfer ID (should be unique)
	IDTransfer string `json:"idTransfer,omitempty"`

	// options
	Options []*ProtobufOption `json:"options"`

	// tokens to transfer
	Token string `json:"token,omitempty"`
}

ChannelTransferTransferBeginAdminRequest TransferBeginAdminRequest request for tokens transfer by platform administrator

swagger:model channel_transferTransferBeginAdminRequest

func (*ChannelTransferTransferBeginAdminRequest) MarshalBinary

func (m *ChannelTransferTransferBeginAdminRequest) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ChannelTransferTransferBeginAdminRequest) UnmarshalBinary

func (m *ChannelTransferTransferBeginAdminRequest) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ChannelTransferTransferBeginAdminRequest) Validate

Validate validates this channel transfer transfer begin admin request

type ChannelTransferTransferBeginCustomerRequest

type ChannelTransferTransferBeginCustomerRequest struct {

	// Amount of tokens to transfer
	Amount string `json:"amount,omitempty"`

	// destination channel
	ChannelTo string `json:"channelTo,omitempty"`

	// general parameters
	Generals *ChannelTransferGeneralParams `json:"generals,omitempty"`

	// transfer ID (should be unique)
	IDTransfer string `json:"idTransfer,omitempty"`

	// options
	Options []*ProtobufOption `json:"options"`

	// Tokens to transfer
	Token string `json:"token,omitempty"`
}

ChannelTransferTransferBeginCustomerRequest TransferBeginCustomerRequest request for tokens transfer by tokens owner

swagger:model channel_transferTransferBeginCustomerRequest

func (*ChannelTransferTransferBeginCustomerRequest) MarshalBinary

func (m *ChannelTransferTransferBeginCustomerRequest) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ChannelTransferTransferBeginCustomerRequest) UnmarshalBinary

func (m *ChannelTransferTransferBeginCustomerRequest) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ChannelTransferTransferBeginCustomerRequest) Validate

Validate validates this channel transfer transfer begin customer request

type ChannelTransferTransferItem

type ChannelTransferTransferItem struct {

	// Amount of token to transfer
	Amount string `json:"amount,omitempty"`

	// token's hold
	Hold bool `json:"hold,omitempty"`

	// Token to transfer
	Token string `json:"token,omitempty"`

	// token's owner user
	User string `json:"user,omitempty"`
}

ChannelTransferTransferItem TransferItem item parameters for MultiTransferBeginCustomerRequest and MultiTransferBeginAdminRequest

swagger:model channel_transferTransferItem

func (*ChannelTransferTransferItem) MarshalBinary

func (m *ChannelTransferTransferItem) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ChannelTransferTransferItem) UnmarshalBinary

func (m *ChannelTransferTransferItem) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ChannelTransferTransferItem) Validate

func (m *ChannelTransferTransferItem) Validate(formats strfmt.Registry) error

Validate validates this channel transfer transfer item

type ChannelTransferTransferStatusResponse

type ChannelTransferTransferStatusResponse struct {

	// transfer ID
	IDTransfer string `json:"idTransfer,omitempty"`

	// error message (may be empty)
	Message string `json:"message,omitempty"`

	// transfer status
	Status ChannelTransferTransferStatusResponseStatus `json:"status,omitempty"`
}

ChannelTransferTransferStatusResponse TransferStatusResponse response for TransferStatus transaction

swagger:model channel_transferTransferStatusResponse

func (*ChannelTransferTransferStatusResponse) MarshalBinary

func (m *ChannelTransferTransferStatusResponse) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ChannelTransferTransferStatusResponse) UnmarshalBinary

func (m *ChannelTransferTransferStatusResponse) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ChannelTransferTransferStatusResponse) Validate

Validate validates this channel transfer transfer status response

type ChannelTransferTransferStatusResponseStatus

type ChannelTransferTransferStatusResponseStatus string

ChannelTransferTransferStatusResponseStatus channel transfer transfer status response status

swagger:model channel_transferTransferStatusResponseStatus

const (

	// ChannelTransferTransferStatusResponseStatusSTATUSINPROCESS captures enum value "STATUS_IN_PROCESS"
	ChannelTransferTransferStatusResponseStatusSTATUSINPROCESS ChannelTransferTransferStatusResponseStatus = "STATUS_IN_PROCESS"

	// ChannelTransferTransferStatusResponseStatusSTATUSUNDEFINED captures enum value "STATUS_UNDEFINED"
	ChannelTransferTransferStatusResponseStatusSTATUSUNDEFINED ChannelTransferTransferStatusResponseStatus = "STATUS_UNDEFINED"

	// ChannelTransferTransferStatusResponseStatusSTATUSCOMPLETED captures enum value "STATUS_COMPLETED"
	ChannelTransferTransferStatusResponseStatusSTATUSCOMPLETED ChannelTransferTransferStatusResponseStatus = "STATUS_COMPLETED"

	// ChannelTransferTransferStatusResponseStatusSTATUSCANCELED captures enum value "STATUS_CANCELED"
	ChannelTransferTransferStatusResponseStatusSTATUSCANCELED ChannelTransferTransferStatusResponseStatus = "STATUS_CANCELED"

	// ChannelTransferTransferStatusResponseStatusSTATUSERROR captures enum value "STATUS_ERROR"
	ChannelTransferTransferStatusResponseStatusSTATUSERROR ChannelTransferTransferStatusResponseStatus = "STATUS_ERROR"
)

func (ChannelTransferTransferStatusResponseStatus) Validate

Validate validates this channel transfer transfer status response status

type GooglerpcStatus

type GooglerpcStatus struct {

	// code
	Code int32 `json:"code,omitempty"`

	// details
	Details []*ProtobufAny `json:"details"`

	// message
	Message string `json:"message,omitempty"`
}

GooglerpcStatus googlerpc status

swagger:model googlerpcStatus

func (*GooglerpcStatus) MarshalBinary

func (m *GooglerpcStatus) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*GooglerpcStatus) UnmarshalBinary

func (m *GooglerpcStatus) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*GooglerpcStatus) Validate

func (m *GooglerpcStatus) Validate(formats strfmt.Registry) error

Validate validates this googlerpc status

type ProtobufAny

type ProtobufAny struct {

	// A URL/resource name that uniquely identifies the type of the serialized
	// protocol buffer message. This string must contain at least
	// one "/" character. The last segment of the URL's path must represent
	// the fully qualified name of the type (as in
	// `path/google.protobuf.Duration`). The name should be in a canonical form
	// (e.g., leading "." is not accepted).
	//
	// In practice, teams usually precompile into the binary all types that they
	// expect it to use in the context of Any. However, for URLs which use the
	// scheme `http`, `https`, or no scheme, one can optionally set up a type
	// server that maps type URLs to message definitions as follows:
	//
	// * If no scheme is provided, `https` is assumed.
	// * An HTTP GET on the URL must yield a [google.protobuf.Type][]
	//   value in binary format, or produce an error.
	// * Applications are allowed to cache lookup results based on the
	//   URL, or have them precompiled into a binary to avoid any
	//   lookup. Therefore, binary compatibility needs to be preserved
	//   on changes to types. (Use versioned type names to manage
	//   breaking changes.)
	//
	// Note: this functionality is not currently available in the official
	// protobuf release, and it is not used for type URLs beginning with
	// type.googleapis.com.
	//
	// Schemes other than `http`, `https` (or the empty scheme) might be
	// used with implementation specific semantics.
	AtType string `json:"@type,omitempty"`
}

ProtobufAny `Any` contains an arbitrary serialized protocol buffer message along with a URL that describes the type of the serialized message.

Protobuf library provides support to pack/unpack Any values in the form of utility functions or additional generated methods of the Any type.

Example 1: Pack and unpack a message in C++.

Foo foo = ...;
Any any;
any.PackFrom(foo);
...
if (any.UnpackTo(&foo)) {
  ...
}

Example 2: Pack and unpack a message in Java.

Foo foo = ...;
Any any = Any.pack(foo);
...
if (any.is(Foo.class)) {
  foo = any.unpack(Foo.class);
}
// or ...
if (any.isSameTypeAs(Foo.getDefaultInstance())) {
  foo = any.unpack(Foo.getDefaultInstance());
}

Example 3: Pack and unpack a message in Python.

foo = Foo(...)
any = Any()
any.Pack(foo)
...
if any.Is(Foo.DESCRIPTOR):
  any.Unpack(foo)
  ...

Example 4: Pack and unpack a message in Go

foo := &pb.Foo{...}
any, err := anypb.New(foo)
if err != nil {
  ...
}
...
foo := &pb.Foo{}
if err := any.UnmarshalTo(foo); err != nil {
  ...
}

The pack methods provided by protobuf library will by default use 'type.googleapis.com/full.type.name' as the type URL and the unpack methods only use the fully qualified type name after the last '/' in the type URL, for example "foo.bar.com/x/y.z" will yield type name "y.z".

JSON

The JSON representation of an `Any` value uses the regular representation of the deserialized, embedded message, with an additional field `@type` which contains the type URL. Example:

package google.profile;
message Person {
  string first_name = 1;
  string last_name = 2;
}

{
  "@type": "type.googleapis.com/google.profile.Person",
  "firstName": <string>,
  "lastName": <string>
}

If the embedded message type is well-known and has a custom JSON representation, that representation will be embedded adding a field `value` which holds the custom JSON in addition to the `@type` field. Example (for message [google.protobuf.Duration][]):

{
  "@type": "type.googleapis.com/google.protobuf.Duration",
  "value": "1.212s"
}

swagger:model protobufAny

func (*ProtobufAny) MarshalBinary

func (m *ProtobufAny) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ProtobufAny) UnmarshalBinary

func (m *ProtobufAny) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ProtobufAny) Validate

func (m *ProtobufAny) Validate(formats strfmt.Registry) error

Validate validates this protobuf any

type ProtobufOption

type ProtobufOption struct {

	// The option's name. For protobuf built-in options (options defined in
	// descriptor.proto), this is the short name. For example, `"map_entry"`.
	// For custom options, it should be the fully-qualified name. For example,
	// `"google.api.http"`.
	Name string `json:"name,omitempty"`

	// The option's value packed in an Any message. If the value is a primitive,
	// the corresponding wrapper type defined in google/protobuf/wrappers.proto
	// should be used. If the value is an enum, it should be stored as an int32
	// value using the google.protobuf.Int32Value type.
	Value *ProtobufAny `json:"value,omitempty"`
}

ProtobufOption A protocol buffer option, which can be attached to a message, field, enumeration, etc.

swagger:model protobufOption

func (*ProtobufOption) MarshalBinary

func (m *ProtobufOption) MarshalBinary() ([]byte, error)

MarshalBinary interface implementation

func (*ProtobufOption) UnmarshalBinary

func (m *ProtobufOption) UnmarshalBinary(b []byte) error

UnmarshalBinary interface implementation

func (*ProtobufOption) Validate

func (m *ProtobufOption) Validate(formats strfmt.Registry) error

Validate validates this protobuf option

Jump to

Keyboard shortcuts

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