Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Identity

Hierarchy

  • Identity

Index

Properties

controls

controls: ControlData[] = []

extra

extra: null

label

label: string

lock

lock: boolean

ontid

ontid: string

Methods

addControl

toJson

  • toJson(): string

toJsonObj

  • toJsonObj(): any
  • Serializes to JSON object.

    Returned object will not be stringified.

    Returns any

Static create

  • Creates Identity object encrypting specified private key.

    The identity is not registered on the blockchain. Caller needs to register it.

    Parameters

    • privateKey: PrivateKey

      Private key associated with the identity

    • keyphrase: string

      Password use to encrypt the private key

    • label: string

      Custom label

    • Optional params: ScryptParams

      Optional scrypt params

    Returns Identity

Static importIdentity

  • Import identity

    Parameters

    • label: string

      Name of identity

    • encryptedPrivateKey: PrivateKey

      Encrypted private key

    • password: string

      User's password to decrypt

    • address: Address

      Address to decrypt

    • saltBase64: string

      Salt to decrypt

    • Optional params: ScryptParams

      Optional params to decrypt

    Returns Identity

Static parseJson

Static parseJsonObj

  • Deserializes JSON object.

    Object should be real object, not stringified.

    Parameters

    • obj: any

      JSON object

    Returns Identity

Generated using TypeDoc