Class RDBERule.Combinations
java.lang.Object
org.openscience.cdk.formula.rules.RDBERule.Combinations
- Enclosing class:
- RDBERule
-
Constructor Summary
ConstructorsConstructorDescriptionCombinations
(Object[] inArray, int m) Create a Combination to enumerate through all subsets of the supplied Object array, selecting m at a time. -
Method Summary
-
Constructor Details
-
Combinations
Create a Combination to enumerate through all subsets of the supplied Object array, selecting m at a time.- Parameters:
inArray
- the group to choose fromm
- int the number to select in each choice
-
-
Method Details
-
hasMoreElements
public boolean hasMoreElements()- Returns:
- true, unless we have already returned the last combination.
-
nextElement
- Returns:
- java.lang.Object, the next combination from the supplied Object array.
Actually, an array of Objects is returned. The declaration must say just Object, because the Combinations class implements Enumeration, which declares that the nextElement() returns a plain Object. Users must cast the returned object to (Object[]).
-