Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFE: use a JsonView for every resource of an application #24

Closed
cowtowncoder opened this issue Jul 25, 2013 · 1 comment
Closed

RFE: use a JsonView for every resource of an application #24

cowtowncoder opened this issue Jul 25, 2013 · 1 comment
Milestone

Comments

@cowtowncoder
Copy link
Member

(note: migrated from https://github.com/FasterXML/jackson-jaxrs-json-provider/issues/15)


As this stackoverflow question suggests, JsonView can only be added on methods. So, if one need to use a JsonView globally — for every resource of an application — it has a ton of work to do.

Can we use a global JsonView: objectMapper.setDefaultView(View.Public.class)?
Can we annotate Resource classes with JsonView?
@cowtowncoder
Copy link
Member Author

Implement; now providers have methods:

  • setDefaultReadView
  • setDefaultWriteView

for specifying view to use for cases where endpoint does not have active view definition.

cowtowncoder added a commit that referenced this issue Oct 10, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant