Exemplo n.º 1
0
        protected DocumentStoreClient(DocumentDbAccess dbAccess, DocumentStoreConfig config, IEnumerable <Type> storedProcedures)
        {
            if (dbAccess == null)
            {
                throw new ArgumentNullException(nameof(dbAccess));
            }
            if (config == null)
            {
                throw new ArgumentNullException(nameof(config));
            }

            _dbAccess = dbAccess;
            _config   = config;

            _collectionUri = UriFactory.CreateDocumentCollectionUri(dbAccess.DbConfig.DatabaseId, dbAccess.DbConfig.CollectionName);

            if (storedProcedures != null)
            {
                _storedProcedures = storedProcedures.ToDictionary(x => x, GetStoredProcedureName);
            }
        }
Exemplo n.º 2
0
 protected DocumentQueryClient(
     DocumentDbAccess dbAccess,
     DocumentStoreConfig config,
     IEnumerable <Type> storedProcedures) : base(dbAccess, config, storedProcedures)
 {
 }