Package org.eclipse.core.resources

Examples of org.eclipse.core.resources.IProject.open()


            description.setLocation(locationPath);
          }
         
          monitor.worked(1);
          project.create(description, monitor);
          project.open(monitor);
          monitor.worked(1);
         
          if (!project.hasNature(PHPNature.ID)) {
            ResourceUtil.addNature(project, monitor, PHPNature.ID);
          }
View Full Code Here


      final IProject project = root.getProject(projectDescription
          .getName());
      createProject(monitor, projectDescription, project, exists);
      importedProjects.add(project);

      project.open(monitor);
      connectProject(monitor, repositoryPath, project);
    }
  }

  protected void connectProject(final IProgressMonitor monitor,
View Full Code Here

      }
      desc.setLocationURI(uri);
      project.create(desc, monitor);
    }
    if (!project.isOpen()) {
      project.open(monitor);
    }
    return project;
  }

  public static void createFile(IPath relativeDstFilePath, File srcFile, String license, String connectorName, String packageName) throws CoreException {
View Full Code Here

    @Override
    protected void finishInstallTemplate(IProgressMonitor monitor) throws Exception {
      IProject project = getProject();
      project.close(new SubProgressMonitor(monitor, 1000));
      project.open(new SubProgressMonitor(monitor, 1000));

      createEOModelSupport();
      createFrameworksSupport();
      addWebServiceFrameworks();
View Full Code Here

  public void testAddIncrementalFrameworkNature() {
    IProject project = this.getProject("testAddIncrementalFrameworkNature");
    NullProgressMonitor monitor = new NullProgressMonitor();
    try {
      project.create(monitor);
      project.open(monitor);
      IProjectDescription description = project.getDescription();
      List<String> naturesList = new ArrayList<String>(Arrays.asList(description.getNatureIds()));
      naturesList.add("org.eclipse.jdt.core.javanature");
      description.setNatureIds(naturesList.toArray(new String[naturesList.size()]));
      project.setDescription(description, monitor);
View Full Code Here

  public void testAddIncrementalApplicationNature() {
    IProject project = this.getProject("testAddIncrementalApplicationNature");
    NullProgressMonitor monitor = new NullProgressMonitor();
    try {
      project.create(monitor);
      project.open(monitor);
      IProjectDescription description = project.getDescription();
      List<String> naturesList = new ArrayList<String>(Arrays.asList(description.getNatureIds()));
      naturesList.add("org.eclipse.jdt.core.javanature");
      description.setNatureIds(naturesList.toArray(new String[naturesList.size()]));
      project.setDescription(description, monitor);
View Full Code Here

  public void testAddAndFrameworkNature() {
    IProject project = this.getProject("testAddAndFrameworkNature");
    NullProgressMonitor monitor = new NullProgressMonitor();
    try {
      project.create(monitor);
      project.open(monitor);
      IProjectDescription description = project.getDescription();
      List<String> naturesList = new ArrayList<String>(Arrays.asList(description.getNatureIds()));
      naturesList.add("org.eclipse.jdt.core.javanature");
      description.setNatureIds(naturesList.toArray(new String[naturesList.size()]));
      project.setDescription(description, monitor);
View Full Code Here

  public void testAddAntApplicationNature() {
    IProject project = this.getProject("testAddAntApplicationNature");
    NullProgressMonitor monitor = new NullProgressMonitor();
    try {
      project.create(monitor);
      project.open(monitor);
      IProjectDescription description = project.getDescription();
      List<String> naturesList = new ArrayList<String>(Arrays.asList(description.getNatureIds()));
      naturesList.add("org.eclipse.jdt.core.javanature");
      description.setNatureIds(naturesList.toArray(new String[naturesList.size()]));
      project.setDescription(description, monitor);
View Full Code Here

          for (IProjectDescription projectDescription : projectDescriptions) {
            try {
              IProject project = ResourcesPlugin.getWorkspace().getRoot().getProject(projectDescription.getName());
              monitor.beginTask("Importing " + project.getName() + " ...", 100);
              project.create(projectDescription, new SubProgressMonitor(monitor, 30));
              project.open(IResource.BACKGROUND_REFRESH, new SubProgressMonitor(monitor, 70));
            }
            catch (Throwable t) {
              System.out.println("ImportProjectsTask.run: " + t.getMessage());
            }
          }
View Full Code Here

    description.setLocationURI(projectProject.getProjectUri());
    description.setNatureIds(new String[] { JS_DEBUG_PROJECT_NATURE });
    try {

      project.create(description, null);
      project.open(null);

      return project;
    } catch (CoreException e) {
      ChromiumDebugPlugin.log(e);
      return null;
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.