/// <summary>
        /// Smart constructor that determines which data accessor class the manager will be calling from.
        /// </summary>
        /// <param name="dataStoreType">Data storage medium.</param>
        public RealThreadManager(AppData.DataStoreType dataStoreType)
        {
            switch (dataStoreType)
            {
            case AppData.DataStoreType.mock:
                dao = new ThreadAccessorMock();
                break;

            case AppData.DataStoreType.msssql:
                dao = new ThreadAccessorMSSQL();
                break;
            }
            daoType = dataStoreType;
        }
示例#2
0
        public ResortVehicleCheckoutManager(IResortVehicleCheckoutAccessor resortVehicleCheckoutAccessor = null
                                            , IResortVehicleAccessor resortVehicleAccessor = null)
        {
            daotype = AppData.DataStoreType.msssql;

            switch (daotype)
            {
            case AppData.DataStoreType.mock:
                throw new NotImplementedException();
                break;

            case AppData.DataStoreType.msssql:
            default:
                _resortVehicleCheckoutAccessor = new ResortVehicleCheckoutAccessor();
                _resortVehicleAccessor         = new ResortVehicleAccessor();
                break;
            }
        }