Package org.cdma.interfaces

Examples of org.cdma.interfaces.IDataset


        final JPanel panel = new JPanel(new BorderLayout());
        final Tree tree = new Tree();

        URL fileURL = ArchivingCDMAPluginTest.class.getResource("testCouleurExpression.vc");
        File newFile = null;
        IDataset dataset = null;
        try {
            newFile = new File(fileURL.toURI());
            dataset = new VcDataset(newFile);
            dataset.open();

        } catch (IOException e1) {
            e1.printStackTrace();
        } catch (URISyntaxException e2) {
            e2.printStackTrace();
        }

        ITreeNode rootNode = new BasicTreeNode();
        constructTree(rootNode, dataset.getRootGroup());
        tree.setRootNode(rootNode);
        tree.addMouseListener(archivingListener);

        panel.add(tree, BorderLayout.CENTER);
View Full Code Here


    protected void addDatasetFromDialog(final URI uri) {
        Display.getDefault().asyncExec(new Runnable() {
            @Override
            public void run() {
                try {
                    IDataset dataset = makeDataset(uri);
                    // Check duplication
                    for (IDataset ds : datasets) {
                        if (dataset.getLocation().equals(ds.getLocation())) {
                            dataset.close();
                            return;
                        }
                    }
                    // If not duplicated, open it
                    if (!dataset.isOpen()) {
                        dataset.open();
                    }
                    datasets.add(dataset);
                    treeViewer.add(datasets, dataset);
                    for (DatasetChangeListener listener : getDatasetChangeListeners()) {
                        // listener.datasetAdded(dataset);
View Full Code Here

    public void addDataset(final URI uri) {
        Display.getDefault().asyncExec(new Runnable() {
            @Override
            public void run() {
                try {
                    IDataset dataset = makeDataset(uri);
                    // Check duplication
                    for (IDataset ds : datasets) {
                        if (dataset.getLocation().equals(ds.getLocation())) {
                            dataset.close();
                            return;
                        }
                    }
                    // If not duplicated, open it
                    if (!dataset.isOpen()) {
                        dataset.open();
                    }
                    datasets.add(dataset);
                    treeViewer.add(datasets, dataset);
                    //                                      treeViewer.expandToLevel(dataset, 0);
                } catch (Exception e1) {
View Full Code Here

TOP

Related Classes of org.cdma.interfaces.IDataset

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.