Class: Casper::Entity::Account

Inherits:
Object
  • Object
show all
Defined in:
lib/entity/account.rb

Overview

An Account is a structure that represents a user on a Casper Network.

Instance Method Summary collapse

Constructor Details

#initialize(account_hash, named_keys, main_purse, associated_keys, action_thresholds) ⇒ Account

Returns a new instance of Account.

Parameters:

  • account_hash (CLAccountHash)
  • named_keys (Array)
  • main_purse (CLUref)

    The account's main purse URef

  • associated_keys (Array)
  • action_thresholds (Array<ActionThresHolds>)


11
12
13
14
15
16
17
# File 'lib/entity/account.rb', line 11

def initialize(, named_keys, main_purse, associated_keys, action_thresholds)
  @account_hash = 
  @named_keys = named_keys
  @main_purse = main_purse
  @associated_keys = associated_keys
  @action_thresholds = action_thresholds
end

Instance Method Details

#get_account_hashCLAccountHash

Returns:

  • (CLAccountHash)


20
21
22
# File 'lib/entity/account.rb', line 20

def 
  @account_hash
end

#get_action_thresholdsActionThresHolds

Returns:

  • (ActionThresHolds)


40
41
42
# File 'lib/entity/account.rb', line 40

def get_action_thresholds
  @action_thresholds
end

#get_associated_keysArray<AssociatedKey>

Returns:



35
36
37
# File 'lib/entity/account.rb', line 35

def get_associated_keys
  @associated_keys
end

#get_main_purseCLUref

Returns:

  • (CLUref)


30
31
32
# File 'lib/entity/account.rb', line 30

def get_main_purse
  @main_purse
end

#get_named_keysArray

Returns:

  • (Array)


25
26
27
# File 'lib/entity/account.rb', line 25

def get_named_keys
  @named_keys
end