Package org.gephi.project.api

Examples of org.gephi.project.api.WorkspaceInformation


        writer.writeEndElement();
        writer.writeEndElement();
    }

    public void writeWorkspace(XMLStreamWriter writer, Workspace workspace) throws Exception {
        WorkspaceInformation info = workspace.getLookup().lookup(WorkspaceInformation.class);

        writer.writeStartElement("workspace");
        writer.writeAttribute("name", info.getName());
        if (info.isOpen()) {
            writer.writeAttribute("status", "open");
        } else if (info.isClosed()) {
            writer.writeAttribute("status", "closed");
        } else {
            writer.writeAttribute("status", "invalid");
        }
View Full Code Here


        //detailsLabel.setFont(detailsLabel.getFont().deriveFont((float) (detailsLabel.getFont().getSize() - 2)));
        closeButton.setAction(new DeleteAction());
        closeButton.setCursor(Cursor.getDefaultCursor());

        //Workspace info
        WorkspaceInformation info = workspace.getLookup().lookup(WorkspaceInformation.class);
        workspaceLabel.setText(info.getName());
        detailsLabel.setText(info.getSource());

        //Selected
        ProjectController pc = Lookup.getDefault().lookup(ProjectController.class);
        boolean selected = pc.getCurrentWorkspace() == workspace;
        if (selected) {
View Full Code Here

        fireWorkspaceEvent(EventType.INITIALIZE, workspace);
        return workspace;
    }

    public void deleteWorkspace(Workspace workspace) {
        WorkspaceInformation wi = workspace.getLookup().lookup(WorkspaceInformation.class);
        WorkspaceProviderImpl workspaceProvider = wi.getProject().getLookup().lookup(WorkspaceProviderImpl.class);

        Workspace toSelectWorkspace = null;
        if (getCurrentWorkspace() == workspace) {
            toSelectWorkspace = workspaceProvider.getPrecedingWorkspace(workspace);
        }
View Full Code Here

        writer.writeStartDocument("UTF-8", "1.0");
        writer.writeStartElement("workspaceFile");

        writeHeader(writer);

        WorkspaceInformation info = workspace.getLookup().lookup(WorkspaceInformation.class);

        writer.writeStartElement("workspace");
        writer.writeAttribute("name", info.getName());
        writer.writeAttribute("id", String.valueOf(workspace.getId()));
        if (info.isOpen()) {
            writer.writeAttribute("status", "open");
        } else if (info.isClosed()) {
            writer.writeAttribute("status", "closed");
        } else {
            writer.writeAttribute("status", "invalid");
        }
View Full Code Here

        //detailsLabel.setFont(detailsLabel.getFont().deriveFont((float) (detailsLabel.getFont().getSize() - 2)));
        closeButton.setAction(new DeleteAction());
        closeButton.setCursor(Cursor.getDefaultCursor());

        //Workspace info
        WorkspaceInformation info = workspace.getLookup().lookup(WorkspaceInformation.class);
        workspaceLabel.setText(info.getName());
        detailsLabel.setText(info.getSource());

        //Selected
        ProjectController pc = Lookup.getDefault().lookup(ProjectController.class);
        boolean selected = pc.getCurrentWorkspace() == workspace;
        if (selected) {
View Full Code Here

TOP

Related Classes of org.gephi.project.api.WorkspaceInformation

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.