Revision: 7623
Initial Code
Initial URL
Initial Description
Initial Title
Initial Tags
Initial Language
at August 1, 2008 11:30 by t3flexdev
Initial Code
package ###PACKAGE### { import com.adobe.cairngorm.model.ModelLocator; import mx.logging.ILogger; [Bindable] public class ###CLASSFILENAME### implements ModelLocator { private static var model : AppModelLocator; public function AppLocator() : void { if ( AppModelLocator.model != null ) throw new Error( "Only one ModelLocator instance should be instantiated" ); } // singleton: always returns the one existing static instance to itself public static function getInstance() : AppModelLocator { if ( model == null ) model = new AppModelLocator(); return model; } } }
Initial URL
Initial Description
###PACKAGE### replace -> com.yourdomain.model ###CLASSFILENAME### replace -> AppModelLocator
Initial Title
AppModelLocator MODEL
Initial Tags
Initial Language
ActionScript 3