The get function is invoked when you want to read it:
object.someproperty;
The set function is invoked when you set it:
object.someproperty = "semi";
"semi" is the val parameter.
Also, search in the Flex documentation for "getter setter".
--- In flexcoders@yahoogroups.com, "shemeshkale" <[EMAI
tnx, this works great.
but i m still confused with this set/get.
where can i read about it? questions like:
- who and when invoke each one?
- which happens first?
- the return on the 'get' is returning where?
.
.
.
--- In flexcoders@yahoogroups.com, "gotgoose09" <[EMAIL PROTECTED]> wrote:
>
> Rena
Rename checkState to _checkState.
private var _checkState:String;
public function get checkState():String
{
return _checkState;
}
public function set checkState(val:String):void
{
// make sure val is a valid value
if (val == "true" || val == "semi" || val == "false")
{
_che
3 matches
Mail list logo