C# Class GoRogue.DiceNotation.Terms.DivideTerm

Term representing the division operator -- divides the first term by the second.
Inheritance: ITerm
显示文件 Open project: Chris3606/GoRogue

Public Methods

Method Description
DivideTerm ( ITerm term1, ITerm term2 ) : System

Constructor. Takes the two terms to divide.

GetResult ( IEnhancedRandom rng ) : int

Divides the first term by the second, evaluating those two terms as necessary.

ToString ( ) : string

Returns a parenthesized string representing the operation.

Method Details

DivideTerm() public method

Constructor. Takes the two terms to divide.
public DivideTerm ( ITerm term1, ITerm term2 ) : System
term1 ITerm The first term (left-hand side).
term2 ITerm The second term (right-hand side).
return System

GetResult() public method

Divides the first term by the second, evaluating those two terms as necessary.
public GetResult ( IEnhancedRandom rng ) : int
rng IEnhancedRandom The rng to used -- passed to other terms.
return int

ToString() public method

Returns a parenthesized string representing the operation.
public ToString ( ) : string
return string