I am trying to develop a conceptual model (object-oriented) of GPS-collected data. Usually, common classes are Track
, which represents an ordered sequence of Trackpoints
, and the class Trackpoint
itself, which has properties such as latitude, longitude, elevation, timestamp, speed, accumulated distance, etc.
The fact is: since a Trackpoint
instance only "makes sense" as an item of a Track
(or a Segment
, or a ConnectedSegment
, or other possible similar collection types), the question is:
Is it good/common practice to design a class so that it "behaves" better (or exclusively) as member of a collection? And should I design the collection itself to enforce this?