List of usage examples for org.eclipse.jdt.core.dom PostfixExpression setSourceRange
public final void setSourceRange(int startPosition, int length)
From source file:org.eclipse.jdt.core.dom.ASTConverter.java
License:Open Source License
public PostfixExpression convert(org.eclipse.jdt.internal.compiler.ast.PostfixExpression expression) { final PostfixExpression postfixExpression = new PostfixExpression(this.ast); if (this.resolveBindings) { recordNodes(postfixExpression, expression); }/*from w w w.j av a 2s . co m*/ postfixExpression.setSourceRange(expression.sourceStart, expression.sourceEnd - expression.sourceStart + 1); postfixExpression.setOperand(convert(expression.lhs)); switch (expression.operator) { case org.eclipse.jdt.internal.compiler.ast.OperatorIds.PLUS: postfixExpression.setOperator(PostfixExpression.Operator.INCREMENT); break; case org.eclipse.jdt.internal.compiler.ast.OperatorIds.MINUS: postfixExpression.setOperator(PostfixExpression.Operator.DECREMENT); break; } return postfixExpression; }