Class: Time

Inherits:
Object
  • Object
show all
Defined in:
lib/dgaff/time.rb

Instance Method Summary collapse

Instance Method Details

#gmtObject



13
14
15
# File 'lib/dgaff/time.rb', line 13

def gmt
  return to_time.gmtime
end

#super_parse(value) ⇒ Object



2
3
4
5
6
7
8
9
10
11
# File 'lib/dgaff/time.rb', line 2

def super_parse(value)
  answer = nil
  begin 
    self.parse
  rescue
    year,month,day,hour,minute,second = value.split(" ")
    answer = Time.parse("#{year}-#{month}-#{day} #{hour}:#{minute}:#{second}")
  end
  return answer
end