dk.rode.thesis.visitor
Class DateValuedVisitableSequence
java.lang.Object
dk.rode.thesis.decorator.SequenceDecorator<E>
dk.rode.thesis.visitor.AbstractVisitableSequence<Date>
dk.rode.thesis.visitor.DateValuedVisitableSequence
- All Implemented Interfaces:
- Sequence<Date>, Copyable<Sequence<Date>>, StrictCopyable<Sequence<Date>>, Stringable<Sequence<Date>>, TypeVisitableSequence<Date>, ValueVisitableSequence<Date>
@Participant(value="ConcreteElement")
public class DateValuedVisitableSequence
- extends AbstractVisitableSequence<Date>
A date valued visitable sequence allows any
sequence
delivering Date
values
to become value
visitable using the
SequenceValueVisitor.visitDateValued(Sequence, Object)
visitation method and is type
visitable for any known sub-interface of Sequence
that is implemented by the sequence.
- Author:
- Gunni Rode / rode.dk
- See Also:
IntegerValuedVisitableSequence
,
StringValuedVisitableSequence
,
ReflectiveVisitableSequence
Methods inherited from class dk.rode.thesis.decorator.SequenceDecorator |
bounded, consistent, current, equals, getSequence, getStringablePolicy, hashCode, next, reset, state, toString, toString, unique |
DateValuedVisitableSequence
public DateValuedVisitableSequence(Sequence<Date> sequence)
- Constructor.
- Parameters:
sequence
- The decorated sequence that will become visitable;
cannot be null.
- Throws:
NullPointerException
- If sequence
is null.
accept
public <P> void accept(SequenceValueVisitor<P> visitor,
P argument)
- Description copied from interface:
ValueVisitableSequence
- Visits this visitable sequence using the
value
visitor supplied
as visitor
.
- Type Parameters:
P
- The type of visitor-supplied argument. Use Void
for visitors that do not need an additional argument.- Parameters:
visitor
- The visitor; never null.argument
- A context supplied argument, if any.- See Also:
SequenceValueVisitor.visitDateValued(Sequence, Object)
copy
public DateValuedVisitableSequence copy()
- Returns a deep copy of this object.
The decorated sequence is not copied.
- Returns:
- The copy; never null.
Feel free to use and/or modify the Java 6 source code developed for this thesis AT YOUR OWN RISK, but note that the source code comes WITHOUT ANY — and I do mean WITHOUT ANY — form of warranty WHAT SO EVER!
The original thesis and source code are available at rode.dk/thesis.