class String

Example shamelessly stolen from www.dabeaz.com/generators

Public Instance Methods

to_datetime() click to toggle source

parse Apache timestamps

# File examples/parse_apache.rb, line 9
def to_datetime
        DateTime.parse(sub(":", "T"))
end