package model
{
	import com.adobe.cairngorm.model.IModelLocator;
	import com.adobe.cairngorm.CairngormMessageCodes;
	import com.adobe.cairngorm.CairngormError;
	
	import mx.collections.ArrayCollection;
	
	[Bindable]
	public class EmployeesModelLocator implements IModelLocator
	{
		public var employeesList:ArrayCollection;
		
		private static var _instance:EmployeesModelLocator;
		
		public function EmployeesModelLocator() {
			if (_instance != null ) {
				throw new CairngormError(CairngormMessageCodes.SINGLETON_EXCEPTION,
					"EmployeesModelLocator");
			}
			
			_instance = this;
		}
		
		public static function getInstance():EmployeesModelLocator {
			if (_instance == null) {
				_instance = new EmployeesModelLocator();
			}
			
			return _instance;
		}
	}
}