Class: PDTP::Server::Trust::Edge

Inherits:
Object
  • Object
show all
Defined in:
lib/pdtp/server/trust.rb

Overview

struct for storing a single trust relationship

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(trust = 1.0, success = 1.0, transfers = 1.0) ⇒ Edge

Returns a new instance of Edge.



31
32
33
34
35
# File 'lib/pdtp/server/trust.rb', line 31

def initialize(trust = 1.0, success = 1.0, transfers = 1.0)
  @trust = trust
  @success = success
  @transfers = transfers
end

Instance Attribute Details

#successObject

Returns the value of attribute success.



29
30
31
# File 'lib/pdtp/server/trust.rb', line 29

def success
  @success
end

#transfersObject

Returns the value of attribute transfers.



29
30
31
# File 'lib/pdtp/server/trust.rb', line 29

def transfers
  @transfers
end

#trustObject

Returns the value of attribute trust.



29
30
31
# File 'lib/pdtp/server/trust.rb', line 29

def trust
  @trust
end