Class: Client
A client for interacting with the Chromatic protocol on a specific chain.
Constructors
constructor
• new Client(chainName
, signerOrProvider
)
Creates a new instance of the Client class.
Parameters
Name | Type | Description |
---|---|---|
chainName | string | The name of the chain. |
signerOrProvider | Signer | Provider | The signer or provider object. |
Defined in
packages/sdk-ethers-v5/src/Client.ts:24
Properties
chainName
• chainName: string
The name of the chain.
Defined in
packages/sdk-ethers-v5/src/Client.ts:24
Accessors
provider
• get
provider(): Provider
The provider associated with the client.
Returns
Provider
Defined in
packages/sdk-ethers-v5/src/Client.ts:38
signer
• get
signer(): Signer
The signer associated with the client.
Returns
Signer
Defined in
packages/sdk-ethers-v5/src/Client.ts:31
Methods
account
▸ account(): ChromaticAccount
Creates a new instance of the ChromaticAccount class.
Returns
An instance of the ChromaticAccount class.
Defined in
packages/sdk-ethers-v5/src/Client.ts:101
lens
▸ lens(): ChromaticLens
Creates a new instance of the ChromaticLens class.
Returns
An instance of the ChromaticLens class.
Defined in
packages/sdk-ethers-v5/src/Client.ts:61
market
▸ market(): ChromaticMarket
Creates a new instance of the ChromaticMarket class.
Returns
An instance of the ChromaticMarket class.
Defined in
packages/sdk-ethers-v5/src/Client.ts:77
marketFactory
▸ marketFactory(): ChromaticMarketFactory
Creates a new instance of the ChromaticMarketFactory class.
Returns
An instance of the ChromaticMarketFactory class.
Defined in
packages/sdk-ethers-v5/src/Client.ts:69
position
▸ position(): ChromaticPosition
Creates a new instance of the ChromaticPosition class.
Returns
An instance of the ChromaticPosition class.
Defined in
packages/sdk-ethers-v5/src/Client.ts:85
router
▸ router(): ChromaticRouter
Creates a new instance of the ChromaticRouter class.
Returns
An instance of the ChromaticRouter class.
Defined in
packages/sdk-ethers-v5/src/Client.ts:93
setSignerOrProvider
▸ setSignerOrProvider(signerOrProvider
): void
Sets the signer or provider for the client.
Parameters
Name | Type | Description |
---|---|---|
signerOrProvider | Signer | Provider | The signer or provider object. |
Returns
void