Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

Index

Constructors

constructor

Properties

Protected _beaconId

_beaconId: ExposedPromise<string, unknown> = ...

The beaconId is a public key that is used to identify one specific application (dapp or wallet). This is used inside a message to specify the sender, for example.

Protected Readonly _isConnected

_isConnected: ExposedPromise<boolean, unknown> = ...

Returns whether or not the transport is connected

Protected _keyPair

_keyPair: ExposedPromise<KeyPair, unknown> = ...

The local keypair that is used for the communication encryption

Protected _transport

_transport: ExposedPromise<Transport<any, any, any>, unknown> = ...

Protected Readonly accountManager

accountManager: AccountManager

Private Readonly appMetadataManager

appMetadataManager: AppMetadataManager

Optional Readonly appUrl

appUrl: string

The URL of the dApp.

Protected Readonly events

Protected handleResponse

handleResponse: (_event: BeaconRequestMessage, connectionInfo: ConnectionContext) => void

Type declaration

Optional Readonly iconUrl

iconUrl: string

The URL of the dApp Icon. This can be used to display the icon of the dApp on in the wallet

Protected Readonly matrixNodes

matrixNodes: string[]

Readonly name

name: string

The name of the client

Private pendingRequests

pendingRequests: [BeaconRequestMessage, ConnectionContext][] = ...

This array stores pending requests, meaning requests we received and have not yet handled / sent a response.

Private Readonly permissionManager

permissionManager: PermissionManager

Protected Readonly rateLimit

rateLimit: number = 2

How many requests can be sent after another

Protected Readonly rateLimitWindowInSeconds

rateLimitWindowInSeconds: number = 5

The time window in seconds in which the "rateLimit" is checked

Protected requestCounter

requestCounter: number[] = ...

Stores the times when requests have been made to determine if the rate limit has been reached

Protected storage

storage: Storage

Accessors

beaconId

  • get beaconId(): Promise<string>

connectionStatus

isConnected

  • get isConnected(): Promise<boolean>

Protected keyPair

  • get keyPair(): Promise<KeyPair>

ready

  • get ready(): Promise<void>

Protected transport

  • get transport(): Promise<Transport<any, any, any>>

Methods

_connect

  • _connect(): Promise<void>

Protected addListener

  • addListener(transport: Transport<any, any, any>): Promise<void>

addPeer

  • addPeer(peer: PeerInfo, sendPairingResponse?: boolean): Promise<void>

addRequestAndCheckIfRateLimited

  • addRequestAndCheckIfRateLimited(): Promise<boolean>

connect

destroy

  • destroy(): Promise<void>

getAccount

  • getAccount(accountIdentifier: string): Promise<undefined | AccountInfo>

getAccounts

getAppMetadata

  • getAppMetadata(senderId: string): Promise<undefined | AppMetadata>

getAppMetadataList

getOwnAppMetadata

getPeers

getPermission

  • getPermission(accountIdentifier: string): Promise<undefined | PermissionInfo>

getPermissions

init

removeAccount

  • removeAccount(accountIdentifier: string): Promise<void>

removeAllAccounts

  • removeAllAccounts(): Promise<void>

removeAllAppMetadata

  • removeAllAppMetadata(): Promise<void>

removeAllPeers

  • removeAllPeers(sendDisconnectToPeers?: boolean): Promise<void>

removeAllPermissions

  • removeAllPermissions(): Promise<void>

removeAppMetadata

  • removeAppMetadata(senderId: string): Promise<void>

removePeer

removePermission

  • removePermission(accountIdentifier: string): Promise<void>

Private removePermissionsForPeers

respond

Private respondToMessage

Private sendAcknowledgeResponse

Protected sendDisconnectToPeer

  • sendDisconnectToPeer(peer: PeerInfo, transport?: Transport<any, any, any>): Promise<void>

Protected setTransport

  • setTransport(transport?: Transport<any, any, any>): Promise<void>

Generated using TypeDoc