Well, actually there is a difference.
In AS3, class constructors can not be Private. In AS2 they can.
So in AS2 you can do this:
class MySingleton {
private function MySingleton() {
}
public static function getInstance() {
// bah blah..
}
}
Which is not allowed in AS3.
regards,
Muzak
----- Original Message -----
From: "Frédéric v. Bochmann" <[EMAIL PROTECTED]>
To: "'Flashcoders mailing list'" <[email protected]>
Sent: Saturday, October 29, 2005 6:32 PM
Subject: RE: [Flashcoders] Newbie AS3 question
> (*Just looking back at the title of this Thread*)
>
> Just in case someone's wonders; creating a Singleton is nothing new in
> ActionScript, it can be done in AS1, AS2 or AS3.
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders