Sha256: 1142de09f68792a8acd90aec1cb8d81f96a68a079c4fb3757b728489c1e74499

Contents?: true

Size: 770 Bytes

Versions: 24

Compression:

Stored size: 770 Bytes

Contents

require_relative './htmllog.rb'
require_relative './jsonlog.rb'
require_relative './yamllog.rb'

class Logger
	@@timers=Hash.new
	@@html_log=HtmlLog.new
  @@json_log=JsonLog.new
  @@yaml_log=YamlLog.new
	def self.start_task task
		@@timers[task]=Timer.new
		Console.announce_task_start task
		@@html_log.start_task task
  	end

  	def self.end_task task
  		elapsed=@@timers[task].elapsed
  		@@html_log.end_task task
  	end

  	def self.finalize
  		@@html_log.finalize
      @@json_log.finalize
      @@yaml_log.finalize
  	end

  	def self.start_command command
      Console.start_command command
      //
      @@html_log.start_command command
  	end

  	def self.end_command command
      Console.end_command command
      @@html_log.end_command command
  	end
end

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
dev_tasks-1.0.37 lib/logger.rb
dev_tasks-1.0.35 lib/logger.rb
dev_tasks-1.0.34 lib/logger.rb
dev_tasks-1.0.33 lib/logger.rb
dev_tasks-1.0.31 lib/logger.rb
dev_tasks-1.0.30 lib/logger.rb
dev_tasks-1.0.29 lib/logger.rb
dev_tasks-1.0.28 lib/logger.rb
dev_tasks-1.0.12 lib/logger.rb
dev_tasks-1.0.11 lib/logger.rb
dev_tasks-1.0.10 lib/logger.rb
dev_tasks-1.0.9 lib/logger.rb
dev_tasks-1.0.8 lib/logger.rb
dev_tasks-1.0.7 lib/logger.rb
dev_tasks-1.0.6 lib/logger.rb
dev_tasks-1.0.5 lib/logger.rb
dev_tasks-1.0.4 lib/logger.rb
dev_tasks-1.0.3 lib/logger.rb
dev_tasks-1.0.2 lib/logger.rb
dev_tasks-1.0.1 lib/logger.rb