class DBRotator::Schema
Attributes
name[R]
Public Class Methods
new(name, schema_regex)
click to toggle source
# File lib/db_rotator.rb, line 165 def initialize(name, schema_regex) @name = name @schema_regex = schema_regex end
Public Instance Methods
to_date()
click to toggle source
# File lib/db_rotator.rb, line 170 def to_date Date.strptime( name.match(@schema_regex)[1], TIME_FORMAT ) end