models

package
v0.0.0-...-4a9e3d1 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2023 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (

	// TransactionOperationCREATE captures enum value "CREATE"
	TransactionOperationCREATE string = "CREATE"

	// TransactionOperationTRANSFER captures enum value "TRANSFER"
	TransactionOperationTRANSFER string = "TRANSFER"

	// TransactionOperationVALIDATORELECTION captures enum value "VALIDATOR_ELECTION"
	TransactionOperationVALIDATORELECTION string = "VALIDATOR_ELECTION"

	// TransactionOperationCHAINMIGRATIONELECTION captures enum value "CHAIN_MIGRATION_ELECTION"
	TransactionOperationCHAINMIGRATIONELECTION string = "CHAIN_MIGRATION_ELECTION"

	// TransactionOperationVOTE captures enum value "VOTE"
	TransactionOperationVOTE string = "VOTE"
)
View Source
const (

	// TransactionOutputConditionDetailsTypeEd25519DashShaDash256 captures enum value "ed25519-sha-256"
	TransactionOutputConditionDetailsTypeEd25519DashShaDash256 string = "ed25519-sha-256"
)
View Source
const (

	// TransactionVersionNr2Dot0 captures enum value "2.0"
	TransactionVersionNr2Dot0 string = "2.0"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Asset

type Asset struct {

	// data
	Data interface{} `json:"data,omitempty"`

	// id
	// Min Length: 32
	ID string `json:"id,omitempty"`
}

Asset asset

swagger:model Asset

func (*Asset) ContextValidate

func (m *Asset) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this asset based on context it is used

func (*Asset) MarshalBinary

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

MarshalBinary interface implementation

func (*Asset) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*Asset) Validate

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

Validate validates this asset

type Block

type Block struct {

	// height
	Height int64 `json:"height,omitempty"`

	// transactions
	Transactions []*Transaction `json:"transactions"`
}

Block block

swagger:model Block

func (*Block) ContextValidate

func (m *Block) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this block based on the context it is used

func (*Block) MarshalBinary

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

MarshalBinary interface implementation

func (*Block) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*Block) Validate

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

Validate validates this block

type Error

type Error struct {

	// message
	Message interface{} `json:"message,omitempty"`

	// status
	Status int64 `json:"status,omitempty"`
}

Error error

swagger:model Error

func (*Error) ContextValidate

func (m *Error) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this error based on context it is used

func (*Error) MarshalBinary

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

MarshalBinary interface implementation

func (*Error) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*Error) Validate

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

Validate validates this error

type Fulfills

type Fulfills struct {

	// output index
	// Required: true
	OutputIndex int64 `json:"output_index"`

	// transaction id
	// Required: true
	TransactionID string `json:"transaction_id"`
}

Fulfills fulfills

swagger:model Fulfills

func (*Fulfills) ContextValidate

func (m *Fulfills) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this fulfills based on context it is used

func (*Fulfills) MarshalBinary

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

MarshalBinary interface implementation

func (*Fulfills) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*Fulfills) Validate

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

Validate validates this fulfills

type Metadata

type Metadata interface{}

Metadata metadata

swagger:model Metadata

type RootResponse

type RootResponse struct {

	// assets
	Assets string `json:"assets,omitempty"`

	// blocks
	Blocks string `json:"blocks,omitempty"`

	// docs
	Docs string `json:"docs,omitempty"`

	// metadata
	Metadata string `json:"metadata,omitempty"`

	// outputs
	Outputs string `json:"outputs,omitempty"`

	// streams
	Streams string `json:"streams,omitempty"`

	// transactions
	Transactions string `json:"transactions,omitempty"`

	// validators
	Validators string `json:"validators,omitempty"`
}

RootResponse root response

swagger:model RootResponse

func (*RootResponse) ContextValidate

func (m *RootResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this root response based on context it is used

func (*RootResponse) MarshalBinary

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

MarshalBinary interface implementation

func (*RootResponse) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*RootResponse) Validate

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

Validate validates this root response

type Transaction

type Transaction struct {

	// asset
	// Required: true
	Asset *Asset `json:"asset"`

	// id
	// Required: true
	// Min Length: 32
	ID *string `json:"id"`

	// inputs
	// Required: true
	// Min Items: 1
	Inputs []*TransactionInput `json:"inputs"`

	// metadata
	// Required: true
	Metadata Metadata `json:"metadata"`

	// operation
	// Required: true
	// Enum: [CREATE TRANSFER VALIDATOR_ELECTION CHAIN_MIGRATION_ELECTION VOTE]
	Operation string `json:"operation"`

	// outputs
	// Required: true
	Outputs []*TransactionOutput `json:"outputs"`

	// version
	// Required: true
	// Enum: [2.0]
	Version string `json:"version"`
}

Transaction transaction

swagger:model Transaction

func (*Transaction) ContextValidate

func (m *Transaction) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this transaction based on the context it is used

func (*Transaction) MarshalBinary

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

MarshalBinary interface implementation

func (*Transaction) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*Transaction) Validate

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

Validate validates this transaction

type TransactionInput

type TransactionInput struct {

	// fulfillment
	// Required: true
	Fulfillment interface{} `json:"fulfillment"`

	// fulfills
	// Required: true
	Fulfills *Fulfills `json:"fulfills"`

	// owners before
	// Required: true
	// Min Items: 1
	// Unique: true
	OwnersBefore []string `json:"owners_before"`
}

TransactionInput transaction input

swagger:model TransactionInput

func (*TransactionInput) ContextValidate

func (m *TransactionInput) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this transaction input based on the context it is used

func (*TransactionInput) MarshalBinary

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

MarshalBinary interface implementation

func (*TransactionInput) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*TransactionInput) Validate

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

Validate validates this transaction input

type TransactionMode

type TransactionMode string

TransactionMode transaction mode

swagger:model TransactionMode

const (

	// TransactionModeAsync captures enum value "async"
	TransactionModeAsync TransactionMode = "async"

	// TransactionModeSync captures enum value "sync"
	TransactionModeSync TransactionMode = "sync"

	// TransactionModeCommit captures enum value "commit"
	TransactionModeCommit TransactionMode = "commit"
)

func NewTransactionMode

func NewTransactionMode(value TransactionMode) *TransactionMode

func (TransactionMode) ContextValidate

func (m TransactionMode) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this transaction mode based on context it is used

func (TransactionMode) Pointer

func (m TransactionMode) Pointer() *TransactionMode

Pointer returns a pointer to a freshly-allocated TransactionMode.

func (TransactionMode) Validate

func (m TransactionMode) Validate(formats strfmt.Registry) error

Validate validates this transaction mode

type TransactionOutput

type TransactionOutput struct {

	// amount
	// Required: true
	Amount string `json:"amount"`

	// condition
	// Required: true
	Condition TransactionOutputCondition `json:"condition"`

	// public keys
	// Required: true
	// Min Items: 1
	// Unique: true
	PublicKeys []string `json:"public_keys"`
}

TransactionOutput transaction output

swagger:model TransactionOutput

func (*TransactionOutput) ContextValidate

func (m *TransactionOutput) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this transaction output based on the context it is used

func (*TransactionOutput) MarshalBinary

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

MarshalBinary interface implementation

func (*TransactionOutput) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*TransactionOutput) Validate

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

Validate validates this transaction output

type TransactionOutputCondition

type TransactionOutputCondition struct {

	// details
	// Required: true
	Details TransactionOutputConditionDetails `json:"details"`

	// uri
	// Required: true
	// Min Length: 1
	// Pattern: ^ni:///sha-256;([a-zA-Z0-9_-]{0,86})[?](fpt=(ed25519|threshold)-sha-256(&)?|cost=[0-9]+(&)?|subtypes=ed25519-sha-256(&)?){2,3}$
	URI string `json:"uri"`
}

TransactionOutputCondition transaction output condition

swagger:model TransactionOutputCondition

func (*TransactionOutputCondition) ContextValidate

func (m *TransactionOutputCondition) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validate this transaction output condition based on the context it is used

func (*TransactionOutputCondition) MarshalBinary

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

MarshalBinary interface implementation

func (*TransactionOutputCondition) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*TransactionOutputCondition) Validate

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

Validate validates this transaction output condition

type TransactionOutputConditionDetails

type TransactionOutputConditionDetails struct {

	// public key
	// Required: true
	// Min Length: 1
	PublicKey string `json:"public_key"`

	// type
	// Required: true
	// Enum: [ed25519-sha-256]
	Type string `json:"type"`
}

TransactionOutputConditionDetails transaction output condition details

swagger:model TransactionOutputConditionDetails

func (*TransactionOutputConditionDetails) ContextValidate

func (m *TransactionOutputConditionDetails) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this transaction output condition details based on context it is used

func (*TransactionOutputConditionDetails) MarshalBinary

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

MarshalBinary interface implementation

func (*TransactionOutputConditionDetails) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*TransactionOutputConditionDetails) Validate

Validate validates this transaction output condition details

type ValidTransactionResponse

type ValidTransactionResponse struct {

	// asset id
	AssetID string `json:"asset_id,omitempty"`

	// height
	Height int64 `json:"height,omitempty"`

	// transaction id
	TransactionID string `json:"transaction_id,omitempty"`
}

ValidTransactionResponse valid transaction response

swagger:model ValidTransactionResponse

func (*ValidTransactionResponse) ContextValidate

func (m *ValidTransactionResponse) ContextValidate(ctx context.Context, formats strfmt.Registry) error

ContextValidate validates this valid transaction response based on context it is used

func (*ValidTransactionResponse) MarshalBinary

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

MarshalBinary interface implementation

func (*ValidTransactionResponse) UnmarshalBinary

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

UnmarshalBinary interface implementation

func (*ValidTransactionResponse) Validate

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

Validate validates this valid transaction response

Jump to

Keyboard shortcuts

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