Thanks Michael,

Talking about support of features, would you know if the follow features
are supported:
- Composite keys (e.g. key existing order order number and order line)
- Enum types

Thanks so much again Michael!

Cheers,
Jan


On Fri, Mar 7, 2014 at 11:36 AM, Bolz, Michael <michael.b...@sap.com> wrote:

> Hi Jan,
>
> unfortunately OData in version 2 does not support collections of simple
> properties.
> So the way to go for that issue would be to introduce an Entity e.g. "Tag"
> with a SimpleProperty "Name".
> Then add a navigation from "BlogPost" to "Tag" with name "tags" (with the
> @EdmNavigation annotation).
> This solution is a little clumsy but should work for your use case.
>
> Kind regards,
> Michael
>
>
> On 07.03.2014, at 10:44, Jan Penninkhof <j...@penninkhof.com> wrote:
>
> > Hi All,
> >
> > I hope this is not a very stupid question, but something I just haven't
> > been able to figure out yet. I've chosen to use the annotation based
> model,
> > as it helps me to keep the meta model and the java application nicely
> > consistent.
> >
> > In my model I would like to have something similar to this:
> >
> > @EdmEntitySet(name = "BlogPost")
> > public class BlogPost {
> >
> > @EdmKey
> > @EdmProperty
> > private String id;
> > @EdmProperty
> > private String title;
> > @EdmProperty
> > private String body;
> > @EdmProperty
> > private List<String> tags;
> > ....
> >
> > It is especially with regards to the "tags" property that I wonder how to
> > solve this. I would prefer not to point to another entity with predefined
> > tags, but to have a list of arbitrary tags inside the blog post instead.
> >
> > It seems it can't be done with the @EdmProprety annotation, as it only
> > supports basic properties such as string etc, and no collection types. Is
> > there a way this can be done using annotations?
> >
> > Thanks!
> >
> > - Jan
>
>

Reply via email to