I want to know about the setter and getter. I know that it is a properties of declaring variable but some time I get confused. Presently I am using a sample of code that is below:
public with sharing class hello
{
public String temp{set;get;}
public hello(){
temp = 'first' ;
}
public String gettemp(){
return 'second' ;
}
}
So I want to know that when I use temp on VFP than what value will show on page, what is reason for that, and what is the difference between temp
and gettemp
?
Thanks Ashlekh Gera