Package jsky.catalog.vo

Examples of jsky.catalog.vo.VoCatalog


     * @throws Exception on error
     */
    protected void tableLoadVotable(URL url, String tableId, String name) throws Exception {
        Navigator navigator = _imageFrame.getNavigator();
        if (navigator != null) {
            VoCatalog catalog = new VoCatalog(VoTable.createVoTable(url, tableId, name));
            navigator.setQueryResult(catalog);
            navigator.setOrigURL(url); // XXX is this still needed?
            navigator.registerTable(url, tableId);
        }
    }
View Full Code Here


                StarTable starTable = new FitsPlusTableBuilder().makeStarTable(dataSrc, true,
                        StoragePolicy.getDefaultPolicy());
                dataSrc.close();
                VoTable table = VoTable.createVoTable(starTable, null, 1000000);
                table.setName(name);
                new VoCatalog(table); // Wraps the table in a local catalog for searching
                return table;
            }
        }

        // Fall back to the old default, based on Skycat tables
View Full Code Here

                public InputStream getRawInputStream() {
                    return new ByteArrayInputStream(votBytes);
                }
            };
            String name = sender.toString() + "-" + id;
            VoCatalog catalog = new VoCatalog(VoTable.createVoTable(datsrc, id, name));
            navigator.setQueryResult(catalog);
            navigator.registerTable(null, id);
        }
    }
View Full Code Here

            throws IOException {
        Navigator navigator = _imageFrame.getNavigator();
        if (navigator != null) {
            String name = sender.toString() + "-" + id;
            URL url = new URL(urlStr);
            VoCatalog catalog = new VoCatalog(VoTable.createVoTable(url, id, name));
            navigator.setQueryResult(catalog);
            navigator.registerTable(url, id);
        }
    }
View Full Code Here

                || "text/xml".equalsIgnoreCase(contentType)
                || filename.endsWith(".xml")
                || filename.endsWith(".vot")) {
            // VOTable XML file or FITS table
            VoTable table = VoTable.createVoTable(url, null, format);
            table.setCatalog(new VoCatalog(table));
            return makeCatalogComponent(table.getCatalog());
        }

        if ("text/csv".equalsIgnoreCase(format)) {
            // CSV formatted table
            StarTable starTable = new CsvStarTable(new URLDataSource(url));
            VoTable table = VoTable.createVoTable(starTable, null, Integer.MAX_VALUE);
            table.setCatalog(new VoCatalog(table));
            return makeCatalogComponent(table.getCatalog());
        }

        if (filename.toLowerCase().endsWith(".fits") && !"application/xml".equalsIgnoreCase(contentType)) {
            // Local FITS table file
            try {
//              NavigatorFITSTable table = NavigatorFITSTable.getFitsTable(filename);
                VoTable table = VoTable.createVoTable(url, null, format);
                table.setCatalog(new VoCatalog(table));
                return makeCatalogComponent(table.getCatalog());
            } catch (Exception e) {
                // ignore: might be an image file, which is handled below
            }
        }
View Full Code Here

TOP

Related Classes of jsky.catalog.vo.VoCatalog

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.