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 | Provider | Signer | The signer or provider object. |
Defined in
packages/sdk-ethers-v6/src/Client.ts:23
Properties
chainName
• chainName: string
The name of the chain.
Defined in
packages/sdk-ethers-v6/src/Client.ts:23
Accessors
provider
• get
provider(): Provider
The provider associated with the client.
Returns
Provider
Defined in
packages/sdk-ethers-v6/src/Client.ts:37
signer
• get
signer(): Signer
The signer associated with the client.
Returns
Signer
Defined in
packages/sdk-ethers-v6/src/Client.ts:30
Methods
account
▸ account(): ChromaticAccount
Creates a new instance of the ChromaticAccount class.
Returns
An instance of the ChromaticAccount class.
Defined in
packages/sdk-ethers-v6/src/Client.ts:99
lens
▸ lens(): ChromaticLens
Creates a new instance of the ChromaticLens class.
Returns
An instance of the ChromaticLens class.
Defined in
packages/sdk-ethers-v6/src/Client.ts:59
market
▸ market(): ChromaticMarket
Creates a new instance of the ChromaticMarket class.
Returns
An instance of the ChromaticMarket class.
Defined in
packages/sdk-ethers-v6/src/Client.ts:75
marketFactory
▸ marketFactory(): ChromaticMarketFactory
Creates a new instance of the ChromaticMarketFactory class.
Returns
An instance of the ChromaticMarketFactory class.
Defined in
packages/sdk-ethers-v6/src/Client.ts:67
position
▸ position(): ChromaticPosition
Creates a new instance of the ChromaticPosition class.
Returns
An instance of the ChromaticPosition class.
Defined in
packages/sdk-ethers-v6/src/Client.ts:83
router
▸ router(): ChromaticRouter
Creates a new instance of the ChromaticRouter class.
Returns
An instance of the ChromaticRouter class.
Defined in
packages/sdk-ethers-v6/src/Client.ts:91
setSignerOrProvider
▸ setSignerOrProvider(signerOrProvider
): void
Sets the signer or provider for the client.
Parameters
Name | Type | Description |
---|---|---|
signerOrProvider | Provider | Signer | The signer or provider object. |
Returns
void