Beispiel #1
0
        public RightRepository(StorageTypeSetting.StorageTypes storageType)
        {
            switch (storageType)
            {
            case StorageTypeSetting.StorageTypes.SQL:
                _context = new RightContextSQL();
                break;

            case StorageTypeSetting.StorageTypes.Memory:
                _context = new RightContextMemory();
                break;

            default:
                throw new ArgumentOutOfRangeException(nameof(storageType), storageType, "Set Storage Type");
            }
        }
Beispiel #2
0
 public RightRepository(IRightContext context)
 {
     this._Context = context;
 }