what is the difference between @ChildResourceFromRequest and @ChildResource with examples?
Hi, may I know,
what is the difference between @ChildResourceFromRequest and @ChildResource with examples
Thank you
Hi, may I know,
what is the difference between @ChildResourceFromRequest and @ChildResource with examples
Thank you
Hi @rahul234dabas ,
let me give you a basic understanding of your doubt.
When we try to inject a resource as @ChildResource, it loses the context of SlingHttpServletRequest. Hence we use @ChildResourceFromRequest instead @ChildResource. The @ChildResourceFromRequest is found in the ACS AEM Commons package. In @ChildResourceFromRequest, it uses a mock request object pointed to the resource path as the adaptable, Which allows the sling model to reference the request. But it fails to inject via the standard @ChildResource injector.
Thanks
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.