Constructors
constructor
- new State(snap: SnapsProvider): State
Properties
snap
snap: SnapsProvider
Methods
delete
- delete(origin: string): Promise<boolean>
Returns Promise<boolean>
get
- get(
origin: string,
): Promise<
| undefined
| {
derivationPath: string;
network: "mainnet"
| "testnet";
rpc: { token: string; url: string };
unit?: { decimals: number; symbol: "FIL" | "tFIL" };
},
> Returns Promise<
| undefined
| {
derivationPath: string;
network: "mainnet"
| "testnet";
rpc: { token: string; url: string };
unit?: { decimals: number; symbol: "FIL" | "tFIL" };
},
>
has
- has(origin: string): Promise<boolean>
Returns Promise<boolean>
set
- set(
origin: string,
config: {
derivationPath: string;
network: "mainnet" | "testnet";
rpc: { token: string; url: string };
unit?: { decimals: number; symbol: "FIL" | "tFIL" };
},
): Promise<
{
derivationPath: string;
network: "mainnet"
| "testnet";
rpc: { token: string; url: string };
unit?: { decimals: number; symbol: "FIL" | "tFIL" };
},
> Parameters
- origin: string
- config: {
derivationPath: string;
network: "mainnet" | "testnet";
rpc: { token: string; url: string };
unit?: { decimals: number; symbol: "FIL" | "tFIL" };
}
Returns Promise<
{
derivationPath: string;
network: "mainnet"
| "testnet";
rpc: { token: string; url: string };
unit?: { decimals: number; symbol: "FIL" | "tFIL" };
},
>