Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

page manager api uses

Avatar

Level 1

hi all,

I have a component in 6.4 aem and i authored the value for that componet through dilog .now the component node has saved with dilogs fields inside conf template folder.now i need to access that component node and properties in my code or java code to map that node properties with some static data.how can i access that node to map that node properties woth spme data and where i need to do this in java code or somewhere else

please help me out

1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi,

You can use either JCR Node API.

Node (Content Repository for Java Technology API Version 2.0)

or

If you are trying to achieving context aware config, then you can access properties using caconfig object.

Apache Sling :: Apache Sling Context-Aware Configuration

View solution in original post

5 Replies

Avatar

Correct answer by
Community Advisor

Hi,

You can use either JCR Node API.

Node (Content Repository for Java Technology API Version 2.0)

or

If you are trying to achieving context aware config, then you can access properties using caconfig object.

Apache Sling :: Apache Sling Context-Aware Configuration

Avatar

Level 2

Hi Arun, can you suggest which is best for the above use case I have only one node and properties. Now how I can access this node .do I need to write java imp class or any article if there is

Avatar

Community Advisor

Hi,

If this is a fixed node and property, you can access using Node API.

Avatar

Level 2

Dear Arun, I am saving this node properties from dilog box and values getting updated in conf template folder where node get created.every time values getting changed but not property names.so do I need to create interface and implement class where I can use sling or node api .one another way also there using sling api..get resouse .plz suggest

Avatar

Level 10

You can use the JCR API to reference a node and modify any of its props. Are you familiar with using the JCR API? Do you know how to get a session by using a System user and the Sling Mapping Service?