Пример #1
0
        public TownDatabase(LiteDatabase database)
        {
            Console.WriteLine("Running LiteDB!");
            this.database = database;

            Guilds = new LiteDBTableAccess <TownGuild>(database, "Guilds");
            Users  = new LiteDBTableAccess <TownUser>(database, "Users");
        }
Пример #2
0
        public TownDatabase(IAmazonDynamoDB dbContext, LiteDatabase database)
        {
            this.database = database;

            Guilds = new LiteDBTableAccess <TownGuild>(database, "Guilds");
            Users  = new LiteDBTableAccess <TownUser>(database, "Users");

            Console.WriteLine("Migrating to dynamo!");
            Migrate(dbContext);

            Guilds = new DynamoTableAccess <TownGuild>(dynamo);
            Users  = new DynamoTableAccess <TownUser>(dynamo);
        }