else if ( value instanceof RubyString ) {
final Time time = Time.valueOf( value.toString() );
statement.setTime( index, time ); // assume local time-zone
}
else { // DateTime ( ActiveSupport::TimeWithZone.to_time )
final RubyFloat timeValue = value.convertToFloat(); // to_f
final Time time = new Time(timeValue.getLongValue() * 1000); // millis
// java.sql.Time is expected to be only up to second precision
statement.setTime( index, time, getTimeZoneCalendar("GMT") );
}
}
}