cancel
Showing results for 
Search instead for 
Did you mean: 

Declaring getter and setter method for context node attribute

Former Member
0 Kudos

Hi All,

Can anyone tell me how to create a getter and settere methods with parameter passing for context node attribute in methods tab.

Regards

Sireesha.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

hi,

by default u will have the 'typed access required'

property of the context attributes set to true which generates the getters n setters automatically..

explicitly if u want to create a method

switch to methods tab,

click on new

choose method radio button,

give the name get , choose the return type,

click on next,

there, click on new for giving the parameters,

choose the return type.

say finish and implement the logic in the get and set methods.

Regards,

Satya.

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

For every context node" type access required" property will be true by default,which means the setter and getter methods for all attributes will be generated automatically.U can also create user defined methods in view or in controller and pass args to the methods using methods tab.

Regards,

Srikanth Reddy.T

Former Member
0 Kudos

Thank you so much for both of you.

my context node calculated attribute is set to false. I have changed it to "True".

Getter and setter methods are automatically created.

Thanks one again.

Regards

Sireesha.

Former Member
0 Kudos

Hi,

If you want to have setter and getter methods for your attribute create them as calculated attributes.

Once this is done set the read only to false so that you get the getter. Is this what you are looking for?

Regards

Ayyapparaj