コード例 #1
0
        public static IOntologyReader GetKeywordsList(CatalogSettings catalogSettings)
        {
            if (catalogSettings == null)
            {
                throw new ArgumentNullException("catalogSettings");
            }

            IOntologyReader reader;

            switch (catalogSettings.TypeOfCatalog)
            {
            case TypeOfCatalog.LocalMetadataCache:
                reader = new DbKeywordsList();
                break;

            case TypeOfCatalog.HisCentral:
                reader = new HisCentralKeywordsList();
                break;

            default:
                throw new Exception("Unknown TypeOfCatalog");
            }

            return(reader);
        }
コード例 #2
0
        public static IOntologyReader GetKeywordsList(CatalogSettings catalogSettings)
        {
            if (catalogSettings == null) throw new ArgumentNullException("catalogSettings");

            IOntologyReader reader;
            switch (catalogSettings.TypeOfCatalog)
            {
                case TypeOfCatalog.LocalMetadataCache:
                    reader = new DbKeywordsList();
                    break;
                case TypeOfCatalog.HisCentral:
                    reader = new HisCentralKeywordsList();
                    break;
                default:
                    throw new Exception("Unknown TypeOfCatalog");
            }

            return reader;
        }