org.codehaus.jackson.jaxrs.JacksonJaxbJsonProvider Java Examples
The following examples show how to use
org.codehaus.jackson.jaxrs.JacksonJaxbJsonProvider.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: AggregatorWebServiceTest.java From ambari-metrics with Apache License 2.0 | 5 votes |
public AggregatorWebServiceTest() { super(new WebAppDescriptor.Builder( "org.apache.hadoop.metrics2.host.aggregator") .contextPath("jersey-guice-filter") .servletPath("/") .clientConfig(new DefaultClientConfig(JacksonJaxbJsonProvider.class)) .build()); }
Example #2
Source File: JiraRestAccess.java From rtc2jira with GNU General Public License v2.0 | 5 votes |
public JiraRestAccess(String url, String user, String password) { this.restHome = url + JIRA_REST_API_SUFFIX; String userAndPassword = user + ':' + password; this.authentification = new String(Base64.getEncoder().encode(userAndPassword.getBytes())); JacksonJsonProvider jacksonJsonProvider = new JacksonJaxbJsonProvider().configure(DeserializationConfig.Feature.FAIL_ON_UNKNOWN_PROPERTIES, false); objectMapper = jacksonJsonProvider.locateMapper(Object.class, MediaType.APPLICATION_JSON_TYPE); ClientConfig cfg = new DefaultClientConfig(); cfg.getSingletons().add(jacksonJsonProvider); this.client = Client.create(cfg); // this.client.addFilter(new LoggingFilter(System.out)); }
Example #3
Source File: MyriadServletModule.java From incubator-myriad with Apache License 2.0 | 5 votes |
@Override protected void configureServlets() { bind(ClustersResource.class); bind(ConfigurationResource.class); bind(SchedulerStateResource.class); bind(ControllerResource.class); bind(ArtifactsResource.class); bind(GuiceContainer.class); bind(JacksonJaxbJsonProvider.class).in(Scopes.SINGLETON); serve("/api/*").with(GuiceContainer.class); }
Example #4
Source File: OlatRestApplication.java From olat with Apache License 2.0 | 5 votes |
@Override public Set<Class<?>> getClasses() { final Set<Class<?>> classes = new HashSet<Class<?>>(); classes.add(JacksonJaxbJsonProvider.class); classes.addAll(getRestRegistrationService().getClasses()); return classes; }
Example #5
Source File: OlatRestApplication.java From olat with Apache License 2.0 | 5 votes |
@Override public Set<Class<?>> getClasses() { final Set<Class<?>> classes = new HashSet<Class<?>>(); classes.add(JacksonJaxbJsonProvider.class); classes.addAll(getRestRegistrationService().getClasses()); return classes; }
Example #6
Source File: MyApplication.java From Test-Driven-Java-Development-Second-Edition with MIT License | 4 votes |
public MyApplication(BooksEndpoint booksEndpoint) { register(booksEndpoint); register(RequestContextFilter.class); register(JacksonJaxbJsonProvider.class); register(CustomExceptionMapper.class); }
Example #7
Source File: JaxRsClientConfig.java From paymentgateway with GNU General Public License v3.0 | 4 votes |
@Bean public JacksonJaxbJsonProvider jacksonJaxbJsonProvider() { return new JacksonJaxbJsonProvider(); }
Example #8
Source File: JaxRsClientConfig.java From paymentgateway with GNU General Public License v3.0 | 4 votes |
@Bean public JacksonJaxbJsonProvider jacksonJaxbJsonProvider() { return new JacksonJaxbJsonProvider(); }