Package org.eclipse.php.internal.core.includepath

Examples of org.eclipse.php.internal.core.includepath.IncludePath


  public IProject getCurrProject() {
    return getProject();
  }

  protected IncludePath[] setProjectBaseIncludepath() {
    return new IncludePath[] { new IncludePath(getProject(), getProject()) };
  }
View Full Code Here


    IncludePathManager manager = IncludePathManager.getInstance();
    IncludePath[] includePath = manager.getIncludePaths(project);
    int count = includePath.length;
    System.arraycopy(includePath, 0,
        includePath = new IncludePath[count + 1], 0, count);
    includePath[count] = new IncludePath(folder, project);

    setIncludePath(manager, includePath);
    includePath = manager.getIncludePaths(project);

    Assert.assertTrue(includePath.length == 1);
View Full Code Here

    } else if (object instanceof IProjectFragment) {
      IProjectFragment root = (IProjectFragment) object;
    } else {
      assert object instanceof IncludePath;

      IncludePath includePath = (IncludePath) object;
      try {
        if (includePath.isBuildpath())
          IncludePathManager.getInstance()
              .removeEntryFromIncludePath(
                  includePath.getProject(),
                  (IBuildpathEntry) (includePath.getEntry()));
        IProject proj = includePath.getProject();
        IncludePathManager manager = IncludePathManager.getInstance();
        IncludePath[] paths = manager.getIncludePaths(proj);
        List<IncludePath> entries = new ArrayList<IncludePath>();
        for (IncludePath path : paths) {
          if (!path.equals(includePath)) {
View Full Code Here

            .getEntry();
        if (renamedPath.isPrefixOf(entry.getPath())) {
          entry = replaceBuildpath(destProjectName,
              newBuildPathEntryList, renamedPath, entry);

          includePath = new IncludePath(entry,
              includePath.getProject());
        }

      } else if (includePath.getEntry() instanceof IResource) {
        IResource oldRes = (IResource) includePath.getEntry();

        if (renamedPath.isPrefixOf(oldRes.getFullPath())) {
          renamedPath = renamedPath
              .removeLastSegments(1)
              .append(destProjectName)
              .append(oldRes.getFullPath().removeFirstSegments(
                  renamedPath.segmentCount()));
          IResource newRes = null;
          if (oldRes.getType() == IResource.FILE) {
            newRes = ResourcesPlugin.getWorkspace().getRoot()
                .getFile(renamedPath);
          } else if (oldRes.getType() == IResource.FOLDER) {
            newRes = ResourcesPlugin.getWorkspace().getRoot()
                .getFolder(renamedPath);
          } else if (oldRes.getType() == IResource.PROJECT) {
            newRes = ResourcesPlugin.getWorkspace().getRoot()
                .getProject(renamedPath.toString());
          }
          includePath = new IncludePath(newRes,
              includePath.getProject());
        }
      }
    }
    return includePath;
View Full Code Here

        cpEntries.add(DLTKCore.newSourceEntry(projectPath
            .append(srcPath)));

        buildpathEntries = (IBuildpathEntry[]) cpEntries
            .toArray(new IBuildpathEntry[cpEntries.size()]);
        includepathEntries = new IncludePath[] { new IncludePath(
            getProject().getFolder(srcPath), getProject()) };
      } else {
        // flat project layout
        IPath projectPath = getProject().getFullPath();
        List cpEntries = new ArrayList();
View Full Code Here

   *
   * @return array of IncludePath's, size=1, and includes only the project's
   *         root-dir include path
   */
  protected IncludePath[] setProjectBaseIncludepath() {
    return new IncludePath[] { new IncludePath(getProject(), getProject()) };
  }
View Full Code Here

TOP

Related Classes of org.eclipse.php.internal.core.includepath.IncludePath

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.