Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

@ConsumeMime

 
Smari Oumaya
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I always find this notation in tutorials concerning web services REST :"@ConsumeMime("application/(employee)+xml") ". Can someone explain me how to use it.
 
Ivan Krizsan
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi!
It was not entirely easy, but I finally found the API documentation:
https://jersey.dev.java.net/nonav/apidocs/latest/jersey/javax/ws/rs/Consumes.html
By the way, I think the annotation has been renamed to @Consumes in the latest version of Jersey (the JAX-RS reference implementation). Correct me if I am wrong.
Best wishes!
 
Smari Oumaya
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks, but i'm wondering about "employee", how can i define my classes to use them in the consumes annotation. I hope that my question is more clear now.
 
Smari Oumaya
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
please, i really need help!
i can't find how to define my classes in the clause of @consumes.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic