|
||||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |
public interface ReversePolishNotationProcessor
逆ポーランド記法を評価するプロセッサを表すインターフェースです。
メソッドの概要 | |
---|---|
ReversePolishNotationOperand |
addOperation(ReversePolishNotationOperand left,
ReversePolishNotationOperand right)
2個のオペランドの和を返します。 |
ReversePolishNotationOperand |
evaluate(ReversePolishNotationOperand operand)
オペランドを逆ポーランド記法により評価した結果を返します。 |
String |
getFormat()
数値の出力フォーマットを返します。 |
String |
getResult(ReversePolishNotationOperand operand)
オペランドを評価した結果を返します。 |
ReversePolishNotationOperand |
inverseOperation(ReversePolishNotationOperand operand)
オペランドの逆数を返します。 |
ReversePolishNotationOperand |
multiplyOperation(ReversePolishNotationOperand left,
ReversePolishNotationOperand right)
2個のオペランドの積を返します。 |
void |
setFormat(String format)
数値の出力フォーマットを設定します。 |
メソッドの詳細 |
---|
ReversePolishNotationOperand evaluate(ReversePolishNotationOperand operand)
operand
- 対象となるオペランド
String getResult(ReversePolishNotationOperand operand)
operand
- 対象となるオペランド
String getFormat()
void setFormat(String format)
format
- 数値の出力フォーマットReversePolishNotationOperand inverseOperation(ReversePolishNotationOperand operand)
operand
- オペランド
ReversePolishNotationOperand addOperation(ReversePolishNotationOperand left, ReversePolishNotationOperand right)
left
- 左オペランドright
- 左オペランド
ReversePolishNotationOperand multiplyOperation(ReversePolishNotationOperand left, ReversePolishNotationOperand right)
left
- オペランドright
- オペランド
|
||||||||||
前のクラス 次のクラス | フレームあり フレームなし | |||||||||
概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド |