Package org.eclipse.core.resources

Examples of org.eclipse.core.resources.IWorkspace.validateName()


     
      updateStatus(IDEWorkbenchMessages.WizardNewProjectCreationPage_projectNameEmpty);
      return false;
    }

    IStatus nameStatus = workspace.validateName(projectFieldContents,
        IResource.PROJECT);
    if (!nameStatus.isOK()) {
      updateStatus(nameStatus.getMessage());
      return false;
    }
View Full Code Here


      setErrorMessage(null);
      setMessage(NewWizardMessages.NewJavaProjectWizardPageOne_Message_enterProjectName);
      return false;
    }

    final IStatus nameStatus = workspace.validateName(name, IResource.PROJECT);
    if (!nameStatus.isOK()) {
      setErrorMessage(nameStatus.getMessage());
      return false;
    }
View Full Code Here

  }

  private IProject getProject(String projectName) {
    IWorkspace workspace = ResourcesPlugin.getWorkspace();
    IProject project = null;
    IStatus status = workspace.validateName(projectName, IResource.PROJECT);
    if (status.isOK()) {
      project = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
      if (!project.exists()) {
        return null;
      }
View Full Code Here

    String projectName = fProjText.getText().trim();
    IProject project = null;
    if (projectName.length() > 0) {
      IWorkspace workspace = ResourcesPlugin.getWorkspace();
      IStatus status = workspace.validateName(projectName, IResource.PROJECT);
      if (status.isOK()) {
        project = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
        if (!project.exists()) {
          setErrorMessage(MessageFormat.format("Project {0} does not exist", projectName));
          fWebappDirButton.setEnabled(false);
View Full Code Here

      String projectName = config.getAttribute(
          IJavaLaunchConfigurationConstants.ATTR_PROJECT_NAME, "");
      IProject project = null;
      if (projectName.length() > 0) {
        IWorkspace workspace = ResourcesPlugin.getWorkspace();
        IStatus status = workspace.validateName(projectName,
            IResource.PROJECT);
        if (status.isOK()) {
          project = ResourcesPlugin.getWorkspace().getRoot()
              .getProject(projectName);
          if (!project.exists()) {
View Full Code Here

    } catch (CoreException e) {
      return false;
    }
    if (projectName.length() > 0) {
      IWorkspace workspace = ResourcesPlugin.getWorkspace();
      IStatus status = workspace.validateName(projectName,
          IResource.PROJECT);
      if (status.isOK()) {
        IProject project = ResourcesPlugin.getWorkspace().getRoot()
            .getProject(projectName);
        if (!project.exists()) {
View Full Code Here

  }

  private static IProject getProject(String projectName) {
    IWorkspace workspace = ResourcesPlugin.getWorkspace();
    IProject project = null;
    IStatus status = workspace.validateName(projectName, IResource.PROJECT);
    if (status.isOK()) {
      project = ResourcesPlugin.getWorkspace().getRoot()
          .getProject(projectName);
      if (!project.exists()) {
        return null;
View Full Code Here

    String projectName = fProjText.getText().trim();
    IProject project = null;
    if (projectName.length() > 0) {
      IWorkspace workspace = ResourcesPlugin.getWorkspace();
      IStatus status = workspace.validateName(projectName,
          IResource.PROJECT);
      if (status.isOK()) {
        project = ResourcesPlugin.getWorkspace().getRoot()
            .getProject(projectName);
        if (!project.exists()) {
View Full Code Here

  }

  private static IProject getProject(String projectName) {
    IWorkspace workspace = ResourcesPlugin.getWorkspace();
    IProject project = null;
    IStatus status = workspace.validateName(projectName, IResource.PROJECT);
    if (status.isOK()) {
      project = ResourcesPlugin.getWorkspace().getRoot()
          .getProject(projectName);
      if (!project.exists()) {
        return null;
View Full Code Here

    String projectName = fProjText.getText().trim();
    IProject project = null;
    if (projectName.length() > 0) {
      IWorkspace workspace = ResourcesPlugin.getWorkspace();
      IStatus status = workspace.validateName(projectName,
          IResource.PROJECT);
      if (status.isOK()) {
        project = ResourcesPlugin.getWorkspace().getRoot()
            .getProject(projectName);
        if (!project.exists()) {
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.