java - Jersey: Exception Mapper to validate enum values while marshaling request payload -



java - Jersey: Exception Mapper to validate enum values while marshaling request payload -

using many enum classes rest application. things likes status, currency etc covered using enums. right have validate every request @ rest controller level against it's corresponding enum value. there way grab error @ marshaling level , handle via exception mapper? webservice supports both xml , json formats. xml taken care jaxb , json implemented using jackson api.

for understand, trying same : exception mapping enum

so missing might @jsoncreator fromstring method add together in enum code.

java rest jaxb jersey jackson

Comments

Popular posts from this blog

assembly - What is the addressing mode for ld, add, and rjmp instructions? -

vowpalwabbit - Interpreting Vowpal Wabbit results: Why are some lines appended by "h"? -

Is there a way to convert an HTML page styled with Bootstrap CSS into email-compatible html? -