I am developing a server side application (not client). I have a list operation where I am using @GET
and I am passing the parameters as @QueryParam
. Should I use @FormParam
? Will it be helpful while developing the client?
Asked
Active
Viewed 503 times
0
Thiago Negri
- 4,965
- 2
- 25
- 38
Jay
- 379
- 2
- 5
- 21
-
Is the client an HTML form element, or a program? – bmargulies Nov 19 '14 at 12:37
-
Not sure bmargulies :( We are exposed only to server implementation:( – Jay Nov 19 '14 at 12:41
1 Answers
2
The @FormParam
annotation will expect the parameter to be in the body of the request as sent by an HTML form
submit.
An HTTP GET should not use a request body. So, keep using @QueryParam
for @GET
.
See also:
Community
- 1
- 1
Thiago Negri
- 4,965
- 2
- 25
- 38