Package jsky.catalog

Examples of jsky.catalog.Catalog


            _backAction.setEnabled(false);
        }

        // select the related tree node
        if (historyItem.getQueryComponent() != null) {
            Catalog cat = _panelTreeNodeTable.get(historyItem.getQueryComponent());
            if (cat != null) {
                _catalogTree.setSelectedCatalog(cat, true);
            }
        }
View Full Code Here


            _forwAction.setEnabled(false);
        }

        // select the related tree node
        if (historyItem.getQueryComponent() != null) {
            Catalog cat = _panelTreeNodeTable.get(historyItem.getQueryComponent());
            if (cat != null) {
                _catalogTree.setSelectedCatalog(cat, true);
            }
        }
View Full Code Here

    /**
     * Open a catalog window for the named catalog, if found.
     */
    public void openCatalogWindow(String name) {
        CatalogDirectory dir = CatalogNavigator.getCatalogDirectory(false);
        Catalog cat = dir.findCatalog(name);
        if (cat != null) {
            openCatalogWindow(cat);
        }
    }
View Full Code Here

     * @return an array of TablePlotSymbol objects, one for each plot symbol defined.
     */
    public TablePlotSymbol[] getPlotSymbolInfo(TableQueryResult table) {
        // first see if we have the plot information cached
        Object o = _plotSymbolMap.get(table);
        Catalog catalog = table.getCatalog();
        if (o == null) {
            // also check the catalog where the query originated
            if (catalog != null) {
                o = _plotSymbolMap.get(catalog);
            }
View Full Code Here

    /**
     * Set the plot symbol info for the given table
     */
    public void setPlotSymbolInfo(TableQueryResult table, TablePlotSymbol[] symbols) {
        Catalog catalog = table.getCatalog();
        _plotSymbolMap.put(table, symbols);
        if (catalog != null) {
            _plotSymbolMap.put(catalog, symbols);
        }
    }
View Full Code Here

    cat.setHost("nvo.stsci.edu");
    cat.setURLPath("/vor10/ristandardservice.asmx");
    CatalogDirectory dir = VoCatalogDirectory.getDirectory(cat);
    int n = dir.getNumCatalogs();
    for(int i = 0; i < n; i++) {
      Catalog catalog = dir.getCatalog(i);
      System.out.println(i + ": " + catalog.getName() + " - " + catalog.getTitle());
    }
  }
View Full Code Here

     * @return the name to use/display for the FITS table
     */
    protected static String getTableName(String filename, TableQueryResult table) {
        String name = table.getId();
        if (!name.endsWith(TABLE_SUFFIX)) {
            Catalog cat = table.getCatalog();
            if (cat != null) {
                name = cat.getName();
            }
            if (name == null) {
                name = new File(filename).getName();
            }
            // There are size limits on the name
View Full Code Here

        if (value instanceof DefaultMutableTreeNode) {
            DefaultMutableTreeNode node = (DefaultMutableTreeNode) value;
            Object o = node.getUserObject();
            if (o instanceof Catalog) {
                Catalog catalog = (Catalog) o;
                setToolTipText(catalog.getDescription());
                String servType = catalog.getType();
                if (servType.equals("directory")) {
                    setIcon(getOpenIcon());
                }
                if (servType.equals("catalog")) {
                    setIcon(CATALOG_ICON);
View Full Code Here

            return menu;
        }
        int n = dir.getNumCatalogs();
        menu.setEnabled(n != 0);
        for (int i = 0; i < n; i++) {
            Catalog cat = dir.getCatalog(i);
            if (cat.getType().equals(servType)) {
                JMenuItem menuItem = _createCatalogMenuItem(cat);
                if (icon != null) {
                    menuItem.setIcon(icon);
                }
                menu.add(menuItem);
View Full Code Here

            CatalogDirectory rootDir = null, catDir = cat.getParent();
            if (catDir != null) {
                rootDir = (CatalogDirectory) catDir.getRoot();
            }
            if (rootDir != null) {
                Catalog existingCat = rootDir.getCatalog(cat.getName());
                if (existingCat != null && existingCat != cat) {
                    rootDir.removeCatalog(existingCat);
                }
                rootDir.addCatalog(1, cat);
                rootDir.save();
View Full Code Here

TOP

Related Classes of jsky.catalog.Catalog

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.