User (mail: String, person: Resource)
Person (name: String, Role: Resource)
Role (name: String, Team: Resource)
Team (name: String)
So I have 3 nested Relations. To get everything I use Query with include:
/users/1?include=person,person.role,person.role.team
But thats difficult to program. And write nice code.
I tried just to load Query, with ID and find. Then take that information and load Person (but for Person, I have no Person-ID, to call Query(resourceType, resourceIDs) so I have to use the include-method to get something like this:
Hello,
My class looks a little big like this
User (mail: String, person: Resource) Person (name: String, Role: Resource) Role (name: String, Team: Resource) Team (name: String)
So I have 3 nested Relations. To get everything I use Query with include: /users/1?include=person,person.role,person.role.team
But thats difficult to program. And write nice code.
I tried just to load Query, with ID and find. Then take that information and load Person (but for Person, I have no Person-ID, to call Query(resourceType, resourceIDs) so I have to use the include-method to get something like this:
Is there an easier way?