Menu

ForcedResourceType

The @via type ForcedResourceType in Sling MOdels creates a wrapped resource with the provided resource type. If the adaptable is a SlingHttpServletRequest, a wrapped request is created as well to contain the wrapped resource.

e.g. @Via(value = "jcr:content", type = ForcedResourceType.class)


References:

https://sling.apache.org/documentation/bundles/models.html#via-types

https://developer.adobe.com/experience-manager/reference-materials/6-5/javadoc/org/apache/sling/models/annotations/via/ForcedResourceType.html#ForcedResourceType--

No comments:

Post a Comment