Documentation
¶
Overview ¶
Package cmds provides command line tools.
Index ¶
- Variables
- func DefaultImportPS() *ps.PS
- func IsSupportedProposalOperationFactHintFunc() func(hint.Hint) bool
- func LoadHinters(encs *encoder.Encoders) error
- func PAddHinters(pctx context.Context) (context.Context, error)
- func PDigesterFollowUp(ctx context.Context) (context.Context, error)
- func POperationProcessorsMap(pctx context.Context) (context.Context, error)
- func ProcessDigester(ctx context.Context) (context.Context, error)
- func ProcessStartDigester(ctx context.Context) (context.Context, error)
- type BaseCommand
- type BaseNetworkClientCommand
- type DepositCommand
- type ImportCommand
- type NetworkClientBlockItemFileCommand
- type NetworkClientBlockItemFilesCommand
- type NetworkClientCommand
- type NetworkClientReadNodeCommand
- type NetworkClientSendOperationCommand
- type NetworkClientStateCommand
- type NetworkClientWriteNodeCommand
- type PaymentCommand
- type RegisterModelCommand
- type RunCommand
- type Storage
- type TransferCommand
- type UpdateAccountInfoCommand
- type ValidateBlocksCommand
- type WithdrawCommand
Constants ¶
This section is empty.
Variables ¶
View Source
var AddedHinters = []encoder.DecodeDetail{ {Hint: types.DesignHint, Instance: types.Design{}}, {Hint: types.SettingHint, Instance: types.Setting{}}, {Hint: types.DepositRecordHint, Instance: types.DepositRecord{}}, {Hint: payment.DepositHint, Instance: payment.Deposit{}}, {Hint: payment.RegisterModelHint, Instance: payment.RegisterModel{}}, {Hint: payment.TransferHint, Instance: payment.Transfer{}}, {Hint: payment.UpdateAccountSettingHint, Instance: payment.UpdateAccountSetting{}}, {Hint: payment.WithdrawHint, Instance: payment.Withdraw{}}, {Hint: state.DesignStateValueHint, Instance: state.DesignStateValue{}}, {Hint: state.DepositRecordStateValueHint, Instance: state.DepositRecordStateValue{}}, }
View Source
var AddedSupportedHinters = []encoder.DecodeDetail{ {Hint: payment.DepositFactHint, Instance: payment.DepositFact{}}, {Hint: payment.RegisterModelFactHint, Instance: payment.RegisterModelFact{}}, {Hint: payment.TransferFactHint, Instance: payment.TransferFact{}}, {Hint: payment.UpdateAccountSettingFactHint, Instance: payment.UpdateAccountSettingFact{}}, {Hint: payment.WithdrawFactHint, Instance: payment.WithdrawFact{}}, }
View Source
var Hinters []encoder.DecodeDetail
View Source
var PNameOperationProcessorsMap = ps.Name("mitum-payment-operation-processors-map")
View Source
var PNameValidateBlocks = ps.Name("validate-blocks")
View Source
var SupportedProposalOperationFactHinters []encoder.DecodeDetail
Functions ¶
func DefaultImportPS ¶
func LoadHinters ¶
func POperationProcessorsMap ¶
Types ¶
type BaseCommand ¶
type BaseNetworkClientCommand ¶
type BaseNetworkClientCommand struct {
BaseCommand
launchcmd.BaseNetworkClientNodeInfoFlags
Client *isaacnetwork.BaseClient `kong:"-"`
ClientID string `name:"client-id" help:"client id"`
}
type DepositCommand ¶
type DepositCommand struct {
BaseCommand
currencycmds.OperationFlags
Sender currencycmds.AddressFlag `arg:"" name:"sender" help:"sender address" required:"true"`
Contract currencycmds.AddressFlag `arg:"" name:"contract" help:"contract address" required:"true"`
Amount currencycmds.BigFlag `arg:"" name:"amount" help:"deposit amount" required:"true"`
TransferLimit currencycmds.BigFlag `arg:"" name:"transfer limit" help:"transfer limit" required:"true"`
StartTime uint64 `arg:"" name:"start time" help:"start time" required:"true"`
EndTime uint64 `arg:"" name:"end time" help:"end time" required:"true"`
Duration uint64 `arg:"" name:"duration" help:"duration" required:"true"`
Currency currencycmds.CurrencyIDFlag `arg:"" name:"currency" help:"currency id" required:"true"`
// contains filtered or unexported fields
}
type ImportCommand ¶
type ImportCommand struct {
// revive:disable:line-length-limit
launch.DesignFlag
Source string `arg:"" name:"source directory" help:"block data directory to import" type:"existingdir"`
HeightRange launch.RangeFlag `name:"range" help:"<from>-<to>" default:""`
launch.PrivatekeyFlags
Do bool `name:"do" help:"really do import"`
CacheDirectory string `name:"cache-directory" help:"directory for remote block item file"`
launch.DevFlags `embed:"" prefix:"dev."`
// contains filtered or unexported fields
}
type NetworkClientBlockItemFileCommand ¶
type NetworkClientBlockItemFileCommand struct {
BaseNetworkClientCommand
Height launch.HeightFlag `arg:""`
Item base.BlockItemType `arg:"item" help:"item type"`
Validate bool `name:"validate" negatable:"" help:"validate by default" default:"true"`
}
type NetworkClientBlockItemFilesCommand ¶
type NetworkClientBlockItemFilesCommand struct {
BaseNetworkClientCommand
Privatekey string `arg:"" name:"privatekey" help:"privatekey string"`
Height launch.HeightFlag `arg:""`
OutputDirectory string `arg:"" name:"output directory" default:""`
DownloadRemoteItem bool `name:"download-remote-item"`
DownloadAllItems bool `name:"download-all-items"`
// contains filtered or unexported fields
}
type NetworkClientCommand ¶
type NetworkClientCommand struct {
//revive:disable:line-length-limit
//revive:disable:nested-structs
NodeInfo launchcmd.NetworkClientNodeInfoCommand `cmd:"" name:"node-info" help:"remote node info"`
SendOperation NetworkClientSendOperationCommand `cmd:"" name:"send-operation" help:"send operation"`
State launchcmd.NetworkClientStateCommand `cmd:"" name:"state" help:"get state"`
LastBlockMap launchcmd.NetworkClientLastBlockMapCommand `cmd:"" name:"last-blockmap" help:"get last blockmap"`
Design struct {
Read NetworkClientReadNodeCommand `cmd:"" name:"read" help:"read node value"`
Write NetworkClientWriteNodeCommand `cmd:"" name:"write" help:"write node value"`
} `cmd:"" name:"design" help:""`
Event launchcmd.NetworkClientEventLoggingCommand `cmd:"" name:"event" help:"event log"`
}
type NetworkClientReadNodeCommand ¶
type NetworkClientReadNodeCommand struct {
// contains filtered or unexported fields
}
func (*NetworkClientReadNodeCommand) Help ¶
func (*NetworkClientReadNodeCommand) Help() string
type NetworkClientSendOperationCommand ¶
type NetworkClientSendOperationCommand struct {
BaseNetworkClientCommand
Input string `arg:"" name:"input" help:"input; default is stdin" default:"-"`
IsString bool `name:"input.is-string" help:"input is string, not file"`
}
type NetworkClientStateCommand ¶
type NetworkClientStateCommand struct {
BaseNetworkClientCommand
Key string `arg:"" name:"state key" help:"state key"`
Hash string `arg:"" name:"state hash" help:"state hash" default:""`
}
type NetworkClientWriteNodeCommand ¶
type NetworkClientWriteNodeCommand struct {
Input string `arg:"" name:"input" help:"input"`
IsFile bool `name:"input.is-file" help:"input is file"`
// contains filtered or unexported fields
}
func (*NetworkClientWriteNodeCommand) Help ¶
func (cmd *NetworkClientWriteNodeCommand) Help() string
type PaymentCommand ¶
type PaymentCommand struct {
Deposit DepositCommand `cmd:"" name:"deposit" help:"deposit"`
Withdraw WithdrawCommand `cmd:"" name:"withdraw" help:"withdraw"`
Transfer TransferCommand `cmd:"" name:"transfer" help:"transfer"`
UpdateAccountSetting UpdateAccountInfoCommand `cmd:"" name:"update-account-setting" help:"update account setting"`
RegisterModel RegisterModelCommand `cmd:"" name:"register-model" help:"register payment model"`
}
type RegisterModelCommand ¶
type RegisterModelCommand struct {
BaseCommand
currencycmds.OperationFlags
Sender currencycmds.AddressFlag `arg:"" name:"sender" help:"sender address" required:"true"`
Contract currencycmds.AddressFlag `arg:"" name:"contract" help:"contract account to register policy" required:"true"`
Currency currencycmds.CurrencyIDFlag `arg:"" name:"currency" help:"currency id" required:"true"`
// contains filtered or unexported fields
}
type RunCommand ¶
type RunCommand struct {
//revive:disable:line-length-limit
launch.DesignFlag
launch.DevFlags `embed:"" prefix:"dev."`
launch.PrivatekeyFlags
Discovery []launch.ConnInfoFlag `help:"member discovery" placeholder:"ConnInfo"`
Hold launch.HeightFlag `help:"hold consensus states"`
HTTPState string `name:"http-state" help:"runtime statistics thru https" placeholder:"bind address"`
launch.ACLFlags
// contains filtered or unexported fields
}
type Storage ¶
type Storage struct {
Import ImportCommand `cmd:"" help:"import block data files"`
Clean launchcmd.CleanCommand `cmd:"" help:"clean storage"`
ValidateBlocks ValidateBlocksCommand `cmd:"" help:"validate blocks in storage"`
Status launchcmd.StorageStatusCommand `cmd:"" help:"storage status"`
Database launchcmd.DatabaseCommand `cmd:"" help:""`
}
type TransferCommand ¶
type TransferCommand struct {
BaseCommand
currencycmds.OperationFlags
Sender currencycmds.AddressFlag `arg:"" name:"sender" help:"sender address" required:"true"`
Contract currencycmds.AddressFlag `arg:"" name:"contract" help:"contract address" required:"true"`
Receiver currencycmds.AddressFlag `arg:"" name:"receiver" help:"receiver address" required:"true"`
Amount currencycmds.BigFlag `arg:"" name:"amount" help:"amount" required:"true"`
Currency currencycmds.CurrencyIDFlag `arg:"" name:"currency" help:"currency id" required:"true"`
// contains filtered or unexported fields
}
type UpdateAccountInfoCommand ¶
type UpdateAccountInfoCommand struct {
BaseCommand
currencycmds.OperationFlags
Sender currencycmds.AddressFlag `arg:"" name:"sender" help:"sender address" required:"true"`
Contract currencycmds.AddressFlag `arg:"" name:"contract" help:"contract address" required:"true"`
TransferLimit currencycmds.BigFlag `arg:"" name:"transfer limit" help:"transfer limit" required:"true"`
StartTime uint64 `arg:"" name:"start time" help:"start time" required:"true"`
EndTime uint64 `arg:"" name:"end time" help:"end time" required:"true"`
Duration uint64 `arg:"" name:"duration" help:"duration" required:"true"`
Currency currencycmds.CurrencyIDFlag `arg:"" name:"currency" help:"currency id" required:"true"`
// contains filtered or unexported fields
}
type ValidateBlocksCommand ¶
type ValidateBlocksCommand struct {
launch.DesignFlag
launch.PrivatekeyFlags
HeightRange launch.RangeFlag `name:"range" help:"<from>-<to>" default:""`
launch.DevFlags `embed:"" prefix:"dev."`
// contains filtered or unexported fields
}
type WithdrawCommand ¶
type WithdrawCommand struct {
BaseCommand
currencycmds.OperationFlags
Sender currencycmds.AddressFlag `arg:"" name:"sender" help:"sender address" required:"true"`
Contract currencycmds.AddressFlag `arg:"" name:"contract" help:"contract address" required:"true"`
Currency currencycmds.CurrencyIDFlag `arg:"" name:"currency" help:"currency id" required:"true"`
// contains filtered or unexported fields
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.