Listens to events emitted by the Galactic Marketplace program and will call the registered onEvent() callback function for each event.

Param: connection

Solana connection

Param: programId

The Galactic Marketplace program PublicKey

Param: commitment

Optional Solana commitment level, defaults the connection commitment level

Constructors

Properties

commitment: Commitment
connection: Connection
eventListeners: number[] = []
idl: Idl
onEvent: ((eventType, order, slotContext) => void)

Type declaration

    • (eventType, order, slotContext): void
    • Parameters

      Returns void

program: Program<Idl>
programId: PublicKey
provider: AnchorProvider
queuedEvents: BlockChainEvent[] = []
registeredCurrencyInfo: {
    [key: string]: GmRegisteredCurrency;
} = {}

Type declaration

Methods