class ExecutionLog

Attributes

endDate[RW]
executionId[RW]
host[RW]
startDate[RW]

Public Class Methods

from_json(data) click to toggle source
# File lib/logs/execution_log.rb, line 16
def self.from_json data
  executionLog = ExecutionLog.new
  executionLog.executionId = data['execution_id']
  executionLog.startDate = data['start_date']
  executionLog.endDate = data['end_date']
  executionLog.host = data['host']
  executionLog
end
new() click to toggle source
# File lib/logs/execution_log.rb, line 11
def initialize
  @host = Socket.gethostname
  @startDate = Time.now.to_ms
end

Public Instance Methods

to_json(options={}) click to toggle source
# File lib/logs/execution_log.rb, line 25
def to_json(options={})
  {'execution_id' => @executionId, 'start_date' => @startDate, 'end_date' => @endDate, 'host' => @host}.to_json
end