@Service @Named(value="isisRoRendering.ContentNegotiationServiceOrgApacheIsisV1") @Order(value=-200) @Qualifier(value="OrgApacheIsisV1") public class ContentNegotiationServiceOrgApacheIsisV1 extends ContentNegotiationServiceAbstract
| Modifier and Type | Field and Description |
|---|---|
static String |
ACCEPT_PROFILE
Unlike RO v1.0, use a single content-type of
application/json;profile="urn:org.apache.isis/v1". |
static String |
CONTENT_TYPE_OAI_V1_LIST
The media type (as a string) used as the content-Type header when a standalone collection is rendered.
|
static String |
CONTENT_TYPE_OAI_V1_OBJECT
The media type (as a string) used as the content-Type header when a domain object is rendered.
|
static String |
CONTENT_TYPE_OAI_V1_OBJECT_COLLECTION
The media type (as a string) used as the content-Type header when a parented collection is rendered.
|
| Constructor and Description |
|---|
ContentNegotiationServiceOrgApacheIsisV1(ContentNegotiationServiceForRestfulObjectsV1_0 restfulObjectsV1_0) |
| Modifier and Type | Method and Description |
|---|---|
javax.ws.rs.core.Response.ResponseBuilder |
buildResponse(IResourceContext resourceContext,
org.apache.isis.core.metamodel.interactions.managed.ManagedAction objectAndAction)
Action prompt is not supported.
|
javax.ws.rs.core.Response.ResponseBuilder |
buildResponse(IResourceContext resourceContext,
org.apache.isis.core.metamodel.interactions.managed.ManagedCollection managedCollection)
Individual (parented) collection of an object is returned as a list with the RO representation
as an object in the list with a single property named '$$ro'
|
javax.ws.rs.core.Response.ResponseBuilder |
buildResponse(IResourceContext resourceContext,
org.apache.isis.core.metamodel.spec.ManagedObject objectAdapter)
Domain object is returned as a map with the RO 1.0 representation as a special '$$ro' property
within that map.
|
javax.ws.rs.core.Response.ResponseBuilder |
buildResponse(IResourceContext resourceContext,
org.apache.isis.core.metamodel.interactions.managed.ManagedProperty objectAndProperty)
Individual property of an object is not supported.
|
javax.ws.rs.core.Response.ResponseBuilder |
buildResponse(IResourceContext resourceContext,
ObjectAndActionInvocation objectAndActionInvocation)
Action invocation is supported provided it returns a single domain object or a list of domain objects
(ie invocations returning void or scalar value are not supported).
|
protected javax.ws.rs.core.Response.ResponseBuilder |
responseBuilder(javax.ws.rs.core.Response.ResponseBuilder responseBuilder)
For easy subclassing to further customize, eg additional headers
|
protected EnumSet<org.apache.isis.applib.client.SuppressionType> |
suppress(IResourceContext resourceContext) |
ensureDomainObjectAssignable, ensureJaxbAnnotated, loadClass, mediaTypeParameterList, mediaTypeParameterMatches, objectOf, returnedObjectOfpublic static final String ACCEPT_PROFILE
application/json;profile="urn:org.apache.isis/v1".
The response content types (CONTENT_TYPE_OAI_V1_OBJECT, CONTENT_TYPE_OAI_V1_OBJECT_COLLECTION,
CONTENT_TYPE_OAI_V1_LIST) append the 'repr-type' parameter.
public static final String CONTENT_TYPE_OAI_V1_OBJECT
for discussion.,
Constant Field Valuespublic static final String CONTENT_TYPE_OAI_V1_OBJECT_COLLECTION
for discussion.,
Constant Field Valuespublic static final String CONTENT_TYPE_OAI_V1_LIST
for discussion.,
Constant Field Valuespublic ContentNegotiationServiceOrgApacheIsisV1(ContentNegotiationServiceForRestfulObjectsV1_0 restfulObjectsV1_0)
public javax.ws.rs.core.Response.ResponseBuilder buildResponse(IResourceContext resourceContext, org.apache.isis.core.metamodel.spec.ManagedObject objectAdapter)
buildResponse in interface ContentNegotiationServicebuildResponse in class ContentNegotiationServiceAbstractpublic javax.ws.rs.core.Response.ResponseBuilder buildResponse(IResourceContext resourceContext, org.apache.isis.core.metamodel.interactions.managed.ManagedProperty objectAndProperty)
buildResponse in interface ContentNegotiationServicebuildResponse in class ContentNegotiationServiceAbstractpublic javax.ws.rs.core.Response.ResponseBuilder buildResponse(IResourceContext resourceContext, org.apache.isis.core.metamodel.interactions.managed.ManagedCollection managedCollection)
buildResponse in interface ContentNegotiationServicebuildResponse in class ContentNegotiationServiceAbstractpublic javax.ws.rs.core.Response.ResponseBuilder buildResponse(IResourceContext resourceContext, org.apache.isis.core.metamodel.interactions.managed.ManagedAction objectAndAction)
buildResponse in interface ContentNegotiationServicebuildResponse in class ContentNegotiationServiceAbstractpublic javax.ws.rs.core.Response.ResponseBuilder buildResponse(IResourceContext resourceContext, ObjectAndActionInvocation objectAndActionInvocation)
#buildResponse(RepresentationService.Context2, ManagedObject)), while
action invocations returning a list will be rendered as a list with the RO v1.0 representation as a map object
with a single '$$ro' property (similar to #buildResponse(RepresentationService.Context2, ObjectAndCollection))buildResponse in interface ContentNegotiationServicebuildResponse in class ContentNegotiationServiceAbstractprotected javax.ws.rs.core.Response.ResponseBuilder responseBuilder(javax.ws.rs.core.Response.ResponseBuilder responseBuilder)
protected EnumSet<org.apache.isis.applib.client.SuppressionType> suppress(IResourceContext resourceContext)
Copyright © 2010–2020 The Apache Software Foundation. All rights reserved.