javax.ws.rs.client
Class Entity<T>
java.lang.Object
javax.ws.rs.client.Entity<T>
- Type Parameters:
T - entity type.
public class Entity<T>
- extends Object
Encapsulates message entity including the associated variant information.
- Author:
- Marek Potociar
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
entity
public static <T> Entity<T> entity(T entity,
MediaType mediaType)
entity
public static <T> Entity<T> entity(T entity,
String mediaType)
throws IllegalStateException
- Throws:
IllegalStateException
entity
public static <T> Entity<T> entity(T entity,
Variant variant)
throws IllegalStateException
- Throws:
IllegalStateException
text
public static <T> Entity<T> text(T entity)
xml
public static <T> Entity<T> xml(T entity)
json
public static <T> Entity<T> json(T entity)
html
public static <T> Entity<T> html(T entity)
xhtml
public static <T> Entity<T> xhtml(T entity)
form
public static Entity<Form> form(Form form)
form
public static Entity<Form> form(MultivaluedMap<String,String> formData)
getVariant
public Variant getVariant()
getMediaType
public MediaType getMediaType()
getEncoding
public String getEncoding()
getLanguage
public Locale getLanguage()
getEntity
public T getEntity()
Copyright © 2007-2012 Oracle Corporation. All Rights Reserved. Use is subject to license terms.