Examples of becomeWorkingCopy()


Examples of org.aspectj.org.eclipse.jdt.internal.core.CompilationUnit.becomeWorkingCopy()

   */
  public final ICompilationUnit newWorkingCopy(String name, IClasspathEntry[] classpath, IProblemRequestor problemRequestor, IProgressMonitor monitor) throws JavaModelException {
    ExternalJavaProject project = new ExternalJavaProject(classpath);
    IPackageFragment parent = project.getPackageFragmentRoot(Path.EMPTY).getPackageFragment(IPackageFragment.DEFAULT_PACKAGE_NAME);
    CompilationUnit result = new CompilationUnit((PackageFragment) parent, name, this);
    result.becomeWorkingCopy(problemRequestor, monitor);
    return result;
  }

  /**
   * Returns a new working copy with the given name using this working copy owner to
View Full Code Here

Examples of org.aspectj.org.eclipse.jdt.internal.core.CompilationUnit.becomeWorkingCopy()

   */
  public final ICompilationUnit newWorkingCopy(String name, IClasspathEntry[] classpath, IProgressMonitor monitor) throws JavaModelException {
    ExternalJavaProject project = new ExternalJavaProject(classpath);
    IPackageFragment parent = project.getPackageFragmentRoot(Path.EMPTY).getPackageFragment(IPackageFragment.DEFAULT_PACKAGE_NAME);
    CompilationUnit result = new CompilationUnit((PackageFragment) parent, name, this);
    result.becomeWorkingCopy(getProblemRequestor(result), monitor);
    return result;
  }

}
View Full Code Here

Examples of org.eclipse.dltk.core.ISourceModule.becomeWorkingCopy()

  @Test
  public void testCompletionOnOutSrc() throws Exception { testCompletionOnOutSrc$(); }
  public void testCompletionOnOutSrc$() throws Exception {
    ISourceModule srcModule = SampleMainProject.getSourceModule(IOutsideBuildpathTestResources.TEST_OUTFILE);
   
    srcModule.becomeWorkingCopy(null, null);
    try {
      final int offset = srcModule.getSource().indexOf("Foo foo");
     
      class CompletionRequestorTestCheck extends CompletionRequestor {
        @Override
View Full Code Here

Examples of org.eclipse.dltk.core.ISourceModule.becomeWorkingCopy()

    sourceModule.discardWorkingCopy();
   
    String originalFileContents = "module wc_change0;";
    updateFileContents(moduleFile, originalFileContents);
   
    sourceModule.becomeWorkingCopy(new NullProblemRequestor(), new NullProgressMonitor());
    doCodeCompletion(moduleFile, 0, "wc_change0");
   
    sourceModule.getBuffer().setContents("module wc_change1;");
    assertEquals(readFileContents(moduleFile), originalFileContents);
   
View Full Code Here

Examples of org.eclipse.dltk.core.ISourceModule.becomeWorkingCopy()

    sourceModule = testsProject.getSourceModule("source/basic_pack/foo.d");
    moduleFile = (IFile) sourceModule.getResource();
    doCodeCompletion(moduleFile, 0, "basic_pack/");
   
    // Test commitWorkingCopy
    sourceModule.becomeWorkingCopy(new NullProblemRequestor(), new NullProgressMonitor());
    sourceModule.getBuffer().setContents("module wc_commitWC_Test;");
    sourceModule.commitWorkingCopy(true, new NullProgressMonitor());
    doCodeCompletion(moduleFile, 0, "wc_commitWC_Test/");

    sourceModule.getBuffer().setContents("module wc_commitWC_Test2;");
View Full Code Here

Examples of org.eclipse.dltk.core.ISourceModule.becomeWorkingCopy()

                                   * no
                                   * progress
                                   * monitor
                                   */);
    else
      workingCopy.becomeWorkingCopy(problemRequestor, null/*
                                 * no progress
                                 * monitor
                                 */);
    workingCopy.getBuffer().setContents(source);
    // if (problemRequestor instanceof ProblemRequestor)
View Full Code Here

Examples of org.eclipse.dltk.core.ISourceModule.becomeWorkingCopy()

                IFile file = filesMap.get(pdttFile);
                ISourceModule modelElement = (ISourceModule) DLTKCore
                    .create(file);
                if (ScriptModelUtil.isPrimary(modelElement))
                  modelElement.becomeWorkingCopy(
                      new IProblemRequestor() {

                        public void acceptProblem(
                            IProblem problem) {
                          // TODO Auto-generated
View Full Code Here

Examples of org.eclipse.dltk.core.ISourceModule.becomeWorkingCopy()

                IFile file = filesMap.get(pdttFile);
                ISourceModule modelElement = (ISourceModule) DLTKCore
                    .create(file);
                if (ScriptModelUtil.isPrimary(modelElement))
                  modelElement.becomeWorkingCopy(
                      new IProblemRequestor() {

                        public void acceptProblem(
                            IProblem problem) {
                          // TODO Auto-generated
View Full Code Here

Examples of org.eclipse.dltk.core.ISourceModule.becomeWorkingCopy()

                IFile file = filesMap.get(pdttFile);
                ISourceModule modelElement = (ISourceModule) DLTKCore
                    .create(file);
                if (ScriptModelUtil.isPrimary(modelElement))
                  modelElement.becomeWorkingCopy(
                      new IProblemRequestor() {

                        public void acceptProblem(
                            IProblem problem) {
                          // TODO Auto-generated
View Full Code Here

Examples of org.eclipse.dltk.core.ISourceModule.becomeWorkingCopy()

                IFile file = filesMap.get(pdttFile);
                ISourceModule modelElement = (ISourceModule) DLTKCore
                    .create(file);
                if (ScriptModelUtil.isPrimary(modelElement))
                  modelElement.becomeWorkingCopy(
                      new IProblemRequestor() {

                        public void acceptProblem(
                            IProblem problem) {
                          // TODO Auto-generated
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.