Package org.gephi.project.api

Examples of org.gephi.project.api.ProjectMetaData


        writer.writeEndElement();
    }

    public void writeProject(XMLStreamWriter writer, Project project) throws Exception {
        ProjectInformation info = project.getLookup().lookup(ProjectInformation.class);
        ProjectMetaData metaData = project.getLookup().lookup(ProjectMetaData.class);
        WorkspaceProviderImpl workspaces = project.getLookup().lookup(WorkspaceProviderImpl.class);

        writer.writeStartElement("project");
        writer.writeAttribute("name", info.getName());

        //MetaData
        writer.writeStartElement("metadata");

        writer.writeStartElement("title");
        writer.writeCharacters(metaData.getTitle());
        writer.writeEndElement();

        writer.writeStartElement("keywords");
        writer.writeCharacters(metaData.getKeywords());
        writer.writeEndElement();

        writer.writeStartElement("description");
        writer.writeCharacters(metaData.getDescription());
        writer.writeEndElement();

        writer.writeStartElement("author");
        writer.writeCharacters(metaData.getAuthor());
        writer.writeEndElement();

        writer.writeEndElement();

        //Workspaces
View Full Code Here


            if (info.getFile() != null) {
                fileLabel.setText(info.getFile().getName());
            }
        }

        ProjectMetaData metaData = project.getLookup().lookup(ProjectMetaData.class);
        if (metaData != null) {
            titleTextField.setText(metaData.getTitle());
            authorTextField.setText(metaData.getAuthor());
            keywordsTextField.setText(metaData.getKeywords());
            descriptionTextArea.setText(metaData.getDescription());
        }
    }
View Full Code Here

            if (!nameTextField.getText().isEmpty() && !nameTextField.getText().equals(info.getName())) {
                ProjectController pc = Lookup.getDefault().lookup(ProjectController.class);
                pc.renameProject(project, nameTextField.getText());
            }
        }
        ProjectMetaData metaData = project.getLookup().lookup(ProjectMetaData.class);
        if (metaData != null) {
            metaData.setTitle(titleTextField.getText());

            metaData.setAuthor(authorTextField.getText());
            metaData.setKeywords(keywordsTextField.getText());
            metaData.setDescription(descriptionTextArea.getText());
        }
    }
View Full Code Here

            if (info.getFile() != null) {
                fileLabel.setText(info.getFile().getName());
            }
        }

        ProjectMetaData metaData = project.getLookup().lookup(ProjectMetaData.class);
        if (metaData != null) {
            titleTextField.setText(metaData.getTitle());
            authorTextField.setText(metaData.getAuthor());
            keywordsTextField.setText(metaData.getKeywords());
            descriptionTextArea.setText(metaData.getDescription());
        }
    }
View Full Code Here

            if (!nameTextField.getText().isEmpty() && !nameTextField.getText().equals(info.getName())) {
                ProjectController pc = Lookup.getDefault().lookup(ProjectController.class);
                pc.renameProject(project, nameTextField.getText());
            }
        }
        ProjectMetaData metaData = project.getLookup().lookup(ProjectMetaData.class);
        if (metaData != null) {
            metaData.setTitle(titleTextField.getText());

            metaData.setAuthor(authorTextField.getText());
            metaData.setKeywords(keywordsTextField.getText());
            metaData.setDescription(descriptionTextArea.getText());
        }
    }
View Full Code Here

        writer.writeStartElement("projectFile");

        writeHeader(writer);

        ProjectInformation info = project.getLookup().lookup(ProjectInformation.class);
        ProjectMetaData metaData = project.getLookup().lookup(ProjectMetaData.class);

        //Start Project
        writer.writeStartElement("project");
        writer.writeAttribute("name", info.getName());
        writer.writeAttribute("ids", String.valueOf(((ProjectImpl) project).getWorkspaceIds()));

        //MetaData
        writer.writeStartElement("metadata");

        writer.writeStartElement("title");
        writer.writeCharacters(metaData.getTitle());
        writer.writeEndElement();

        writer.writeStartElement("keywords");
        writer.writeCharacters(metaData.getKeywords());
        writer.writeEndElement();

        writer.writeStartElement("description");
        writer.writeCharacters(metaData.getDescription());
        writer.writeEndElement();

        writer.writeStartElement("author");
        writer.writeCharacters(metaData.getAuthor());
        writer.writeEndElement();

        writer.writeEndElement();
        //End Metadata
View Full Code Here

TOP

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

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.