@Override public Object getProperty(String key) throws PropertyException { return jaxbMarshaller.getProperty(key); }
@Override protected void preWriteTo(final Object object, final Class<?> type, final Type genericType, final Annotation[] annotations, final MediaType mediaType, final MultivaluedMap<String, Object> httpHeaders, final Marshaller marshaller) throws JAXBException { super.preWriteTo(object, type, genericType, annotations, mediaType, httpHeaders, marshaller); // Entity Filtering. if (marshaller.getProperty(MarshallerProperties.OBJECT_GRAPH) == null) { final Object objectGraph = provider.get().getFilteringObject(genericType, true, annotations); if (objectGraph != null) { marshaller.setProperty(MarshallerProperties.OBJECT_GRAPH, objectGraph); } } }
try { header = (String) m.getProperty(property); } catch (PropertyException e) { header = (String) m.getProperty(property); } catch (PropertyException ex) {
public Object getProperty(String s) throws PropertyException { return marshaller.getProperty(s); }
public Object getProperty(String key) throws PropertyException { return jaxbMarshaller.getProperty(key); }
/** * Returns the encoding of the XML document to write. */ private String getEncoding() throws PropertyException { return (String) marshaller.getProperty(JAXB_ENCODING); }
public Object getProperty(String s) throws PropertyException { return marshaller.getProperty(s); }
public Object getProperty(String s) throws PropertyException { return marshaller.getProperty(s); }
/** * Delegates to the wrapped marshaller. This method is invoked by the parent * class if the given name was not one of the {@link XML} constants. */ @Override Object getStandardProperty(final String name) throws PropertyException { return marshaller.getProperty(name); }
/** * {@inheritDoc} */ @Override public Object getProperty( final String name ) throws PropertyException { return marshaller.getProperty( name ); }
public Object getProperty(String s) throws PropertyException { return marshaller.getProperty(s); }
@Override public Object getProperty(String key) throws PropertyException { return jaxbMarshaller.getProperty(key); }
public Object getProperty(String key) throws PropertyException { return jaxbMarshaller.getProperty(key); }
/** * Returns the encoding of the XML document to write. */ private String getEncoding() throws PropertyException { return (String) marshaller.getProperty(JAXB_ENCODING); }
/** * Delegates to the wrapped marshaller. This method is invoked by the parent * class if the given name was not one of the {@link XML} constants. */ @Override Object getStandardProperty(final String name) throws PropertyException { return marshaller.getProperty(name); }
@Override public Object getProperty(String key) throws PropertyException { return jaxbMarshaller.getProperty(key); }
@Nullable private static Object _getProperty (@Nonnull final Marshaller aMarshaller, @Nonnull final String sPropertyName) { try { return aMarshaller.getProperty (sPropertyName); } catch (final PropertyException ex) { throw new IllegalArgumentException ("Failed to get JAXB property '" + sPropertyName + "'", ex); } }
@Nullable private static Object _getProperty (@Nonnull final Marshaller aMarshaller, @Nonnull final String sPropertyName) { try { return aMarshaller.getProperty (sPropertyName); } catch (final PropertyException ex) { throw new IllegalArgumentException ("Failed to get JAXB property '" + sPropertyName + "'", ex); } }
@Override public void marshal(Object jaxbElement, OutputStream os) throws JAXBException { try { marshaller.marshal(jaxbElement, new FilterInvalidXmlCharsOutputStreamWriter(os, (String) marshaller.getProperty(JAXB_ENCODING))); } catch (UnsupportedEncodingException e) { throw new RuntimeException(localeManager.resolveMessage("apiError.output_stream_filter.exception"), e); } }
@Override protected void preWriteTo(final Object object, final Class<?> type, final Type genericType, final Annotation[] annotations, final MediaType mediaType, final MultivaluedMap<String, Object> httpHeaders, final Marshaller marshaller) throws JAXBException { super.preWriteTo(object, type, genericType, annotations, mediaType, httpHeaders, marshaller); // Entity Filtering. if (marshaller.getProperty(MarshallerProperties.OBJECT_GRAPH) == null) { final Object objectGraph = provider.get().getFilteringObject(genericType, true, annotations); if (objectGraph != null) { marshaller.setProperty(MarshallerProperties.OBJECT_GRAPH, objectGraph); } } }