Package org.aspectj.org.eclipse.jdt.core

Examples of org.aspectj.org.eclipse.jdt.core.ICompilationUnit.save()


      // update the contents of the existing unit if fForce is true
      if (force) {
        IBuffer buffer = unit.getBuffer();
        if (buffer == null) return;
        buffer.setContents(fSource);
        unit.save(new NullProgressMonitor(), false);
        resultElements = new IJavaElement[] {unit};
        if (!Util.isExcluded(unit)
            && unit.getParent().exists()) {
          for (int i = 0; i < resultElements.length; i++) {
            delta.changed(resultElements[i], IJavaElementDelta.F_CONTENT);
View Full Code Here


          }
        }
      }
    }
    if (delta.getAffectedChildren().length > 0) {
      cu.save(getSubProgressMonitor(1), force);
      if (!cu.isWorkingCopy()) { // if unit is working copy, then save will have already fired the delta
        addDelta(delta);
        setAttribute(HAS_MODIFIED_RESOURCE_ATTR, TRUE);
      }
    }
View Full Code Here

      JavaElementDelta delta = newJavaElementDelta();
      ICompilationUnit unit = getCompilationUnit();
      generateNewCompilationUnitAST(unit);
      if (this.creationOccurred) {
        //a change has really occurred
        unit.save(null, false);
        boolean isWorkingCopy = unit.isWorkingCopy();
        if (!isWorkingCopy)
          setAttribute(HAS_MODIFIED_RESOURCE_ATTR, TRUE);
        worked(1);
        resultElements = generateResultHandles();
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.