Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister

Re^2: One to many, many to one relationships

by rvosa (Curate)
on Mar 12, 2007 at 13:26 UTC ( #604347=note: print w/replies, xml ) Need Help??

in reply to Re: One to many, many to one relationships
in thread One to many, many to one relationships

I think the question hinges on when the linkage information first becomes available: is it instrinsically known at the point when an object instance is created, or might it get introduced at some later stage as an update to an existing instance?
It might be introduced later - especially for nodes, which might never be linked to a taxon.

Also, I don't want to/can't change the api such that the link has to be created in the constructor.
If it makes sense that instances of each object type are able to exist independently, without necessarily being linked to one of the other object types, then it would make sense for link creation to be a separate process, which takes a taxon instance and a node or sequence instance, and updates each one by adding a reference to the other. (In the taxon, a reference to a node or sequence would be pushed onto an array of nodes or sequences; in a node or sequence, there can be only one reference to a given taxon.)
Yup, that's what I tend towards. Thanks!
  • Comment on Re^2: One to many, many to one relationships

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://604347]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (3)
As of 2020-11-30 06:10 GMT
Find Nodes?
    Voting Booth?

    No recent polls found