Documentation
¶
Index ¶
- Variables
- func LookupWorldOp(ctx context.Context, opTypeID string) (world.Operation, error)
- type Transaction
- type Tx
- func (t *Tx) ApplyWorldObjectOp(ctx context.Context, le *logrus.Entry, objectHandle world.ObjectState, ...) (sysErr bool, err error)
- func (t *Tx) ApplyWorldOp(ctx context.Context, le *logrus.Entry, worldHandle world.WorldState, ...) (sysErr bool, err error)
- func (m *Tx) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *Tx) CloneVT() *Tx
- func (this *Tx) EqualMessageVT(thatMsg any) bool
- func (this *Tx) EqualVT(that *Tx) bool
- func (t *Tx) GetOperationTypeId() string
- func (x *Tx) GetTaskObjectKey() string
- func (x *Tx) GetTxComplete() *TxComplete
- func (x *Tx) GetTxStart() *TxStart
- func (x *Tx) GetTxType() TxType
- func (x *Tx) GetTxUpdateInputs() *TxUpdateInputs
- func (x *Tx) GetTxUpdateWithPassState() *TxUpdateWithPassState
- func (t *Tx) LocateTx() (Transaction, error)
- func (t *Tx) MarshalBlock() ([]byte, error)
- func (x *Tx) MarshalJSON() ([]byte, error)
- func (x *Tx) MarshalProtoJSON(s *json.MarshalState)
- func (x *Tx) MarshalProtoText() string
- func (m *Tx) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *Tx) MarshalToVT(dAtA []byte) (int, error)
- func (m *Tx) MarshalVT() (dAtA []byte, err error)
- func (*Tx) ProtoMessage()
- func (x *Tx) Reset()
- func (m *Tx) SizeVT() (n int)
- func (x *Tx) String() string
- func (t *Tx) UnmarshalBlock(data []byte) error
- func (x *Tx) UnmarshalJSON(b []byte) error
- func (x *Tx) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *Tx) UnmarshalVT(dAtA []byte) error
- func (t *Tx) Validate() error
- type TxComplete
- func (m *TxComplete) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *TxComplete) CloneVT() *TxComplete
- func (this *TxComplete) EqualMessageVT(thatMsg any) bool
- func (this *TxComplete) EqualVT(that *TxComplete) bool
- func (t *TxComplete) ExecuteTx(ctx context.Context, worldState world.WorldState, sender peer.ID, ...) error
- func (x *TxComplete) GetResult() *value.Result
- func (t *TxComplete) GetTxType() TxType
- func (x *TxComplete) GetValueSet() *target.ValueSet
- func (x *TxComplete) MarshalJSON() ([]byte, error)
- func (x *TxComplete) MarshalProtoJSON(s *json.MarshalState)
- func (x *TxComplete) MarshalProtoText() string
- func (m *TxComplete) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TxComplete) MarshalToVT(dAtA []byte) (int, error)
- func (m *TxComplete) MarshalVT() (dAtA []byte, err error)
- func (*TxComplete) ProtoMessage()
- func (x *TxComplete) Reset()
- func (m *TxComplete) SizeVT() (n int)
- func (x *TxComplete) String() string
- func (x *TxComplete) UnmarshalJSON(b []byte) error
- func (x *TxComplete) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *TxComplete) UnmarshalVT(dAtA []byte) error
- func (t *TxComplete) Validate() error
- type TxStart
- func (m *TxStart) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *TxStart) CloneVT() *TxStart
- func (this *TxStart) EqualMessageVT(thatMsg any) bool
- func (this *TxStart) EqualVT(that *TxStart) bool
- func (t *TxStart) ExecuteTx(ctx context.Context, worldState world.WorldState, sender peer.ID, ...) error
- func (x *TxStart) GetAssignSelf() bool
- func (t *TxStart) GetTxType() TxType
- func (x *TxStart) MarshalJSON() ([]byte, error)
- func (x *TxStart) MarshalProtoJSON(s *json.MarshalState)
- func (x *TxStart) MarshalProtoText() string
- func (m *TxStart) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TxStart) MarshalToVT(dAtA []byte) (int, error)
- func (m *TxStart) MarshalVT() (dAtA []byte, err error)
- func (*TxStart) ProtoMessage()
- func (x *TxStart) Reset()
- func (m *TxStart) SizeVT() (n int)
- func (x *TxStart) String() string
- func (x *TxStart) UnmarshalJSON(b []byte) error
- func (x *TxStart) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *TxStart) UnmarshalVT(dAtA []byte) error
- func (t *TxStart) Validate() error
- type TxType
- func (x TxType) Enum() *TxType
- func (x TxType) MarshalJSON() ([]byte, error)
- func (x TxType) MarshalProtoJSON(s *json.MarshalState)
- func (x TxType) MarshalProtoText() string
- func (x TxType) MarshalText() ([]byte, error)
- func (x TxType) String() string
- func (x *TxType) UnmarshalJSON(b []byte) error
- func (x *TxType) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (x *TxType) UnmarshalText(b []byte) error
- func (t TxType) Validate() error
- type TxUpdateInputs
- func (m *TxUpdateInputs) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *TxUpdateInputs) CloneVT() *TxUpdateInputs
- func (this *TxUpdateInputs) EqualMessageVT(thatMsg any) bool
- func (this *TxUpdateInputs) EqualVT(that *TxUpdateInputs) bool
- func (t *TxUpdateInputs) ExecuteTx(ctx context.Context, worldState world.WorldState, sender peer.ID, ...) error
- func (x *TxUpdateInputs) GetResetInputs() bool
- func (t *TxUpdateInputs) GetTxType() TxType
- func (x *TxUpdateInputs) GetUpdateTarget() bool
- func (x *TxUpdateInputs) GetValueSet() *target.ValueSet
- func (x *TxUpdateInputs) MarshalJSON() ([]byte, error)
- func (x *TxUpdateInputs) MarshalProtoJSON(s *json.MarshalState)
- func (x *TxUpdateInputs) MarshalProtoText() string
- func (m *TxUpdateInputs) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TxUpdateInputs) MarshalToVT(dAtA []byte) (int, error)
- func (m *TxUpdateInputs) MarshalVT() (dAtA []byte, err error)
- func (*TxUpdateInputs) ProtoMessage()
- func (x *TxUpdateInputs) Reset()
- func (m *TxUpdateInputs) SizeVT() (n int)
- func (x *TxUpdateInputs) String() string
- func (x *TxUpdateInputs) UnmarshalJSON(b []byte) error
- func (x *TxUpdateInputs) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *TxUpdateInputs) UnmarshalVT(dAtA []byte) error
- func (t *TxUpdateInputs) Validate() error
- type TxUpdateWithPassState
- func (m *TxUpdateWithPassState) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *TxUpdateWithPassState) CloneVT() *TxUpdateWithPassState
- func (this *TxUpdateWithPassState) EqualMessageVT(thatMsg any) bool
- func (this *TxUpdateWithPassState) EqualVT(that *TxUpdateWithPassState) bool
- func (t *TxUpdateWithPassState) ExecuteTx(ctx context.Context, worldState world.WorldState, sender peer.ID, ...) error
- func (t *TxUpdateWithPassState) GetTxType() TxType
- func (x *TxUpdateWithPassState) MarshalJSON() ([]byte, error)
- func (x *TxUpdateWithPassState) MarshalProtoJSON(s *json.MarshalState)
- func (x *TxUpdateWithPassState) MarshalProtoText() string
- func (m *TxUpdateWithPassState) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *TxUpdateWithPassState) MarshalToVT(dAtA []byte) (int, error)
- func (m *TxUpdateWithPassState) MarshalVT() (dAtA []byte, err error)
- func (*TxUpdateWithPassState) ProtoMessage()
- func (x *TxUpdateWithPassState) Reset()
- func (m *TxUpdateWithPassState) SizeVT() (n int)
- func (x *TxUpdateWithPassState) String() string
- func (x *TxUpdateWithPassState) UnmarshalJSON(b []byte) error
- func (x *TxUpdateWithPassState) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *TxUpdateWithPassState) UnmarshalVT(dAtA []byte) error
- func (t *TxUpdateWithPassState) Validate() error
Constants ¶
This section is empty.
Variables ¶
var ( TxType_name = map[int32]string{ 0: "TxType_INVALID", 1: "TxType_UPDATE_INPUTS", 2: "TxType_START", 3: "TxType_UPDATE_WITH_PASS_STATE", 4: "TxType_COMPLETE", } TxType_value = map[string]int32{ "TxType_INVALID": 0, "TxType_UPDATE_INPUTS": 1, "TxType_START": 2, "TxType_UPDATE_WITH_PASS_STATE": 3, "TxType_COMPLETE": 4, } )
Enum value maps for TxType.
var WorldOperationTypeID = "forge/task/tx"
WorldOperationTypeID is the transaction object operation type id. Corresponds to a single *TransactionData object.
Functions ¶
Types ¶
type Transaction ¶
type Transaction interface {
// MarshalVT marshals to binary.
MarshalVT() ([]byte, error)
// UnmarshalVT unmarshals from binary.
UnmarshalVT(data []byte) error
// GetTxType returns the type of transaction this is.
GetTxType() TxType
// Validate performs a cursory check of the transaction.
// Note: this should not fetch network data.
Validate() error
// ExecuteTx executes the transaction against the task instance.
// bcs is located at the task state root.
// The result is written into bcs.
ExecuteTx(
ctx context.Context,
worldState world.WorldState,
sender peer.ID,
objKey string,
bcs *block.Cursor,
root *forge_task.Task,
) error
}
Transaction is an instance of a transaction object.
func NewTxCompleteTxn ¶
func NewTxCompleteTxn() Transaction
NewTxCompleteTxn constructs the COMPLETE transaction.
func NewTxStartTxn ¶
func NewTxStartTxn() Transaction
NewTxStartTxn constructs a new START transaction.
func NewTxUpdateInputsTxn ¶
func NewTxUpdateInputsTxn() Transaction
NewTxUpdateInputsTxn constructs a new UPDATE_INPUTS transaction.
func NewTxUpdateWithPassStateTxn ¶
func NewTxUpdateWithPassStateTxn() Transaction
NewTxUpdateWithPassStateTxn constructs a new UPDATE_WITH_PASS_STATE transaction.
type Tx ¶
type Tx struct {
// TxType is the kind of transaction this is.
TxType TxType `protobuf:"varint,1,opt,name=tx_type,json=txType,proto3" json:"txType,omitempty"`
// TaskObjectKey is the Task object ID this is associated with.
// The Task object must already exist.
TaskObjectKey string `protobuf:"bytes,2,opt,name=task_object_key,json=taskObjectKey,proto3" json:"taskObjectKey,omitempty"`
// TxUpdateInputs updates the Task with the latest Target and Inputs.
// TxType_UPDATE_INPUTS
TxUpdateInputs *TxUpdateInputs `protobuf:"bytes,3,opt,name=tx_update_inputs,json=txUpdateInputs,proto3" json:"txUpdateInputs,omitempty"`
// TxStart contains the start transaction tx.
// TxType_START
TxStart *TxStart `protobuf:"bytes,4,opt,name=tx_start,json=txStart,proto3" json:"txStart,omitempty"`
// TxUpdatePassState contains the update pass state tx.
// TxType_UPDATE_WITH_PASS_STATE
TxUpdateWithPassState *TxUpdateWithPassState `` /* 126-byte string literal not displayed */
// TxComplete contains the complete tx.
// TxType_COMPLETE
TxComplete *TxComplete `protobuf:"bytes,6,opt,name=tx_complete,json=txComplete,proto3" json:"txComplete,omitempty"`
// contains filtered or unexported fields
}
Tx is the on-the-wire representation of a transaction.
func ByteSliceToTx ¶
ByteSliceToTx converts a byte slice block a Tx. If blk is nil, returns nil, nil If the blk is already parsed to a MockWorldOp, returns the MockWorldOp.
func NewTxComplete ¶
func NewTxComplete(objKey string, result *forge_value.Result) *Tx
NewTxComplete constructs the COMPLETE transaction.
func NewTxStart ¶
NewTxStart constructs a new START transaction.
func NewTxUpdateInputs ¶
NewTxUpdateInputs constructs a new UPDATE_INPUTS transaction.
func NewTxUpdateWithPassState ¶
NewTxUpdateWithPassState constructs a new UPDATE_WITH_PASS_STATE transaction.
func (*Tx) ApplyWorldObjectOp ¶
func (t *Tx) ApplyWorldObjectOp(ctx context.Context, le *logrus.Entry, objectHandle world.ObjectState, sender peer.ID) (sysErr bool, err error)
ApplyWorldObjectOp applies the operation to a world object handle.
func (*Tx) ApplyWorldOp ¶
func (t *Tx) ApplyWorldOp( ctx context.Context, le *logrus.Entry, worldHandle world.WorldState, sender peer.ID, ) (sysErr bool, err error)
ApplyWorldOp applies the operation as a world operation.
func (*Tx) CloneMessageVT ¶
func (m *Tx) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*Tx) EqualMessageVT ¶
func (*Tx) GetOperationTypeId ¶
GetOperationTypeId returns the operation type identifier.
func (*Tx) GetTaskObjectKey ¶
func (*Tx) GetTxComplete ¶
func (x *Tx) GetTxComplete() *TxComplete
func (*Tx) GetTxStart ¶
func (*Tx) GetTxUpdateInputs ¶
func (x *Tx) GetTxUpdateInputs() *TxUpdateInputs
func (*Tx) GetTxUpdateWithPassState ¶
func (x *Tx) GetTxUpdateWithPassState() *TxUpdateWithPassState
func (*Tx) LocateTx ¶
func (t *Tx) LocateTx() (Transaction, error)
LocateTx returns the sub-block for the transaction.
func (*Tx) MarshalBlock ¶
MarshalBlock marshals the block to binary. This is the initial step of marshaling, before transformations.
func (*Tx) MarshalJSON ¶
MarshalJSON marshals the Tx to JSON.
func (*Tx) MarshalProtoJSON ¶
func (x *Tx) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the Tx message to JSON.
func (*Tx) MarshalProtoText ¶
func (*Tx) ProtoMessage ¶
func (*Tx) ProtoMessage()
func (*Tx) UnmarshalBlock ¶
UnmarshalBlock unmarshals the block to the object. This is the final step of decoding, after transformations.
func (*Tx) UnmarshalJSON ¶
UnmarshalJSON unmarshals the Tx from JSON.
func (*Tx) UnmarshalProtoJSON ¶
func (x *Tx) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the Tx message from JSON.
func (*Tx) UnmarshalVT ¶
type TxComplete ¶
type TxComplete struct {
// Result is information about the outcome of a completed pass.
Result *value.Result `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"`
// ValueSet is the set of outputs from the task.
// Inputs must be empty.
// Must match the outputs calculated from the Pass and Execution objects.
// Must be empty if the result is not success.
ValueSet *target.ValueSet `protobuf:"bytes,2,opt,name=value_set,json=valueSet,proto3" json:"valueSet,omitempty"`
// contains filtered or unexported fields
}
TxComplete completes the execution by setting the result. If failed, may transition from any state. If success, must be in the CHECKING state. If success, the most recent Pass must be in COMPLETE state and not failed. TxType: TxType_COMPLETE
func (*TxComplete) CloneMessageVT ¶
func (m *TxComplete) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*TxComplete) CloneVT ¶
func (m *TxComplete) CloneVT() *TxComplete
func (*TxComplete) EqualMessageVT ¶
func (this *TxComplete) EqualMessageVT(thatMsg any) bool
func (*TxComplete) EqualVT ¶
func (this *TxComplete) EqualVT(that *TxComplete) bool
func (*TxComplete) ExecuteTx ¶
func (t *TxComplete) ExecuteTx( ctx context.Context, worldState world.WorldState, sender peer.ID, objKey string, bcs *block.Cursor, root *forge_task.Task, ) error
ExecuteTx executes the transaction against the Task instance.
func (*TxComplete) GetResult ¶
func (x *TxComplete) GetResult() *value.Result
func (*TxComplete) GetTxType ¶
func (t *TxComplete) GetTxType() TxType
GetTxType returns the type of transaction this is.
func (*TxComplete) GetValueSet ¶
func (x *TxComplete) GetValueSet() *target.ValueSet
func (*TxComplete) MarshalJSON ¶
func (x *TxComplete) MarshalJSON() ([]byte, error)
MarshalJSON marshals the TxComplete to JSON.
func (*TxComplete) MarshalProtoJSON ¶
func (x *TxComplete) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TxComplete message to JSON.
func (*TxComplete) MarshalProtoText ¶
func (x *TxComplete) MarshalProtoText() string
func (*TxComplete) MarshalToSizedBufferVT ¶
func (m *TxComplete) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TxComplete) MarshalToVT ¶
func (m *TxComplete) MarshalToVT(dAtA []byte) (int, error)
func (*TxComplete) MarshalVT ¶
func (m *TxComplete) MarshalVT() (dAtA []byte, err error)
func (*TxComplete) ProtoMessage ¶
func (*TxComplete) ProtoMessage()
func (*TxComplete) Reset ¶
func (x *TxComplete) Reset()
func (*TxComplete) SizeVT ¶
func (m *TxComplete) SizeVT() (n int)
func (*TxComplete) String ¶
func (x *TxComplete) String() string
func (*TxComplete) UnmarshalJSON ¶
func (x *TxComplete) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the TxComplete from JSON.
func (*TxComplete) UnmarshalProtoJSON ¶
func (x *TxComplete) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TxComplete message from JSON.
func (*TxComplete) UnmarshalVT ¶
func (m *TxComplete) UnmarshalVT(dAtA []byte) error
func (*TxComplete) Validate ¶
func (t *TxComplete) Validate() error
Validate performs a cursory check of the transaction. Note: this should not fetch network data.
type TxStart ¶
type TxStart struct {
// AssignSelf assigns the sender of the tx to the new Pass.
AssignSelf bool `protobuf:"varint,1,opt,name=assign_self,json=assignSelf,proto3" json:"assignSelf,omitempty"`
// contains filtered or unexported fields
}
TxStart starts the execution of the Task by creating a Pass. Transitions from PENDING, RETRY, or COMPLETE to RUNNING. Cancels any existing Pass.
TxType: TxType_START
func (*TxStart) CloneMessageVT ¶
func (m *TxStart) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*TxStart) EqualMessageVT ¶
func (*TxStart) ExecuteTx ¶
func (t *TxStart) ExecuteTx( ctx context.Context, worldState world.WorldState, sender peer.ID, objKey string, bcs *block.Cursor, root *forge_task.Task, ) error
ExecuteTx executes the transaction against the pass instance.
func (*TxStart) GetAssignSelf ¶
func (*TxStart) MarshalJSON ¶
MarshalJSON marshals the TxStart to JSON.
func (*TxStart) MarshalProtoJSON ¶
func (x *TxStart) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TxStart message to JSON.
func (*TxStart) MarshalProtoText ¶
func (*TxStart) MarshalToSizedBufferVT ¶
func (*TxStart) ProtoMessage ¶
func (*TxStart) ProtoMessage()
func (*TxStart) UnmarshalJSON ¶
UnmarshalJSON unmarshals the TxStart from JSON.
func (*TxStart) UnmarshalProtoJSON ¶
func (x *TxStart) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TxStart message from JSON.
func (*TxStart) UnmarshalVT ¶
type TxType ¶
type TxType int32
TxType indicates the kind of transaction.
const ( TxType_TxType_INVALID TxType = 0 // TxType_UPDATE_INPUTS updates the ValueSet inputs and target. // If the values are identical: does nothing. // If changed: transitions to PENDING state and cancels any ongoing Pass. TxType_TxType_UPDATE_INPUTS TxType = 1 // TxType_START marks the pass as running. // Transitions to state RUNNING from PENDING. TxType_TxType_START TxType = 2 // TxType_UPDATE_WITH_PASS_STATE updates the state of the Task based the Pass. // If none or missing: can transition to PENDING. // If failed: can transition to COMPLETE or RETRY. // If success or complete: can transition to CHECKING state. TxType_TxType_UPDATE_WITH_PASS_STATE TxType = 3 // TxType_COMPLETE sets the result of the Task. // If failed, can transition from any state. // If success, must transition from CHECKING state. // If success, all Execution states must be Successful. TxType_TxType_COMPLETE TxType = 4 )
func (TxType) MarshalJSON ¶
MarshalJSON marshals the TxType to JSON.
func (TxType) MarshalProtoJSON ¶
func (x TxType) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TxType to JSON.
func (TxType) MarshalProtoText ¶
func (TxType) MarshalText ¶
MarshalText marshals the TxType to text.
func (*TxType) UnmarshalJSON ¶
UnmarshalJSON unmarshals the TxType from JSON.
func (*TxType) UnmarshalProtoJSON ¶
func (x *TxType) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TxType from JSON.
func (*TxType) UnmarshalText ¶
UnmarshalText unmarshals the TxType from text.
type TxUpdateInputs ¶
type TxUpdateInputs struct {
// UpdateTarget indicates to update the TargetRef if necessary.
UpdateTarget bool `protobuf:"varint,1,opt,name=update_target,json=updateTarget,proto3" json:"updateTarget,omitempty"`
// ResetInputs indicates to clear the existing inputs before setting.
ResetInputs bool `protobuf:"varint,2,opt,name=reset_inputs,json=resetInputs,proto3" json:"resetInputs,omitempty"`
// ValueSet is the set of inputs to set for the task.
// Outputs must be empty.
// Any Value with Type=UNKNOWN (0) will be deleted.
ValueSet *target.ValueSet `protobuf:"bytes,3,opt,name=value_set,json=valueSet,proto3" json:"valueSet,omitempty"`
// contains filtered or unexported fields
}
TxUpdateInputs updates the Task with the latest Target and Inputs. If the value is identical: does nothing. If changed: transitions to PENDING state and cancels any ongoing Pass.
TxType: TxType_UPDATE_INPUTS
func (*TxUpdateInputs) CloneMessageVT ¶
func (m *TxUpdateInputs) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*TxUpdateInputs) CloneVT ¶
func (m *TxUpdateInputs) CloneVT() *TxUpdateInputs
func (*TxUpdateInputs) EqualMessageVT ¶
func (this *TxUpdateInputs) EqualMessageVT(thatMsg any) bool
func (*TxUpdateInputs) EqualVT ¶
func (this *TxUpdateInputs) EqualVT(that *TxUpdateInputs) bool
func (*TxUpdateInputs) ExecuteTx ¶
func (t *TxUpdateInputs) ExecuteTx( ctx context.Context, worldState world.WorldState, sender peer.ID, objKey string, bcs *block.Cursor, root *forge_task.Task, ) error
ExecuteTx executes the transaction against the Task instance.
func (*TxUpdateInputs) GetResetInputs ¶
func (x *TxUpdateInputs) GetResetInputs() bool
func (*TxUpdateInputs) GetTxType ¶
func (t *TxUpdateInputs) GetTxType() TxType
GetTxType returns the type of transaction this is.
func (*TxUpdateInputs) GetUpdateTarget ¶
func (x *TxUpdateInputs) GetUpdateTarget() bool
func (*TxUpdateInputs) GetValueSet ¶
func (x *TxUpdateInputs) GetValueSet() *target.ValueSet
func (*TxUpdateInputs) MarshalJSON ¶
func (x *TxUpdateInputs) MarshalJSON() ([]byte, error)
MarshalJSON marshals the TxUpdateInputs to JSON.
func (*TxUpdateInputs) MarshalProtoJSON ¶
func (x *TxUpdateInputs) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TxUpdateInputs message to JSON.
func (*TxUpdateInputs) MarshalProtoText ¶
func (x *TxUpdateInputs) MarshalProtoText() string
func (*TxUpdateInputs) MarshalToSizedBufferVT ¶
func (m *TxUpdateInputs) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TxUpdateInputs) MarshalToVT ¶
func (m *TxUpdateInputs) MarshalToVT(dAtA []byte) (int, error)
func (*TxUpdateInputs) MarshalVT ¶
func (m *TxUpdateInputs) MarshalVT() (dAtA []byte, err error)
func (*TxUpdateInputs) ProtoMessage ¶
func (*TxUpdateInputs) ProtoMessage()
func (*TxUpdateInputs) Reset ¶
func (x *TxUpdateInputs) Reset()
func (*TxUpdateInputs) SizeVT ¶
func (m *TxUpdateInputs) SizeVT() (n int)
func (*TxUpdateInputs) String ¶
func (x *TxUpdateInputs) String() string
func (*TxUpdateInputs) UnmarshalJSON ¶
func (x *TxUpdateInputs) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the TxUpdateInputs from JSON.
func (*TxUpdateInputs) UnmarshalProtoJSON ¶
func (x *TxUpdateInputs) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TxUpdateInputs message from JSON.
func (*TxUpdateInputs) UnmarshalVT ¶
func (m *TxUpdateInputs) UnmarshalVT(dAtA []byte) error
func (*TxUpdateInputs) Validate ¶
func (t *TxUpdateInputs) Validate() error
Validate performs a cursory check of the transaction. Note: this should not fetch network data.
type TxUpdateWithPassState ¶
type TxUpdateWithPassState struct {
// contains filtered or unexported fields
}
TxUpdateWithPassState updates the state of the Task based on the current Pass. If none or not found: transitions to PENDING. If complete or failed: transitions to CHECKING state. TxType: TxType_UPDATE_WITH_PASS_STATE
func (*TxUpdateWithPassState) CloneMessageVT ¶
func (m *TxUpdateWithPassState) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*TxUpdateWithPassState) CloneVT ¶
func (m *TxUpdateWithPassState) CloneVT() *TxUpdateWithPassState
func (*TxUpdateWithPassState) EqualMessageVT ¶
func (this *TxUpdateWithPassState) EqualMessageVT(thatMsg any) bool
func (*TxUpdateWithPassState) EqualVT ¶
func (this *TxUpdateWithPassState) EqualVT(that *TxUpdateWithPassState) bool
func (*TxUpdateWithPassState) ExecuteTx ¶
func (t *TxUpdateWithPassState) ExecuteTx( ctx context.Context, worldState world.WorldState, sender peer.ID, objKey string, bcs *block.Cursor, root *forge_task.Task, ) error
ExecuteTx executes the transaction against the Task instance.
func (*TxUpdateWithPassState) GetTxType ¶
func (t *TxUpdateWithPassState) GetTxType() TxType
GetTxType returns the type of transaction this is.
func (*TxUpdateWithPassState) MarshalJSON ¶
func (x *TxUpdateWithPassState) MarshalJSON() ([]byte, error)
MarshalJSON marshals the TxUpdateWithPassState to JSON.
func (*TxUpdateWithPassState) MarshalProtoJSON ¶
func (x *TxUpdateWithPassState) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the TxUpdateWithPassState message to JSON.
func (*TxUpdateWithPassState) MarshalProtoText ¶
func (x *TxUpdateWithPassState) MarshalProtoText() string
func (*TxUpdateWithPassState) MarshalToSizedBufferVT ¶
func (m *TxUpdateWithPassState) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*TxUpdateWithPassState) MarshalToVT ¶
func (m *TxUpdateWithPassState) MarshalToVT(dAtA []byte) (int, error)
func (*TxUpdateWithPassState) MarshalVT ¶
func (m *TxUpdateWithPassState) MarshalVT() (dAtA []byte, err error)
func (*TxUpdateWithPassState) ProtoMessage ¶
func (*TxUpdateWithPassState) ProtoMessage()
func (*TxUpdateWithPassState) Reset ¶
func (x *TxUpdateWithPassState) Reset()
func (*TxUpdateWithPassState) SizeVT ¶
func (m *TxUpdateWithPassState) SizeVT() (n int)
func (*TxUpdateWithPassState) String ¶
func (x *TxUpdateWithPassState) String() string
func (*TxUpdateWithPassState) UnmarshalJSON ¶
func (x *TxUpdateWithPassState) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the TxUpdateWithPassState from JSON.
func (*TxUpdateWithPassState) UnmarshalProtoJSON ¶
func (x *TxUpdateWithPassState) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the TxUpdateWithPassState message from JSON.
func (*TxUpdateWithPassState) UnmarshalVT ¶
func (m *TxUpdateWithPassState) UnmarshalVT(dAtA []byte) error
func (*TxUpdateWithPassState) Validate ¶
func (t *TxUpdateWithPassState) Validate() error
Validate performs a cursory check of the transaction. Note: this should not fetch network data.