org.eclipse.persistence.internal.helper.Helper.printTime()方法的使用及代码示例

x33g5p2x  于2022-01-20 转载在 其他  
字(6.9k)|赞(0)|评价(0)|浏览(112)

本文整理了Java中org.eclipse.persistence.internal.helper.Helper.printTime()方法的一些代码示例,展示了Helper.printTime()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Helper.printTime()方法的具体详情如下:
包路径:org.eclipse.persistence.internal.helper.Helper
类名称:Helper
方法名:printTime

Helper.printTime介绍

[英]Print the sql.Time.
[中]打印sql。时间

代码示例

代码示例来源:origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * Print the time part of the calendar.
 */
public static String printTime(Calendar calendar) {
  return printTime(calendar, true);
}

代码示例来源:origin: com.haulmont.thirdparty/eclipselink

/**
 * Print the time part of the calendar.
 */
public static String printTime(Calendar calendar) {
  return printTime(calendar, true);
}

代码示例来源:origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * Print the time part of the calendar.
 */
public static String printTime(Calendar calendar) {
  return printTime(calendar, true);
}

代码示例来源:origin: com.haulmont.thirdparty/eclipselink

/**
 * Appends a Time in Symfoware specific format.<br>
 * Symfoware: TIME'hh:mm:ss'
 */
@Override
protected void appendTime(java.sql.Time time, Writer writer) throws IOException {
  writer.write("TIME'" + Helper.printTime(time) + "'");
}

代码示例来源:origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * Appends a Time in Symfoware specific format.<br>
 * Symfoware: TIME'hh:mm:ss'
 */
@Override
protected void appendTime(java.sql.Time time, Writer writer) throws IOException {
  writer.write("TIME'" + Helper.printTime(time) + "'");
}

代码示例来源:origin: com.haulmont.thirdparty/eclipselink

@Override
protected void appendTime(Time time, Writer writer) throws IOException {
  writer.write("TO_TIME('");
  writer.write(Helper.printTime(time));
  writer.write("')");
}

代码示例来源:origin: com.haulmont.thirdparty/eclipselink

/**
 * Answer a platform correct string representation of a Time, suitable for SQL generation.
 * The time is printed in the ODBC platform independent format {t'hh:mm:ss'}.
 */
protected void appendTime(java.sql.Time time, Writer writer) throws IOException {
  writer.write("{t '");
  writer.write(Helper.printTime(time));
  writer.write("'}");
}

代码示例来源:origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * Answer a platform correct string representation of a Time, suitable for SQL generation.
 * The time is printed in the ODBC platform independent format {t'hh:mm:ss'}.
 */
protected void appendTime(java.sql.Time time, Writer writer) throws IOException {
  writer.write("{t '");
  writer.write(Helper.printTime(time));
  writer.write("'}");
}

代码示例来源:origin: org.eclipse.persistence/org.eclipse.persistence.core

@Override
protected void appendTime(Time time, Writer writer) throws IOException {
  writer.write("TO_TIME('");
  writer.write(Helper.printTime(time));
  writer.write("')");
}

代码示例来源:origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * Answer a platform correct string representation of a Time, suitable for SQL generation.
 * The time is printed in the ODBC platform independent format {t'hh:mm:ss'}.
 */
protected void appendTime(java.sql.Time time, Writer writer) throws IOException {
  writer.write("{t '");
  writer.write(Helper.printTime(time));
  writer.write("'}");
}

代码示例来源:origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * Print the Calendar without the nanos portion.
 */
public static String printCalendarWithoutNanos(Calendar calendar) {
  StringBuilder timestampBuf = new StringBuilder();
  timestampBuf.append(printDate(calendar));
  timestampBuf.append(" ");
  timestampBuf.append(printTime(calendar));
  return timestampBuf.toString();
}

代码示例来源:origin: com.haulmont.thirdparty/eclipselink

/**
 * Print the Calendar without the nanos portion.
 */
public static String printCalendarWithoutNanos(Calendar calendar) {
  StringBuilder timestampBuf = new StringBuilder();
  timestampBuf.append(printDate(calendar));
  timestampBuf.append(" ");
  timestampBuf.append(printTime(calendar));
  return timestampBuf.toString();
}

代码示例来源:origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * Print the Calendar without the nanos portion.
 */
public static String printCalendarWithoutNanos(Calendar calendar) {
  StringBuffer timestampBuf = new StringBuffer();
  timestampBuf.append(printDate(calendar));
  timestampBuf.append(" ");
  timestampBuf.append(printTime(calendar));
  return timestampBuf.toString();
}

代码示例来源:origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
*    Answer a platform correct string representation of a Time, suitable for SQL generation.
*    The time is printed in the ODBC platform independent format {t'hh:mm:ss'}.
*/
protected void appendTime(java.sql.Time time, Writer writer) throws IOException {
  if (usesNativeSQL()) {
    writer.write("'");
    writer.write(Helper.printTime(time));
    writer.write("'");
  } else {
    super.appendTime(time, writer);
  }
}

代码示例来源:origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 *    Answer a platform correct string representation of a Time, suitable for SQL generation.
 *    The time is printed in the ODBC platform independent format {t'hh:mm:ss'}.
 */
protected void appendTime(java.sql.Time time, Writer writer) throws IOException {
  if (usesNativeSQL()) {
    writer.write("'");
    writer.write(Helper.printTime(time));
    writer.write("'");
  } else {
    super.appendTime(time, writer);
  }
}

代码示例来源:origin: com.haulmont.thirdparty/eclipselink

/**
*    Answer a platform correct string representation of a Time, suitable for SQL generation.
*    The time is printed in the ODBC platform independent format {t'hh:mm:ss'}.
*/
protected void appendTime(java.sql.Time time, Writer writer) throws IOException {
  if (usesNativeSQL()) {
    writer.write("'");
    writer.write(Helper.printTime(time));
    writer.write("'");
  } else {
    super.appendTime(time, writer);
  }
}

代码示例来源:origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * Appends an MySQL specific time if usesNativeSQL is true otherwise use the ODBC format.
 * Native FORMAT: 'HH:MM:SS'.
 */
protected void appendTime(java.sql.Time time, Writer writer) throws IOException {
  if (usesNativeSQL()) {
    writer.write("'");
    writer.write(Helper.printTime(time));
    writer.write("'");
  } else {
    super.appendTime(time, writer);
  }
}

代码示例来源:origin: com.haulmont.thirdparty/eclipselink

/**
 * Print the sql.Time.
 */
public static String printTime(java.sql.Time time) {
  // PERF: Avoid deprecated get methods, that are now very inefficient and used from toString.
  Calendar calendar = allocateCalendar();
  calendar.setTime(time);
  String string = printTime(calendar);
  releaseCalendar(calendar);
  return string;
}

代码示例来源:origin: org.eclipse.persistence/org.eclipse.persistence.core

/**
 * Print the sql.Time.
 */
public static String printTime(java.sql.Time time) {
  // PERF: Avoid deprecated get methods, that are now very inefficient and used from toString.
  Calendar calendar = allocateCalendar();
  calendar.setTime(time);
  String string = printTime(calendar);
  releaseCalendar(calendar);
  return string;
}

代码示例来源:origin: org.eclipse.persistence/com.springsource.org.eclipse.persistence

/**
 * Print the sql.Time.
 */
public static String printTime(java.sql.Time time) {
  // PERF: Avoid deprecated get methods, that are now very inefficient and used from toString.
  Calendar calendar = allocateCalendar();
  calendar.setTime(time);
  String string = printTime(calendar);
  releaseCalendar(calendar);
  return string;
}

相关文章

Helper类方法