Balance

class Balance(val metadata: ResourceMetadata, val data: BalanceData, var signature: String? = null) : Resource

Balance is a protected resource used to communicate the available amount of each currency held by the PFI on behalf of its customer.

Constructors

Link copied to clipboard
constructor(metadata: ResourceMetadata, data: BalanceData, signature: String? = null)

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
open override val data: BalanceData

The actual resource content. This will always be a JSON object. The Resource Kinds section specifies the content for each individual resource type

Link copied to clipboard
open override val metadata: ResourceMetadata

An object containing fields about the resource

Link copied to clipboard
open override var signature: String?

A message or resource signature is a detached compact JWS as defined in RFC-7515

Functions

Link copied to clipboard
fun sign(did: <Error class: unknown class>)

Signs the Resource using the specified BearerDid

Link copied to clipboard
open override fun toString(): String

Uses Json to serialize the Resource as a json string.

Link copied to clipboard
fun verify()

Verifies the signature of the Resource.