Represents the data type Timestamp without time zone.

Methods
Public Instance methods
escape( value )

Escapes value to be saved in database.

# File lib/momomoto/datatype/timestamp_without_time_zone.rb, line 11
      def escape( value )
        case value
          when nil then 'NULL'
          when String then "'#{Database.escape_string(value)}'"
          else "'#{Database.escape_string(value.strftime('%Y-%m-%d %H:%M:%S'))}'"
        end
      end
filter_set( value )

Values are filtered by this function when being set. Returns an instance of Time or nil if value is nil or empty.

# File lib/momomoto/datatype/timestamp_without_time_zone.rb, line 21
      def filter_set( value )
        case value
          when nil, '' then nil
          when ::Time then value
          when String then ::Time.parse( value )
          else raise Error
        end
       rescue => e
        raise ConversionError, "Error while parsing Timestamp"
      end