@Test(expected = IllegalArgumentException.class) public void testEmptyValue() { Date timestamp = decoder.decodeValue(""); }
@Override public Date decodeValue(String value) { try { return new Date(Long.parseLong(value) * 1000L); } catch (NumberFormatException e) { throw new IllegalArgumentException("Date property value must be numeric."); } }
DatePropertyValueDecoder implements IPropertyValueDecoder<Date> { @Override public Date decodeValue(String value) { try { return new Date(Long.parseLong(value) * 1000L); } catch (NumberFormatException e) { throw new IllegalArgumentException("Date property value must be numeric."); } } }
DatePropertyValueDecoder implements IPropertyValueDecoder<Date> { @Override public Date decodeValue(String value) { try { return new Date(Long.parseLong(value) * 1000L); } catch (NumberFormatException e) { throw new IllegalArgumentException("Date property value must be numeric."); } } DatePropertyValueDecoder(); }
DatePropertyValueDecoder implements IPropertyValueDecoder<Date> { @Override public Date decodeValue(String value) { try { return new Date(Long.parseLong(value) * 1000L); } catch (NumberFormatException e) { throw new IllegalArgumentException("Date property value must be numeric."); } } DatePropertyValueDecoder(); @Override Date decodeValue(String value); @Override List<Class<Date>> getSupportedTypes(); }
DatePropertyValueDecoder implements IPropertyValueDecoder<Date> { @Override public Date decodeValue(String value) { try { return new Date(Long.parseLong(value) * 1000L); } catch (NumberFormatException e) { throw new IllegalArgumentException("Date property value must be numeric."); } } DatePropertyValueDecoder(); @Override Date decodeValue(String value); @Override List<Class<Date>> getSupportedTypes();  }