Aloha,
the following is unlogical I think.
You are inside of CertiLogicalTime Class this means that getClass()
returns "CertiLogicalTime" and the addend have to be
LogicalTimeInterval, which means that getClass returns
CertiLogicalTimeIntervall which will be always true!
Am I that wrong or is this really a bug?
public void increaseBy(LogicalTimeInterval addend) throws
IllegalTimeArithmetic {
if (getClass() != addend.getClass()) {
throw new IllegalTimeArithmetic("Different implementation of
logical time supplied" + getClass() + addend.getClass());
}
time += ((CertiLogicalTimeInterval) addend).getInterval();
}
regards
Sven
--
CERTI-Devel mailing list