Modifier and Type | Method and Description |
---|---|
void |
Message.setEntity(String value,
MediaType mediaType)
Sets a textual entity.
|
Modifier and Type | Method and Description |
---|---|
static MediaType |
MediaType.getMostSpecific(MediaType... mediaTypes)
Returns the first of the most specific media type of the given array of
MediaType s. |
MediaType |
MediaType.getParent()
Returns the parent metadata if available or null.
|
MediaType |
ClientInfo.getPreferredMediaType(List<MediaType> supported)
Returns the preferred media type among a list of supported ones, based on
the client preferences.
|
MediaType |
ClientInfo.getPreferredPatch(List<MediaType> supported)
Returns the preferred patch among a list of supported ones, based on the
client preferences.
|
static MediaType |
MediaType.register(String name,
String description)
Register a media type as a known type that can later be retrieved using
valueOf(String) . |
static MediaType |
MediaType.valueOf(String name)
Returns the media type associated to a name.
|
Modifier and Type | Method and Description |
---|---|
List<Preference<MediaType>> |
ClientInfo.getAcceptedMediaTypes()
Returns the modifiable list of media type preferences.
|
List<Preference<MediaType>> |
ClientInfo.getAcceptedPatches()
Returns the modifiable list of patch preferences.
|
Modifier and Type | Method and Description |
---|---|
static MediaType |
MediaType.getMostSpecific(MediaType... mediaTypes)
Returns the first of the most specific media type of the given array of
MediaType s. |
Modifier and Type | Method and Description |
---|---|
MediaType |
ClientInfo.getPreferredMediaType(List<MediaType> supported)
Returns the preferred media type among a list of supported ones, based on
the client preferences.
|
MediaType |
ClientInfo.getPreferredPatch(List<MediaType> supported)
Returns the preferred patch among a list of supported ones, based on the
client preferences.
|
void |
ClientInfo.setAcceptedMediaTypes(List<Preference<MediaType>> acceptedMediaTypes)
Sets the media type preferences.
|
void |
ClientInfo.setAcceptedPatches(List<Preference<MediaType>> acceptedPatches)
Sets the patch preferences.
|
Constructor and Description |
---|
ClientInfo(MediaType mediaType)
Constructor from a media type.
|
Modifier and Type | Method and Description |
---|---|
MediaType |
MetadataExtension.getMediaType()
Returns the media type.
|
Modifier and Type | Method and Description |
---|---|
protected List<Preference<MediaType>> |
StrictConneg.getMediaTypePrefs()
Returns the enriched list of media type preferences.
|
protected List<Preference<MediaType>> |
FlexibleConneg.getMediaTypePrefs()
Returns the enriched list of media type preferences.
|
Modifier and Type | Method and Description |
---|---|
float |
StrictConneg.scoreMediaType(MediaType mediaType)
Scores a media type relatively to enriched client preferences.
|
Modifier and Type | Method and Description |
---|---|
void |
ConverterHelper.updatePreferences(List<Preference<MediaType>> preferences,
MediaType mediaType,
float score)
Updates the preferences of the given
ClientInfo object with
conversion capabilities for the given entity class. |
Modifier and Type | Method and Description |
---|---|
<T> void |
ConverterHelper.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity)
Updates the preferences of the given
ClientInfo object with
conversion capabilities for the given entity class. |
<T> void |
DefaultConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity) |
void |
ConverterHelper.updatePreferences(List<Preference<MediaType>> preferences,
MediaType mediaType,
float score)
Updates the preferences of the given
ClientInfo object with
conversion capabilities for the given entity class. |
Modifier and Type | Method and Description |
---|---|
MediaType |
ContentType.getMediaType()
Returns the media type.
|
static MediaType |
ContentType.readMediaType(String contentType)
Parses the given content type header and returns the media type.
|
Modifier and Type | Method and Description |
---|---|
static String |
ContentType.writeHeader(MediaType mediaType,
CharacterSet characterSet)
Writes the HTTP "Content-Type" header.
|
Constructor and Description |
---|
ContentType(MediaType mediaType,
CharacterSet characterSet)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
Representation |
FileEntity.getRepresentation(MediaType defaultMediaType,
int timeToLive) |
Representation |
ZipEntryEntity.getRepresentation(MediaType defaultMediaType,
int timeToLive) |
abstract Representation |
Entity.getRepresentation(MediaType defaultMediaType,
int timeToLive)
Returns a representation of this local entity.
|
protected Response |
DirectoryServerResource.getRepresentation(String resourceUri,
MediaType acceptedMediaType)
Returns a representation of the resource at the target URI.
|
Constructor and Description |
---|
ZipEntryRepresentation(MediaType mediaType,
ZipFile zipFile,
ZipEntry entry)
Deprecated.
|
ZipEntryRepresentation(MediaType mediaType,
ZipFile zipFile,
ZipEntry entry,
int timeToLive)
Constructor.
|
Constructor and Description |
---|
VariantInfo(MediaType mediaType)
Constructor.
|
VariantInfo(MediaType mediaType,
MethodAnnotationInfo annotationInfo)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
static boolean |
FormUtils.isParameterFound(Parameter searchedParam,
MediaType mediaRange)
Indicates if the searched parameter is specified in the given media
range.
|
Modifier and Type | Method and Description |
---|---|
MediaType |
Content.getExternalType()
Returns the expected media type of the external content.
|
MediaType |
Link.getType()
Returns the advisoty media type.
|
MediaType |
Text.getType()
Returns the content type.
|
Modifier and Type | Method and Description |
---|---|
List<MediaType> |
Collection.getAccept()
Returns the accepted media types.
|
Modifier and Type | Method and Description |
---|---|
void |
Content.setExternalType(MediaType externalType)
Sets the expected media type of the external content.
|
void |
Link.setType(MediaType type)
Sets the advisoty media type.
|
void |
Text.setType(MediaType type)
Sets the content type.
|
Modifier and Type | Method and Description |
---|---|
void |
Collection.setAccept(List<MediaType> accept)
Sets the accepted media types.
|
<T> void |
AtomConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity) |
Constructor and Description |
---|
Link(Reference href,
Relation rel,
MediaType type)
Constructor.
|
Text(MediaType type)
Constructor.
|
Text(MediaType type,
String content)
Constructor.
|
Constructor and Description |
---|
TemplateRepresentation(Representation templateRepresentation,
freemarker.template.Configuration config,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(Representation templateRepresentation,
freemarker.template.Configuration config,
Object dataModel,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(Representation templateRepresentation,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(Representation templateRepresentation,
Object dataModel,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(String templateName,
freemarker.template.Configuration config,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(String templateName,
freemarker.template.Configuration config,
Object dataModel,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(freemarker.template.Template template,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(freemarker.template.Template template,
Object dataModel,
MediaType mediaType)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
<T> void |
GsonConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity) |
Modifier and Type | Method and Description |
---|---|
MediaType |
FormData.getMediaType()
Returns the media type of the value representation.
|
Modifier and Type | Method and Description |
---|---|
<T> void |
HtmlConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity) |
Modifier and Type | Method and Description |
---|---|
static boolean |
FormUtils.isEntryFound(FormData searchedEntry,
MediaType mediaRange)
Indicates if the searched entry is specified in the given media range.
|
Modifier and Type | Method and Description |
---|---|
protected <T> JacksonRepresentation<T> |
JacksonConverter.create(MediaType mediaType,
T source)
Creates the marshaling
JacksonRepresentation . |
Modifier and Type | Method and Description |
---|---|
<T> void |
JacksonConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity) |
Constructor and Description |
---|
JacksonRepresentation(MediaType mediaType,
T object)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
protected boolean |
JaxbConverter.isCompatible(MediaType mediaType)
Indicates if the given mediaType is compatible with the media types
supported by this converter.
|
Modifier and Type | Method and Description |
---|---|
<T> void |
JaxbConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity) |
Constructor and Description |
---|
JaxbRepresentation(MediaType mediaType,
T object)
Creates a JAXB representation from an existing JAXB content tree.
|
JaxbRepresentation(MediaType mediaType,
T object,
ClassLoader classloader)
Creates a JAXB representation from an existing JAXB content tree.
|
Modifier and Type | Method and Description |
---|---|
protected boolean |
JibxConverter.isCompatible(MediaType mediaType)
Deprecated.
Indicates if the given mediaType is compatible with the media types
supported by this converter.
|
Modifier and Type | Method and Description |
---|---|
<T> void |
JibxConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity)
Deprecated.
|
Constructor and Description |
---|
JibxRepresentation(MediaType mediaType,
T object)
Deprecated.
Creates a JIBX representation from an existing Java object.
|
JibxRepresentation(MediaType mediaType,
T object,
String bindingName)
Deprecated.
Creates a JIBX representation from an existing Java object.
|
Modifier and Type | Method and Description |
---|---|
Representation |
Service.getValue(Object entity,
MediaType mediaType)
Returns the binary representation of the given media resource.
|
Modifier and Type | Method and Description |
---|---|
Representation |
Service.getValue(Object entity,
List<Preference<MediaType>> acceptedMediaTypes)
Returns the binary representation of the given media resource.
|
Modifier and Type | Method and Description |
---|---|
MediaType |
Property.getMediaType()
Returns the media type stored in the content.
|
Modifier and Type | Method and Description |
---|---|
void |
Property.setMediaType(MediaType mediaType)
Sets the media type stored in the content.
|
Modifier and Type | Method and Description |
---|---|
GraphHandler |
RdfRepresentation.createWriter(MediaType mediaType,
Writer writer)
Returns an instance of a graph handler used when writing the inner set of
links.
|
Modifier and Type | Method and Description |
---|---|
<T> void |
RdfConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity) |
Constructor and Description |
---|
RdfRepresentation(Graph linkSet,
MediaType mediaType)
Constructor with argument.
|
RdfRepresentation(MediaType mediaType)
Constructor with argument.
|
Modifier and Type | Method and Description |
---|---|
Representation |
ServletWarEntity.getRepresentation(MediaType defaultMediaType,
int timeToLive) |
Modifier and Type | Method and Description |
---|---|
<T> void |
ThymeleafConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity) |
Constructor and Description |
---|
TemplateRepresentation(String templateName,
Locale locale,
Map<String,Object> dataModel,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(String templateName,
Locale locale,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(String templateName,
org.thymeleaf.TemplateEngine engine,
Locale locale,
Map<String,Object> dataModel,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(String templateName,
org.thymeleaf.TemplateEngine engine,
Locale locale,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(TemplateRepresentation templateRepresentation,
Locale locale,
MediaType mediaType)
Constructor based on a Thymeleaf 'encoded' representation.
|
TemplateRepresentation(TemplateRepresentation templateRepresentation,
org.thymeleaf.TemplateEngine engine,
Locale locale,
MediaType mediaType)
Constructor based on a Thymeleaf 'encoded' representation.
|
Modifier and Type | Method and Description |
---|---|
<T> void |
VelocityConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity) |
Constructor and Description |
---|
TemplateRepresentation(Representation templateRepresentation,
Map<String,Object> dataModel,
MediaType mediaType)
Constructor based on a Velocity 'encoded' representation.
|
TemplateRepresentation(Representation templateRepresentation,
MediaType mediaType)
Constructor based on a Velocity 'encoded' representation.
|
TemplateRepresentation(String templateName,
Map<String,Object> dataModel,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(String templateName,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(org.apache.velocity.Template template,
Map<String,Object> dataModel,
MediaType mediaType)
Constructor.
|
TemplateRepresentation(org.apache.velocity.Template template,
MediaType mediaType)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
MediaType |
RepresentationInfo.getMediaType()
Returns the media type of that element.
|
MediaType |
ResourceInfo.getQueryType()
Returns the media type for the query component of the resource URI.
|
Modifier and Type | Method and Description |
---|---|
void |
RepresentationInfo.setMediaType(MediaType mediaType)
Sets the media type of that element.
|
void |
ResourceInfo.setQueryType(MediaType queryType)
Sets the media type for the query component of the resource URI.
|
Modifier and Type | Method and Description |
---|---|
<T> void |
WadlConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity) |
Constructor and Description |
---|
RepresentationInfo(MediaType mediaType)
Constructor with a media type.
|
Modifier and Type | Method and Description |
---|---|
MediaType |
Transformer.getResultMediaType()
Returns the media type of the result representation.
|
Modifier and Type | Method and Description |
---|---|
void |
Transformer.setResultMediaType(MediaType resultMediaType)
Sets the media type of the result representation.
|
Modifier and Type | Method and Description |
---|---|
<T> void |
XmlConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity) |
Constructor and Description |
---|
DomRepresentation(MediaType mediaType)
Constructor for an empty document.
|
DomRepresentation(MediaType mediaType,
Document xmlDocument)
Constructor from an existing DOM document.
|
SaxRepresentation(MediaType mediaType)
Constructor.
|
SaxRepresentation(MediaType mediaType,
Document xmlDocument)
Constructor.
|
SaxRepresentation(MediaType mediaType,
InputSource xmlSource)
Constructor.
|
SaxRepresentation(MediaType mediaType,
SAXSource xmlSource)
Constructor.
|
XmlRepresentation(MediaType mediaType)
Constructor.
|
XmlRepresentation(MediaType mediaType,
long expectedSize)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
protected <T> XstreamRepresentation<T> |
XstreamConverter.create(MediaType mediaType,
T source)
Deprecated.
Creates the marshaling
XstreamRepresentation . |
protected com.thoughtworks.xstream.XStream |
XstreamRepresentation.createXstream(MediaType mediaType)
Deprecated.
Creates an XStream object based on a media type.
|
<T> com.thoughtworks.xstream.XStream |
XstreamConverter.createXstream(MediaType mediaType,
Class<T> target)
Deprecated.
Creates an XStream object based on a media type.
|
Modifier and Type | Method and Description |
---|---|
<T> void |
XstreamConverter.updatePreferences(List<Preference<MediaType>> preferences,
Class<T> entity)
Deprecated.
|
Constructor and Description |
---|
XstreamRepresentation(MediaType mediaType,
T object)
Deprecated.
Constructor.
|
Modifier and Type | Method and Description |
---|---|
MediaType |
Variant.getMediaType()
Returns the media type.
Note that when used with HTTP connectors, this property maps to the "Content-Type" header. |
Modifier and Type | Method and Description |
---|---|
void |
Variant.setMediaType(MediaType mediaType)
Sets the media type.
Note that when used with HTTP connectors, this property maps to the "Content-Type" header. |
Constructor and Description |
---|
AppendableRepresentation(CharSequence text,
MediaType mediaType)
Constructor.
|
AppendableRepresentation(CharSequence text,
MediaType mediaType,
Language language)
Constructor.
|
AppendableRepresentation(CharSequence text,
MediaType mediaType,
Language language,
CharacterSet characterSet)
Constructor.
|
ByteArrayRepresentation(byte[] byteArray,
int offSet,
int length,
MediaType mediaType) |
ByteArrayRepresentation(byte[] byteArray,
int offSet,
int length,
MediaType mediaType,
long expectedSize) |
ByteArrayRepresentation(byte[] byteArray,
MediaType mediaType)
Constructor.
|
ByteArrayRepresentation(byte[] byteArray,
MediaType mediaType,
long expectedSize) |
ChannelRepresentation(MediaType mediaType)
Constructor.
|
CharacterRepresentation(MediaType mediaType)
Constructor.
|
FileRepresentation(File file,
MediaType mediaType)
Constructor that does not set an expiration date for
file |
FileRepresentation(File file,
MediaType mediaType,
int timeToLive)
Constructor.
|
FileRepresentation(String path,
MediaType mediaType)
Constructor that does not set an expiration date for
path |
FileRepresentation(String path,
MediaType mediaType,
int timeToLive)
Constructor.
|
InputRepresentation(InputStream inputStream,
MediaType mediaType)
Constructor.
|
InputRepresentation(InputStream inputStream,
MediaType mediaType,
long expectedSize)
Constructor.
|
ObjectRepresentation(T object,
MediaType mediaType)
Constructor for either the
APPLICATION_JAVA_OBJECT type
or the APPLICATION_XML type. |
OutputRepresentation(MediaType mediaType)
Constructor.
|
OutputRepresentation(MediaType mediaType,
long expectedSize)
Constructor.
|
ReadableRepresentation(ReadableByteChannel readableChannel,
MediaType mediaType)
Constructor.
|
ReadableRepresentation(ReadableByteChannel channel,
MediaType mediaType,
long expectedSize)
Constructor.
|
ReaderRepresentation(Reader reader,
MediaType mediaType)
Constructor.
|
ReaderRepresentation(Reader reader,
MediaType mediaType,
long expectedSize)
Constructor.
|
Representation(MediaType mediaType)
Constructor.
|
Representation(MediaType mediaType,
Date modificationDate)
Constructor.
|
Representation(MediaType mediaType,
Date modificationDate,
Tag tag)
Constructor.
|
Representation(MediaType mediaType,
Tag tag)
Constructor.
|
RepresentationInfo(MediaType mediaType)
Constructor.
|
RepresentationInfo(MediaType mediaType,
Date modificationDate)
Constructor.
|
RepresentationInfo(MediaType mediaType,
Date modificationDate,
Tag tag)
Constructor.
|
RepresentationInfo(MediaType mediaType,
Tag tag)
Constructor.
|
StreamRepresentation(MediaType mediaType)
Constructor.
|
StringRepresentation(CharSequence text,
MediaType mediaType)
Constructor.
|
StringRepresentation(CharSequence text,
MediaType mediaType,
Language language)
Constructor.
|
StringRepresentation(CharSequence text,
MediaType mediaType,
Language language,
CharacterSet characterSet)
Constructor.
|
Variant(MediaType mediaType)
Constructor.
|
Variant(MediaType mediaType,
Language language)
Constructor.
|
WritableRepresentation(MediaType mediaType)
Constructor.
|
WriterRepresentation(MediaType mediaType)
Constructor.
|
WriterRepresentation(MediaType mediaType,
long expectedSize)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
Representation |
ClientResource.delete(MediaType mediaType)
Deletes the target resource and all its representations.
|
Representation |
ClientResource.get(MediaType mediaType)
Represents the resource using a given media type.
|
protected Representation |
ClientResource.handle(Method method,
MediaType mediaType)
Handles the call by cloning the prototype request, setting the method and
entity.
|
protected Representation |
ClientResource.handle(Method method,
Representation entity,
MediaType mediaType)
Handles the call by cloning the prototype request, setting the method and
entity.
|
Representation |
ClientResource.head(MediaType mediaType)
Represents the resource using a given media type.
|
Representation |
ClientResource.options(MediaType mediaType)
Describes the resource using a given media type.
|
Representation |
ClientResource.patch(Object entity,
MediaType mediaType)
Patches a resource with the given object as delta state.
|
Representation |
ClientResource.post(Object entity,
MediaType mediaType)
Posts an object entity.
|
Representation |
ClientResource.put(Object entity,
MediaType mediaType)
Puts an object entity.
|
Representation |
Resource.toRepresentation(Object source,
MediaType target)
Converts an object into a representation based on a given media type.
|
Modifier and Type | Method and Description |
---|---|
MediaType |
MetadataService.getDefaultMediaType()
Returns the default media type for representations.
|
MediaType |
MetadataService.getMediaType(String extension)
Returns the mediatype associated to this extension.
|
Modifier and Type | Method and Description |
---|---|
List<MediaType> |
EncoderService.getAcceptedMediaTypes()
Returns the media types that should be encoded.
|
List<MediaType> |
MetadataService.getAllMediaTypes(String extension)
Returns all the media types associated to this extension.
|
static List<MediaType> |
EncoderService.getDefaultAcceptedMediaTypes()
Returns the list of default encoded media types.
|
static List<MediaType> |
EncoderService.getDefaultIgnoredMediaTypes()
Returns the list of default ignored media types.
|
List<MediaType> |
EncoderService.getIgnoredMediaTypes()
Returns the media types that should be ignored.
|
List<MediaType> |
ConverterService.getPatchTypes(MediaType representationType)
Returns the list of patch media types available for the given
representation types.
|
Modifier and Type | Method and Description |
---|---|
List<MediaType> |
ConverterService.getPatchTypes(MediaType representationType)
Returns the list of patch media types available for the given
representation types.
|
void |
MetadataService.setDefaultMediaType(MediaType defaultMediaType)
Sets the default media type for local representations.
|
Representation |
ConverterService.toRepresentation(Object source,
MediaType target)
Converts a regular Java object into a Representation.
|
Modifier and Type | Method and Description |
---|---|
void |
ConverterService.updatePreferences(List<Preference<MediaType>> preferences,
Class<?> entity)
Updates the media type preferences with available conversion capabilities
for the given entity class.
|
Modifier and Type | Method and Description |
---|---|
MediaType |
WrapperRepresentation.getMediaType() |
Modifier and Type | Method and Description |
---|---|
void |
WrapperResponse.setEntity(String value,
MediaType mediaType)
Sets a textual entity.
|
void |
WrapperRequest.setEntity(String value,
MediaType mediaType)
Sets a textual entity.
|
void |
WrapperRepresentation.setMediaType(MediaType mediaType) |
Copyright © 2005–2016. All rights reserved.