/// <summary>
        /// Initializes a new instance of the <see cref="MaintainableAnnotationRetrieverEngine"/> class.
        /// </summary>
        /// <param name="mappingStoreDb">The mapping store database.</param>
        /// <param name="tableInfo">The table information.</param>
        /// <exception cref="System.ArgumentNullException"><paramref name="tableInfo"/> is null -or- <paramref name="mappingStoreDb"/> is null.</exception>
        public MaintainableAnnotationRetrieverEngine(Database mappingStoreDb, TableInfo tableInfo)
        {
            if (mappingStoreDb == null)
            {
                throw new ArgumentNullException("mappingStoreDb");
            }

            if (tableInfo == null)
            {
                throw new ArgumentNullException("tableInfo");
            }

            this._mappingStoreDb = mappingStoreDb;

            ISqlQueryInfoBuilder<TableInfo> annotationQueryBuilder = new AnnotationQueryBuilder();
            this._annotationSqlQueryInfo = annotationQueryBuilder.Build(tableInfo);

            this._annotationCommandBuilder = new AnnotationCommandBuilder(this._mappingStoreDb);
        }
Exemple #2
0
        /// <summary>
        /// Initializes a new instance of the <see cref="MaintainableAnnotationRetrieverEngine"/> class.
        /// </summary>
        /// <param name="mappingStoreDb">The mapping store database.</param>
        /// <param name="tableInfo">The table information.</param>
        /// <exception cref="System.ArgumentNullException"><paramref name="tableInfo"/> is null -or- <paramref name="mappingStoreDb"/> is null.</exception>
        public MaintainableAnnotationRetrieverEngine(Database mappingStoreDb, TableInfo tableInfo)
        {
            if (mappingStoreDb == null)
            {
                throw new ArgumentNullException("mappingStoreDb");
            }

            if (tableInfo == null)
            {
                throw new ArgumentNullException("tableInfo");
            }

            this._mappingStoreDb = mappingStoreDb;

            ISqlQueryInfoBuilder <TableInfo> annotationQueryBuilder = new AnnotationQueryBuilder();

            this._annotationSqlQueryInfo = annotationQueryBuilder.Build(tableInfo);

            this._annotationCommandBuilder = new AnnotationCommandBuilder(this._mappingStoreDb);
        }