Please report new issues athttps://github.com/DOCGroup
Time Service, I find that the overlaps() method for TIO (Time Interval Object) does not correctly report the overlap type "OTContainer". I created a scenario like this: Time_intervals -- fixed_int: <------------------------------> first_int: <----------> UTO_curr = _timeServer->universal_time(); CosTime::UTO_ptr UTO_end = _timeServer->new_universal_time(UTO_curr->time() + 9999999, inaccuracy, tdf); CosTime::TIO_ptr fixed_int = UTO_curr->time_to_interval(UTO_end); // Creating first_int interval CosTime::UTO_ptr UTO_start = _timeServer->new_universal_time(UTO_curr->time() + 10000, inaccuracy, tdf); UTO_end = _timeServer->new_universal_time(UTO_curr->time() + 100000, inaccuracy, tdf); CosTime::TIO_ptr first_int = UTO_start->time_to_interval(UTO_end); printOTtype(first_int->overlaps(fixed_int, dummy)); ==> OTContained printOTtype(fixed_int->overlaps(first_int, dummy)); ==> OTContained (wrong!) void printOTtype(CosTime::OverlapType ltype) { switch (ltype) { case CosTime::OTContainer: cout << "OTContainer" << endl; break; case CosTime::OTContained: cout << "OTContained" << endl; break; case CosTime::OTOverlap: cout << "OTOverlap" << endl; break; case CosTime::OTNoOverlap: cout << "OTNoOverlap" << endl; break; default: break; cout << "Indeterministic" << endl; } }
It looks as if the TAO_TIO::spans() method also returns an incorrect overlap type instead of "OTContainer". (A cut and paste error?!?!)
Reassigned bug to tao-support placeholder.
Accepted on behalf of tao-support.