Class: Diograph::Connection
- Inherits:
-
Object
- Object
- Diograph::Connection
- Defined in:
- lib/diograph/connection.rb
Instance Attribute Summary collapse
-
#from_diory ⇒ Object
readonly
Returns the value of attribute from_diory.
-
#to_diory ⇒ Object
readonly
Returns the value of attribute to_diory.
Instance Method Summary collapse
- #from_diory_id ⇒ Object
-
#initialize(args = {}) ⇒ Connection
constructor
A new instance of Connection.
- #to_diory_id ⇒ Object
Constructor Details
#initialize(args = {}) ⇒ Connection
Returns a new instance of Connection.
7 8 9 10 |
# File 'lib/diograph/connection.rb', line 7 def initialize(args={}) @from_diory = args[:from_diory] @to_diory = args[:to_diory] end |
Instance Attribute Details
#from_diory ⇒ Object (readonly)
Returns the value of attribute from_diory.
5 6 7 |
# File 'lib/diograph/connection.rb', line 5 def from_diory @from_diory end |
#to_diory ⇒ Object (readonly)
Returns the value of attribute to_diory.
5 6 7 |
# File 'lib/diograph/connection.rb', line 5 def to_diory @to_diory end |
Instance Method Details
#from_diory_id ⇒ Object
12 13 14 15 |
# File 'lib/diograph/connection.rb', line 12 def from_diory_id nil if @from_diory.nil? @from_diory.diory_id end |
#to_diory_id ⇒ Object
17 18 19 20 |
# File 'lib/diograph/connection.rb', line 17 def to_diory_id nil if @to_diory.nil? @to_diory.diory_id end |