@Override public int getLength() { int minStart= Integer.MAX_VALUE; int maxEnd= 0; for (ITrackedNodePosition node : fPos) { minStart= Math.min(minStart, node.getStartPosition()); maxEnd= Math.max(maxEnd, node.getStartPosition() + node.getLength()); } return minStart == Integer.MAX_VALUE ? 0 : maxEnd - getOffset(); }
@Override public int getOffset() { return fPos.getStartPosition(); }
@Override public int getLength() { return fPos.getLength(); }
@Override public int getOffset() { return fPos.getStartPosition(); }
@Override public int getLength() { return fPos.getLength(); }
@Override public int getLength() { int minStart= Integer.MAX_VALUE; int maxEnd= 0; for (ITrackedNodePosition node : fPos) { minStart= Math.min(minStart, node.getStartPosition()); maxEnd= Math.max(maxEnd, node.getStartPosition() + node.getLength()); } return minStart == Integer.MAX_VALUE ? 0 : maxEnd - getOffset(); }
@Override public int getOffset() { return fPos.getStartPosition(); }
public int getLength() { return fPos.getLength(); }
public int getBodyLength() { return fLastInsertedPosition.getStartPosition() + fLastInsertedPosition.getLength() - getBodyStart(); }
public int getBodyStart() { return fFirstInsertedPosition.getStartPosition(); }
public int getBodyLength() { return fLastInsertedPosition.getStartPosition() + fLastInsertedPosition.getLength() - getBodyStart(); }
public int getBodyStart() { return fFirstInsertedPosition.getStartPosition(); }
public int getBodyLength() { return fLastInsertedPosition.getStartPosition() + fLastInsertedPosition.getLength() - getBodyStart(); }
@Override public int getOffset() { return fPos.getStartPosition(); }
private String getUpdatedMember(IDocument document, BodyDeclaration declaration) throws BadLocationException { ITrackedNodePosition trackedPosition= (ITrackedNodePosition) declaration.getProperty(TRACKED_POSITION_PROPERTY); return Strings.trimIndentation(document.get(trackedPosition.getStartPosition(), trackedPosition.getLength()), fPreferences.tabWidth, fPreferences.indentWidth, false); }
public int getOffset() { return fPos.getStartPosition(); }
private String getUpdatedMember(IDocument document, BodyDeclaration declaration) throws BadLocationException { ITrackedNodePosition trackedPosition= (ITrackedNodePosition) declaration.getProperty(TRACKED_POSITION_PROPERTY); return Strings.trimIndentation(document.get(trackedPosition.getStartPosition(), trackedPosition.getLength()), fPreferences.tabWidth, fPreferences.indentWidth, false); }
public int getBodyStart() { return fFirstInsertedPosition.getStartPosition(); }
private String getUpdatedMember(IDocument document, BodyDeclaration declaration) throws BadLocationException { ITrackedNodePosition trackedPosition= (ITrackedNodePosition) declaration.getProperty(TRACKED_POSITION_PROPERTY); return Strings.trimIndentation(document.get(trackedPosition.getStartPosition(), trackedPosition.getLength()), fPreferences.tabWidth, fPreferences.indentWidth, false); }
@Override public int getOffset() { int minStart= Integer.MAX_VALUE; for (ITrackedNodePosition node : fPos) { minStart= Math.min(minStart, node.getStartPosition()); } return minStart == Integer.MAX_VALUE ? -1 : minStart; }