@Test public void deserialize() { Assert.assertThat(datatype.deserialize(null), is(nullValue())); Assert.assertThat(datatype.deserialize(""), is(nullValue())); Assert.assertThat(datatype.deserialize("1"), is(Context.getFormService().getForm(1))); }
@Override public Form deserialize(String serializedValue) { if (StringUtils.isEmpty(serializedValue)) { return null; } return Context.getFormService().getForm(Integer.valueOf(serializedValue)); }
FormDatatype extends SerializingCustomDatatype<Form> { @Override public Form deserialize(String serializedValue) { if (StringUtils.isEmpty(serializedValue)) { return null; } return Context.getFormService().getForm(Integer.valueOf(serializedValue)); } }
FormDatatype extends SerializingCustomDatatype<Form> { @Override public Form deserialize(String serializedValue) { if (StringUtils.isEmpty(serializedValue)) { return null; } return Context.getFormService().getForm(Integer.valueOf(serializedValue)); }  }
FormDatatype extends SerializingCustomDatatype<Form> { @Override public Form deserialize(String serializedValue) { if (StringUtils.isEmpty(serializedValue)) { return null; } return Context.getFormService().getForm(Integer.valueOf(serializedValue)); }  @Override Form deserialize(String serializedValue); @Override String serialize(Form typedValue); }
FormDatatype extends SerializingCustomDatatype<Form> { @Override public Form deserialize(String serializedValue) { if (StringUtils.isEmpty(serializedValue)) { return null; } return Context.getFormService().getForm(Integer.valueOf(serializedValue)); }  @Override Form deserialize(String serializedValue); @Override String serialize(Form typedValue);  }