@Override public StructuredJsonGenerator writeValue(Date date, TimestampFormat timestampFormat) { try { writer.writeTimestamp(Timestamp.forDateZ(date)); } catch (IOException e) { throw new SdkClientException(e); } return this; }
@Override final void writeBodyTo(IonWriter writer, SymbolTableProvider symbolTableProvider) throws IOException { writer.writeTimestamp(_timestamp_value); }
@Override public StructuredJsonGenerator writeValue(Date date, TimestampFormat timestampFormat) { try { writer.writeTimestamp(Timestamp.forDateZ(date)); } catch (IOException e) { throw new SdkClientException(e); } return this; }
@Override final void writeBodyTo(IonWriter writer, SymbolTableProvider symbolTableProvider) throws IOException { writer.writeTimestamp(_timestamp_value); }
private static void doPrintVersion() throws IOException { IonTextWriterBuilder b = IonTextWriterBuilder.pretty(); b.setCharset(IonTextWriterBuilder.ASCII); IonWriter w = b.build((Appendable)System.out); w.stepIn(IonType.STRUCT); { w.setFieldName("version"); w.writeString(info.getProjectVersion()); w.setFieldName("build_time"); w.writeTimestamp(info.getBuildTime()); } w.stepOut(); w.finish(); System.out.println(); } }
@Override final void writeBodyTo(IonWriter writer, SymbolTableProvider symbolTableProvider) throws IOException { writer.writeTimestamp(_timestamp_value); }
@Override public StructuredJsonGenerator writeValue(Date date) { try { writer.writeTimestamp(Timestamp.forDateZ(date)); } catch (IOException e) { throw new SdkClientException(e); } return this; }
@Override public StructuredJsonGenerator writeValue(Instant instant) { try { Date d = instant != null ? Date.from(instant) : null; writer.writeTimestamp(Timestamp.forDateZ(d)); } catch (IOException e) { throw SdkClientException.builder().cause(e).build(); } return this; }
@Override public StructuredJsonGenerator writeValue(Instant instant) { try { Date d = instant != null ? Date.from(instant) : null; writer.writeTimestamp(Timestamp.forDateZ(d)); } catch (IOException e) { throw SdkClientException.builder().cause(e).build(); } return this; }
public void writeValue(Timestamp value) throws IOException { _verifyValueWrite("write timestamp"); if (value == null) { _writer.writeNull(); } else { _writer.writeTimestamp(value); } }
public void writeDate(Calendar value) throws JsonGenerationException, IOException { _verifyValueWrite("write date value"); _writer.writeTimestamp(Timestamp.forCalendar(value)); } /*
private static void doPrintVersion() throws IOException { IonTextWriterBuilder b = IonTextWriterBuilder.pretty(); b.setCharset(IonTextWriterBuilder.ASCII); IonWriter w = b.build((Appendable)System.out); w.stepIn(IonType.STRUCT); { w.setFieldName("version"); w.writeString(info.getProjectVersion()); w.setFieldName("build_time"); w.writeTimestamp(info.getBuildTime()); } w.stepOut(); w.finish(); System.out.println(); } }
private static void doPrintVersion() throws IOException { IonTextWriterBuilder b = IonTextWriterBuilder.pretty(); b.setCharset(IonTextWriterBuilder.ASCII); IonWriter w = b.build((Appendable)System.out); w.stepIn(IonType.STRUCT); { w.setFieldName("version"); w.writeString(info.getProjectVersion()); w.setFieldName("build_time"); w.writeTimestamp(info.getBuildTime()); } w.stepOut(); w.finish(); System.out.println(); } }