Documentation ¶
Index ¶
- Constants
- Variables
- func OutputGrouper(out *mtg.Output) string
- type AccountSnapshot
- type Asset
- type CollectibleToken
- type Configuration
- type Engine
- type Machine
- func (m *Machine) AddEngine(platform string, engine Engine)
- func (m *Machine) AddProcess(ctx context.Context, pid string, platform, address string, out *mtg.Output, ...) bool
- func (m *Machine) Loop(ctx context.Context)
- func (m *Machine) ProcessCollectibleOutput(ctx context.Context, out *mtg.CollectibleOutput)
- func (m *Machine) ProcessOutput(ctx context.Context, out *mtg.Output)
- func (m *Machine) Spawn(ctx context.Context, p *Process)
- func (m *Machine) WriteGroupEvent(ctx context.Context, pid string, out *mtg.Output, extra []byte)
- func (m *Machine) WriteNFOGroupEvent(ctx context.Context, pid string, out *mtg.CollectibleOutput, extra []byte)
- type Process
- type Store
Constants ¶
View Source
const ( ProcessPlatformQuorum = "quorum" ProcessCreditMulplifier = 10 )
Variables ¶
View Source
var ( // because the sdk bug, this output is skipped, and should always be in the future InvalidCollectibleOutputHackMap = map[string]bool{ "271d7ef5-6bf3-3b96-9c0c-701f7a989435": true, "8f96c027-fbf0-39dc-99b7-6ba6cdf9c66c": true, "5bb0997f-669a-3e65-8c2f-5cc15de4c9ca": true, "175620b8-f4b8-3e66-84bb-669c62d5140d": true, } )
Functions ¶
func OutputGrouper ¶
Types ¶
type AccountSnapshot ¶
type CollectibleToken ¶
type Configuration ¶
type Engine ¶
type Engine interface { VerifyAddress(addr string, extra []byte) error SetupNotifier(addr string) error VerifyEvent(address string, event *encoding.Event) bool EstimateCost(events []*encoding.Event) (common.Integer, error) EnsureSendGroupEvents(address string, events []*encoding.Event) error ReceiveGroupEvents(address string, offset uint64, limit int) ([]*encoding.Event, error) }
type Machine ¶
type Machine struct {
// contains filtered or unexported fields
}
func (*Machine) AddProcess ¶
func (*Machine) ProcessCollectibleOutput ¶
func (m *Machine) ProcessCollectibleOutput(ctx context.Context, out *mtg.CollectibleOutput)
func (*Machine) ProcessOutput ¶
func (*Machine) WriteGroupEvent ¶
func (*Machine) WriteNFOGroupEvent ¶
type Store ¶
type Store interface { CheckPendingGroupEventIdentifier(id string) (bool, error) WritePendingGroupEventAndNonce(event *encoding.Event, id string) error ListPendingGroupEvents(limit int) ([]*encoding.Event, error) ReadGroupEventSignatures(pid string, nonce uint64) ([][]byte, bool, error) WritePendingGroupEventSignatures(pid string, nonce uint64, partials [][]byte) error WriteSignedGroupEventAndExpirePending(event *encoding.Event) error ListSignedGroupEvents(pid string, limit int) ([]*encoding.Event, error) ExpireGroupEventsWithCost(events []*encoding.Event, cost common.Integer) error CheckAccountSnapshot(as *AccountSnapshot) (bool, error) WriteAccountSnapshot(as *AccountSnapshot) error ReadEngineGroupEventsOffset(pid string) (uint64, error) WriteEngineGroupEventsOffset(pid string, offset uint64) error ListProcesses() ([]*Process, error) WriteProcess(p *Process) error WriteAssetOrCollectible(id, category string) error ReadAssetOrCollectible(id string) (string, error) WriteAsset(a *Asset) error ReadAsset(id string) (*Asset, error) WriteCollectibleToken(t *CollectibleToken) error ReadCollectibleToken(id string) (*CollectibleToken, error) }
Click to show internal directories.
Click to hide internal directories.