Class: OpenXml::Parts::Rels::Relationship
- Inherits:
-
Struct
- Object
- Struct
- OpenXml::Parts::Rels::Relationship
- Defined in:
- lib/open_xml/parts/rels.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
Returns the value of attribute id.
-
#target ⇒ Object
Returns the value of attribute target.
-
#type ⇒ Object
Returns the value of attribute type.
Instance Method Summary collapse
-
#initialize(type, target, id = nil) ⇒ Relationship
constructor
A new instance of Relationship.
Constructor Details
#initialize(type, target, id = nil) ⇒ Relationship
Returns a new instance of Relationship.
47 48 49 |
# File 'lib/open_xml/parts/rels.rb', line 47 def initialize(type, target, id=nil) super type, target, id || "R#{SecureRandom.hex}" end |
Instance Attribute Details
#id ⇒ Object
Returns the value of attribute id
46 47 48 |
# File 'lib/open_xml/parts/rels.rb', line 46 def id @id end |
#target ⇒ Object
Returns the value of attribute target
46 47 48 |
# File 'lib/open_xml/parts/rels.rb', line 46 def target @target end |
#type ⇒ Object
Returns the value of attribute type
46 47 48 |
# File 'lib/open_xml/parts/rels.rb', line 46 def type @type end |