public class Address {
public static enum State {
// define all 2 letter states here ...
}
// ....
protected State state; // would'nt it be nice if this worked ...
}
public class Company {
// ...
@Embedded protected EIN ein; // IRS tax id
@Embedded protected Address address;
// ...
}
it fails stating that Address$State is an unsupported field type ...
or
if I play with annotations it claims it cannot find <init>()V which of
course is true because there is no public constructor ...
I think something else is going on with the Entity and it's embedded
types since queries on the address such as
select c from Charity where c.address.state='CA'' do not match
anything and no index is auto generated locally ...
On Sep 3, 12:07 am, leszek <[email protected]> wrote:
> It works for me, also without any annotation. Something like:
>
> Enum {
> Enum1, Enum
>
> };
>
> class EnityClass {
> private Enum en;
>
> public Enum getEn() {
> return en;
> }
>
> public void setEn(Enum en) {
> this.en = en;
> }
>
> }
>
> EntityClass e = new EntityClass();
> e. setEn(Enum.Enum1);
> ....
> em.persist(e);
>
> // after lauching localhost.../_ah/admin/ I can see this entity and
> proper 'en' value.
>
> Could you provide more details ?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google App Engine for Java" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/google-appengine-java?hl=en
-~----------~----~----~----~------~----~------~--~---