Package org.eclipse.core.resources

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


      }
    }
   
    // Create project
    try {
      project.create(monitor);
    } catch (CoreException e) {
      e.printStackTrace();
    }

    // Generate the Classical B source
View Full Code Here


      }
    }
   
    // Create project
    try {
      project.create(monitor);
    } catch (CoreException e) {
      e.printStackTrace();
    }

    // Generate the Classical B source
View Full Code Here

   */
  public static IJavaProject createJavaProject(String projectName) throws CoreException {
    IWorkspaceRoot root= ResourcesPlugin.getWorkspace().getRoot();
    IProject project= root.getProject(projectName);
    if (!project.exists()) {
      project.create(null);
    } else {
      project.refreshLocal(IResource.DEPTH_INFINITE, null);
    }
   
    if (!project.isOpen()) {
View Full Code Here

    this.root = root;
  }

  public void create() throws CoreException {
    IProject project = getProject();
    project.create(null);
    project.open(null);

    project.getFile("build.properties").create(stream("_build.properties"), true, null);
    project.getFile(".classpath").create(stream("_classpath"), true, null);
    IFolder folder = project.getFolder("META-INF");
View Full Code Here

      throws CoreException {
    IProject project = EclipseUtils.getWorkspaceRoot().getProject(name);
    if(overwrite && project.exists()) {
      project.delete(true, pm);
    }
    project.create(pm);
    project.open(pm);
    return project;
  }
 
  public static void deleteProject_unchecked(String projectName) {
View Full Code Here

      if (projectPath != null) {
        description.setLocation(new Path(projectPath));
      }
     
      IProject project = root.getProject(description.getName());
      project.create(description, new NullProgressMonitor());
      project.open(new NullProgressMonitor());

      this.project = project;
     
      EclipseUtils.addNature(project, GoNature.NATURE_ID);
View Full Code Here

                e.printStackTrace();
            }
            goToManual(500);
        }
        try {
            project.create(monitor);
            goToManual(100);
        } catch (Exception e) {
            e.printStackTrace();
        }
        try {
View Full Code Here

            project.open(monitor);
        } catch (Exception e) {
            e.printStackTrace();
            if (!project.exists()) {
                try {
                    project.create(monitor);
                } catch (Exception j) {
                    j.printStackTrace();
                }
                project.open(monitor);
            }
View Full Code Here

      final String path = uri.getPath();

      try {
        final IProject importProject = root.getProject("import");
        if (!importProject.exists()) {
          importProject.create(null);
        }

        importProject.open(null);

        final InputStream is = new FileInputStream(path);
View Full Code Here

      IWorkspace ws = ResourcesPlugin.getWorkspace();
      // get, or create project if non existing
      IProject project = ws.getRoot().getProject(AUTOLINK_PROJECT_NAME);
      boolean newProject = false;
      if(!project.exists()) {
        project.create(null);
       
        newProject = true;
      }
      if(!project.isOpen()) {
        project.open(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.