|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
java.lang.Objectorg.mklab.nfc.rpn.AbstractProcessor
org.mklab.nfc.rpn.AbstractExpressionProcessor
public abstract class AbstractExpressionProcessor
逆ポーランド記法を数式に関して評価する抽象クラスです。
| コンストラクタの概要 | |
|---|---|
AbstractExpressionProcessor()
|
|
| メソッドの概要 | |
|---|---|
ReversePolishNotationOperand |
addOperation(ReversePolishNotationOperand left,
ReversePolishNotationOperand right)
2個のオペランドの和を返します。 |
String |
getResult(ReversePolishNotationOperand operand)
オペランドを評価した結果を返します。 |
String |
getSignedExpression(ReversePolishNotationOperand operand)
オペランドの符号付数式を返します。 |
boolean |
hasCancellation()
数値がゼロの数式を削除するか判定します。 |
ReversePolishNotationOperand |
inverseOperation(ReversePolishNotationOperand operand)
オペランドの逆数を返します。 |
ReversePolishNotationOperand |
multiplyOperation(ReversePolishNotationOperand left,
ReversePolishNotationOperand right)
2個のオペランドの積を返します。 |
void |
setCancellation(boolean hasCancellation)
数値がゼロの数式を削除するか設定します。 |
| クラス org.mklab.nfc.rpn.AbstractProcessor から継承されたメソッド |
|---|
evaluate, getFormat, setFormat |
| クラス java.lang.Object から継承されたメソッド |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| インタフェース org.mklab.nfc.rpn.ReversePolishNotationExpressionProcessor から継承されたメソッド |
|---|
getInverseString, getLeftParentheses, getMultiplicationString, getRightParentheses |
| コンストラクタの詳細 |
|---|
public AbstractExpressionProcessor()
| メソッドの詳細 |
|---|
public boolean hasCancellation()
public void setCancellation(boolean hasCancellation)
hasCancellation - trueならば、数値がゼロの数式を削除します。public String getResult(ReversePolishNotationOperand operand)
ReversePolishNotationProcessor の記述:
ReversePolishNotationProcessor 内の getResultoperand - 対象となるオペランド
ReversePolishNotationProcessor.getResult(org.mklab.nfc.rpn.ReversePolishNotationOperand)public String getSignedExpression(ReversePolishNotationOperand operand)
operand - 対象となるオペランド
public ReversePolishNotationOperand inverseOperation(ReversePolishNotationOperand operand)
ReversePolishNotationProcessor の記述:
ReversePolishNotationProcessor 内の inverseOperationoperand - オペランド
ReversePolishNotationProcessor.inverseOperation(org.mklab.nfc.rpn.ReversePolishNotationOperand)
public ReversePolishNotationOperand addOperation(ReversePolishNotationOperand left,
ReversePolishNotationOperand right)
ReversePolishNotationProcessor の記述:
ReversePolishNotationProcessor 内の addOperationleft - 左オペランドright - 左オペランド
ReversePolishNotationProcessor.addOperation(org.mklab.nfc.rpn.ReversePolishNotationOperand,
org.mklab.nfc.rpn.ReversePolishNotationOperand)
public ReversePolishNotationOperand multiplyOperation(ReversePolishNotationOperand left,
ReversePolishNotationOperand right)
ReversePolishNotationProcessor の記述:
ReversePolishNotationProcessor 内の multiplyOperationleft - オペランドright - オペランド
ReversePolishNotationProcessor.multiplyOperation(org.mklab.nfc.rpn.ReversePolishNotationOperand,
org.mklab.nfc.rpn.ReversePolishNotationOperand)
|
||||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||