# Class PlatformContext<N, P>`Abstract`

#### Type Parameters

- #### N extends Network

- #### P extends Platform

#### Hierarchy

- PlatformContext
  - testing.mocks.MockPlatform
  - testing.mocks.MockPlatform
  - EvmPlatform
  - SolanaPlatform
  - CosmwasmPlatform

- Defined in definitions/src/platform.ts:84

#####
Index

### Constructors

constructor

### Properties

config
network

### Methods

getChain
getProtocol
getRpc
parseWormholeMessages
utils

## Constructors

### constructor

- new PlatformContext<N, P>(network, config): PlatformContext<N, P>

- #### Type Parameters

  - #### N extends "Mainnet" | "Testnet" | "Devnet"

  - #### P extends "Solana" | "Algorand" | "Near" | "Sui" | "Aptos" | "Btc" | "Evm" | "Cosmwasm"

  #### Parameters

  - ##### network: N

  - ##### config: ChainsConfig<N, P>

  #### Returns PlatformContext<N, P>

  - Defined in definitions/src/platform.ts:85

## Properties

### `Readonly` config

config: ChainsConfig<N, P>

- Defined in definitions/src/platform.ts:87

### `Readonly` network

network: N

- Defined in definitions/src/platform.ts:86

## Methods

### `Abstract` getChain

- getChain<C>(chain, rpc?): ChainContext<N, P, C>

- #### Type Parameters

  - #### C extends "Solana" | "Ethereum" | "Terra" | "Bsc" | "Polygon" | "Avalanche" | "Oasis" | "Algorand" | "Aurora" | "Fantom" | "Karura" | "Acala" | "Klaytn" | "Celo" | "Near" | "Moonbeam" | "Neon" | "Terra2" | "Injective" | "Osmosis" | "Sui" | "Aptos" | "Arbitrum" | "Optimism" | "Gnosis" | "Pythnet" | "Xpla" | "Btc" | "Base" | "Sei" | "Rootstock" | "Wormchain" | "Cosmoshub" | "Evmos" | "Kujira" | "Sepolia" | "ArbitrumSepolia" | "BaseSepolia" | "OptimismSepolia" | "Holesky"

  #### Parameters

  - ##### chain: C

  - ##### `Optional` rpc: any

  #### Returns ChainContext<N, P, C>

  - Defined in definitions/src/platform.ts:99

### getProtocol

- getProtocol<PN, T>(protocol, rpc): Promise<T>

- #### Type Parameters

  - #### PN extends "WormholeCore" | "TokenBridge" | "AutomaticTokenBridge" | "CircleBridge" | "AutomaticCircleBridge" | "Relayer" | "IbcBridge" | "NftBridge"

  - #### T

  #### Parameters

  - ##### protocol: PN

  - ##### rpc: any

  #### Returns Promise<T>

  - Defined in definitions/src/platform.ts:105

### `Abstract` getRpc

- getRpc<C>(chain): any

- #### Type Parameters

  - #### C extends "Solana" | "Ethereum" | "Terra" | "Bsc" | "Polygon" | "Avalanche" | "Oasis" | "Algorand" | "Aurora" | "Fantom" | "Karura" | "Acala" | "Klaytn" | "Celo" | "Near" | "Moonbeam" | "Neon" | "Terra2" | "Injective" | "Osmosis" | "Sui" | "Aptos" | "Arbitrum" | "Optimism" | "Gnosis" | "Pythnet" | "Xpla" | "Btc" | "Base" | "Sei" | "Rootstock" | "Wormchain" | "Cosmoshub" | "Evmos" | "Kujira" | "Sepolia" | "ArbitrumSepolia" | "BaseSepolia" | "OptimismSepolia" | "Holesky"

  #### Parameters

  - ##### chain: C

  #### Returns any

  - Defined in definitions/src/platform.ts:96

### parseWormholeMessages

- parseWormholeMessages<C>(chain, rpc, txid): Promise<WormholeMessageId[]>

- #### Type Parameters

  - #### C extends "Solana" | "Ethereum" | "Terra" | "Bsc" | "Polygon" | "Avalanche" | "Oasis" | "Algorand" | "Aurora" | "Fantom" | "Karura" | "Acala" | "Klaytn" | "Celo" | "Near" | "Moonbeam" | "Neon" | "Terra2" | "Injective" | "Osmosis" | "Sui" | "Aptos" | "Arbitrum" | "Optimism" | "Gnosis" | "Pythnet" | "Xpla" | "Btc" | "Base" | "Sei" | "Rootstock" | "Wormchain" | "Cosmoshub" | "Evmos" | "Kujira" | "Sepolia" | "ArbitrumSepolia" | "BaseSepolia" | "OptimismSepolia" | "Holesky"

  #### Parameters

  - ##### chain: C

  - ##### rpc: any

  - ##### txid: string

  #### Returns Promise<WormholeMessageId[]>

  - Defined in definitions/src/platform.ts:110

### utils

- utils(): PlatformUtils<N, P>

- #### Returns PlatformUtils<N, P>

  - Defined in definitions/src/platform.ts:91

Generated using TypeDoc