|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
Abstract description of an assertion that can be evaluated on an element of a collection.
Assertions can be (fairly) easily defined inline using anonymous classes:
// Make sure that Vector `v' contains only Integers.
ForAll.in(collection).ensure(new Assertion() {
public boolean eval(Object o) {
return (o instanceof Integer);
}
});
| Method Summary | |
boolean |
eval(java.lang.Object o)
Evaluate the assertion on an object. |
| Method Detail |
public boolean eval(java.lang.Object o)
o - the object to test.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||