Class: EZML::Parser::DynamicAttributes

Inherits:
Struct
  • Object
show all
Defined in:
lib/ezml/parser.rb

Overview

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#old=(value) ⇒ Object

Sets the attribute old

Parameters:

  • value (Object)

    the value to set the attribute old to.

Returns:

  • (Object)

    the newly set value



210
211
212
# File 'lib/ezml/parser.rb', line 210

def old=(value)
  @old = value
end

Instance Method Details

#to_literalObject

This will be a literal for EZML::Buffer#attributes’s last argument, ‘attributes_hashes`.



219
220
221
# File 'lib/ezml/parser.rb', line 219

def to_literal
  [new, stripped_old].compact.join(', ')
end