Class: Polites::Span::Image
- Inherits:
-
Polites::Span
- Object
- Node
- Polites::Span
- Polites::Span::Image
- Defined in:
- lib/polites/span/image.rb
Instance Attribute Summary collapse
-
#children ⇒ Object
readonly
Returns the value of attribute children.
-
#description ⇒ Object
readonly
Returns the value of attribute description.
-
#filename ⇒ Object
readonly
Returns the value of attribute filename.
-
#height ⇒ Object
readonly
Returns the value of attribute height.
-
#image ⇒ Object
readonly
Returns the value of attribute image.
-
#title ⇒ Object
readonly
Returns the value of attribute title.
-
#width ⇒ Object
readonly
Returns the value of attribute width.
Instance Method Summary collapse
- #eql?(other) ⇒ Boolean
-
#initialize(children, image:, filename: nil, title: nil, description: nil, width: nil, height: nil) ⇒ Image
constructor
A new instance of Image.
Methods inherited from Polites::Span
Methods inherited from Node
Constructor Details
#initialize(children, image:, filename: nil, title: nil, description: nil, width: nil, height: nil) ⇒ Image
Returns a new instance of Image.
9 10 11 12 13 14 15 16 17 |
# File 'lib/polites/span/image.rb', line 9 def initialize(children, image:, filename: nil, title: nil, description: nil, width: nil, height: nil) super(children) @image = image @filename = filename @title = title @description = description @width = width @height = height end |
Instance Attribute Details
#children ⇒ Object (readonly)
Returns the value of attribute children.
7 8 9 |
# File 'lib/polites/span/image.rb', line 7 def children @children end |
#description ⇒ Object (readonly)
Returns the value of attribute description.
7 8 9 |
# File 'lib/polites/span/image.rb', line 7 def description @description end |
#filename ⇒ Object (readonly)
Returns the value of attribute filename.
7 8 9 |
# File 'lib/polites/span/image.rb', line 7 def filename @filename end |
#height ⇒ Object (readonly)
Returns the value of attribute height.
7 8 9 |
# File 'lib/polites/span/image.rb', line 7 def height @height end |
#image ⇒ Object (readonly)
Returns the value of attribute image.
7 8 9 |
# File 'lib/polites/span/image.rb', line 7 def image @image end |
#title ⇒ Object (readonly)
Returns the value of attribute title.
7 8 9 |
# File 'lib/polites/span/image.rb', line 7 def title @title end |
#width ⇒ Object (readonly)
Returns the value of attribute width.
7 8 9 |
# File 'lib/polites/span/image.rb', line 7 def width @width end |
Instance Method Details
#eql?(other) ⇒ Boolean
19 20 21 22 23 24 25 26 27 |
# File 'lib/polites/span/image.rb', line 19 def eql?(other) super && image == other.image && filename == other.filename && title == other.title && description == other.description && width == other.width && height == other.height end |