module MotionVj::Logger

Public Class Methods

error(msg) click to toggle source
# File lib/motion_vj/logger.rb, line 7
def self.error(msg)
  $stderr.puts format(msg, 'ERROR')
end
info(msg) click to toggle source
# File lib/motion_vj/logger.rb, line 3
def self.info(msg)
  $stdout.puts format(msg, 'INFO')
end

Private Class Methods

format(msg, type) click to toggle source
# File lib/motion_vj/logger.rb, line 13
def self.format(msg, type)
  "[motionvj][#{ Time.now.utc.strftime("%Y-%m-%d %H:%M:%S %Z") }][#{ type }]: #{ msg }"
end