コード例 #1
0
        public bool VerifyCurrentCatalogue()
        {
            if (Catalog == StarCatalog.UCAC2)
            {
                if (!UCAC2Catalogue.IsValidCatalogLocation(ref CatalogLocation))
                {
                    return(false);
                }

                if (!UCAC2Catalogue.CheckAndWarnIfNoBSS(CatalogLocation, null))
                {
                    return(false);
                }
            }
            else if (Catalog == StarCatalog.NOMAD)
            {
                if (!NOMADCatalogue.IsValidCatalogLocation(ref CatalogLocation))
                {
                    return(false);
                }

                // TODO: Check index files??
            }
            else if (Catalog == StarCatalog.UCAC3)
            {
                if (!UCAC3Catalogue.IsValidCatalogLocation(ref CatalogLocation))
                {
                    return(false);
                }
            }

            return(true);
        }
コード例 #2
0
        public static bool VerifyCurrentCatalogue(TangraConfig.StarCatalog catalog, ref string path)
        {
            if (catalog == TangraConfig.StarCatalog.UCAC2)
            {
                if (!UCAC2Catalogue.IsValidCatalogLocation(ref path))
                {
                    return(false);
                }

                if (!UCAC2Catalogue.CheckAndWarnIfNoBSS(path, null))
                {
                    return(false);
                }
            }
            else if (catalog == TangraConfig.StarCatalog.NOMAD)
            {
                if (!NOMADCatalogue.IsValidCatalogLocation(ref path))
                {
                    return(false);
                }

                // TODO: Check index files??
            }
            else if (catalog == TangraConfig.StarCatalog.UCAC3)
            {
                if (!UCAC3Catalogue.IsValidCatalogLocation(ref path))
                {
                    return(false);
                }
            }
            else if (catalog == TangraConfig.StarCatalog.PPMXL)
            {
                if (!PPMXLCatalogue.IsValidCatalogLocation(ref path))
                {
                    return(false);
                }
            }
            else if (catalog == TangraConfig.StarCatalog.UCAC4)
            {
                if (!UCAC4Catalogue.IsValidCatalogLocation(ref path))
                {
                    return(false);
                }
            }

            return(true);
        }