Guest User

Untitled

a guest
Nov 22nd, 2017
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. @XmlRootElement
  2. @XmlAccessorType(XmlAccessType.FIELD)
  3. public class Test {
  4.  
  5. @XmlElement(name="id")
  6. protected Long Id;
  7.  
  8. @XmlElement(name = "students")
  9. protected Set<String> students;
  10.  
  11. //Getters and setters
  12. }
  13.  
  14. @POST
  15. @Path("/test")
  16. public String getCounts(JAXBElement<Test> jaxFilters) {
  17. Test filter = jaxFilter.getValue();
  18. //Some logic
  19. }
  20.  
  21. @POST
  22. @Path("/test")
  23. public String getCounts(JAXBElement<List<Test>> jaxFilters) {
  24. List<Test> filter = jaxFilter.getValue();
  25. //Some logic
  26. }
Add Comment
Please, Sign In to add comment