Class: PhantomMenace::Element

Inherits:
Object
  • Object
show all
Defined in:
lib/phantom_menace/element.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options) ⇒ Element

Returns a new instance of Element.



7
8
9
10
11
# File 'lib/phantom_menace/element.rb', line 7

def initialize(options)
  @attributes = options["attrs"]
  @position = options["position"]
  @text = options["text"]
end

Instance Attribute Details

#attributesObject (readonly)

Returns the value of attribute attributes.



3
4
5
# File 'lib/phantom_menace/element.rb', line 3

def attributes
  @attributes
end

#positionObject (readonly)

Returns the value of attribute position.



4
5
6
# File 'lib/phantom_menace/element.rb', line 4

def position
  @position
end

#textObject (readonly)

Returns the value of attribute text.



5
6
7
# File 'lib/phantom_menace/element.rb', line 5

def text
  @text
end