pascallouisperez / jsonmarshaller

JsonMarshaller is a Java 1.5 library that allows marshalling and unmarshalling of JSON objects to and from entities ("Java classes").
Apache License 2.0
1 stars 0 forks source link

Disallow @Value on non @Entity classes #39

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
See code below. Currently the behavior of the JsonMarshaller is somewhat 
surprising. It would be a better to throw with a clear message.

@Test
public void subclass() {
  assertEquals("{}", TwoLattes.createMarshaller(Foo.class).marshall(new Foo()).toString());
}

@Entity static class Foo extends Bar {}

static class Bar {
  @Value String foo = "bar";
}

Original issue reported on code.google.com by pascallo...@gmail.com on 10 Jul 2010 at 8:13

GoogleCodeExporter commented 9 years ago

Original comment by pascallo...@gmail.com on 28 Jul 2010 at 12:41