java - Jersey Resource class interaction? -


Therefore, I'm coming to the speed of jersey and there is a "best practice" question. How hard the resources contained in a file should be

An example:

I have an individual resource and an appointment resource. (I.e.: / person / 1 & amp; / appointment / 12345). For the list of all the appointments for the person, I can do anything like / person / 1 / appointments.

So, my question is, should I implement any method getPersonAppointments () in the person resource category, or just get a reference for an appointment resource class and call that method, all of which The methods are said to return "appointments" together.

I do not know whether it's right or wrong.

Since there are many people in an appointment, and one person has many appointments, the situation is symmetric and You have to pierce the barrier between individuals and appointments.


Comments

Popular posts from this blog

sql - dynamically varied number of conditions in the 'where' statement using LINQ -

asp.net mvc - Dynamically Generated Ajax.BeginForm -

Debug on symbian -