Exemplo n.º 1
0
  @Override
  public Object unmarshal(HierarchicalStreamReader reader, UnmarshallingContext context) {

    return Quality.fromName(reader.getValue());
  }
Exemplo n.º 2
0
  @Override
  public void marshal(Object source, HierarchicalStreamWriter writer, MarshallingContext context) {
    Quality q = (Quality) source;

    writer.setValue(q == null ? "" : q.toString());
  }