[flexcoders] What is the underscore '_'

2008-07-16 Thread Scott
... being used for in flex code? I see example code out there that has variables like _myVar = myVar, what is this doing? TIA!

Re: [flexcoders] What is the underscore '_'

2008-07-16 Thread Dan Vega
Its just standard practice to use an underscore for private variables. Dan On Wed, Jul 16, 2008 at 10:38 AM, Scott [EMAIL PROTECTED] wrote: … being used for in flex code? I see example code out there that has variables like _myVar = myVar, what is this doing? TIA!

Re: [flexcoders] What is the underscore '_'

2008-07-16 Thread Paul Andrews
Sent: Wednesday, July 16, 2008 3:38 PM Subject: [flexcoders] What is the underscore '_' . being used for in flex code? I see example code out there that has variables like _myVar = myVar, what is this doing? TIA!

Re: [flexcoders] What is the underscore '_'

2008-07-16 Thread Leonardo Moreno
Hi The '_' preceding a variable is used as a best practice in private fields because the getters and setters can't have the same name as the variable. private var _name:String; public function set name(name:String):void{this._name = name;} public function get name():String{return