The key line is line 23 where we have the constructor call s(oc) for the set to which we pass oc, this then makes it possible to
inform the origin comp constructor of the "origin" (state). The existence of this constructor form I was not aware of.
The key line is line 23 where we have the constructor call s(oc) for the set to which we pass oc, this then makes it possible to
inform the origin comp constructor of the "origin" (state). The existence of this constructor form I was not aware of.
Yes, i know, now i am synchronizedsorry for insisted on initializing objects, i didn't understood your problem.
Just a little OOP comment, shouldn't your origine point be a member of your class, i don't like the idea of a "dangling" thing be passed as parameter, because you don't need many origine points, or not know the origine point until run-time, or do you? (i mean the origin stays constant?)
For double, like in example, functor is the way to pass that origine (if is anythig about 0.0), but since you in your project build a class, i think you should encapsulate origine in your class (even if you use functor for comparison).
Bookmarks