@Test public void shouldConvertIeTime56ToTimestamp() { final long timestamp = ZonedDateTime.now(ZoneOffset.UTC).toInstant().toEpochMilli(); final TimestampMeasurementElementDto expected = new TimestampMeasurementElementDto(timestamp); final IeTime56 source = new IeTime56(timestamp); final TimestampMeasurementElementDto actual = this.converter.convert(source, null, null); assertThat(actual).isEqualTo(expected); }
@Override public TimestampMeasurementElementDto convert(final IeTime56 source, final Type<? extends TimestampMeasurementElementDto> destinationType, final MappingContext mappingContext) { return new TimestampMeasurementElementDto(source.getTimestamp()); }
IeTime56Converter extends CustomConverter<IeTime56, TimestampMeasurementElementDto> { @Override public TimestampMeasurementElementDto convert(final IeTime56 source, final Type<? extends TimestampMeasurementElementDto> destinationType, final MappingContext mappingContext) { return new TimestampMeasurementElementDto(source.getTimestamp()); } }
IeTime56Converter extends CustomConverter<IeTime56, TimestampMeasurementElementDto> { @Override public TimestampMeasurementElementDto convert(final IeTime56 source, final Type<? extends TimestampMeasurementElementDto> destinationType, final MappingContext mappingContext) { return new TimestampMeasurementElementDto(source.getTimestamp()); }  }
IeTime56Converter extends CustomConverter<IeTime56, TimestampMeasurementElementDto> { @Override public TimestampMeasurementElementDto convert(final IeTime56 source, final Type<? extends TimestampMeasurementElementDto> destinationType, final MappingContext mappingContext) { return new TimestampMeasurementElementDto(source.getTimestamp()); }  @Override TimestampMeasurementElementDto convert(final IeTime56 source,
            final Type<? extends TimestampMeasurementElementDto> destinationType, final MappingContext mappingContext); }
IeTime56Converter extends CustomConverter<IeTime56, TimestampMeasurementElementDto> { @Override public TimestampMeasurementElementDto convert(final IeTime56 source, final Type<? extends TimestampMeasurementElementDto> destinationType, final MappingContext mappingContext) { return new TimestampMeasurementElementDto(source.getTimestamp()); }  @Override TimestampMeasurementElementDto convert(final IeTime56 source,
            final Type<? extends TimestampMeasurementElementDto> destinationType, final MappingContext mappingContext);  }