Class: Logue::MsgObjElement

Inherits:
Element show all
Defined in:
lib/logue/elements/msg_obj_element.rb

Instance Attribute Summary

Attributes inherited from Element

#object

Attributes inherited from BaseElement

#context, #writer

Instance Method Summary collapse

Methods inherited from Element

#initialize

Methods inherited from BaseElement

#initialize, #write_line, #write_msg_object

Constructor Details

This class inherits a constructor from Logue::Element

Instance Method Details

#write_elementObject



5
6
7
8
9
10
11
# File 'lib/logue/elements/msg_obj_element.rb', line 5

def write_element
  if @msg == ObjectUtil::NONE
    write_line @object.to_s
  else
    write_line "#{@msg}: #{@object}"
  end
end