|
Evaluating Software Design Patterns — the "Gang of Four" patterns implemented in Java 6 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object dk.rode.thesis.builder.Main
@Participant(value="Director") public class Main
Builder tests.
Constructor Summary | |
---|---|
Main()
No-arg constructor. |
Method Summary | ||
---|---|---|
private
|
create(ComparableExpressionBuilder<E> builder,
Class<E> type,
E value)
Builds: next[20], y = current, (reverse[true] ? |
|
private void |
log(boolean log)
True to enable logging per expression type. |
|
static void |
main(String[] args)
Executes the Builder tests. |
|
boolean |
test(Log out,
Arguments arguments)
Performs the specific tests and report the outcome to the log supplied as log . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Main()
Method Detail |
---|
private final <E extends Comparable<? super E>> Expression<E> create(ComparableExpressionBuilder<E> builder, Class<E> type, E value) throws ExpressionException
next[20], y = current, (reverse[true] ? next[10], x = current, (x < value ? x : break[y]) : current)Depending on
builder
, type information may be included.
E
- The type of value the evaluation of the
returned expression produces.builder
- The builder to use; cannot be null.type
- The actual type; cannot be null.value
- The value to use in the expression; cannot be null.
NullPointerException
- If either argument is null.
ExpressionException
- If the construction fails.private void log(boolean log)
log
- True to enable verbose logging per expression type,
false to disable.public static void main(String[] args)
args
- The arguments to supply to test(Log, Arguments)
,
if any; can be null.public boolean test(Log out, Arguments arguments)
Testable
log
supplied as log
. Arguments to control log-level:
-log
: a boolean value (as a string) indicating if
class logging is enabled for relevant classes.
-log.verbose
: a boolean value (as a string) indicating
if class logging is enabled for relevant classes that generates
verbose output.
test
in interface Testable
out
- The log to report the test outcome to; cannot be null.arguments
- Additional arguments, if any.
|
Gunni Rode / rode.dk | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |