[Pipet Devel] locus vs. node naming
Brad Chapman
chapmanb at arches.uga.edu
Sat Apr 1 11:36:31 EST 2000
> Brad Chapman wrote:
>> Can we either use "locus/loci" in the definition layer, or think
>> up a new term that won't clash with DOM so much?
Jeff wrote:
> This is a 'simple' namespace problem, which can usually be solved by
> appending
> the application's name. So, instead of 'node', you can use...
>
> vshnode
Well, I wasn't so worried about the namespace problem as the problem
with clarity of code. For instance, let's take this current snippet o'
code from the middle:
middle_node = dom_tree.createElement('middle')
dom_tree.appendChild(middle_node)
success_node = dom_tree.createElement('success')
middle_node.appendChild(success_node)
locus_node = dom_tree.createElement('locus')
locus_node.setAttribute('id', locus_id)
locus_node.setAttribute('num_inputs', str(num_inputs))
locus_node.setAttribute('num_outputs', str(num_outputs))
locus_node.setAttribute('gui_name', gui_name)
success_node.appendChild(locus_node)
I think you can see the problem if I started referring to a locus as a
dlnode (dlnode_node = ...).
The additional problem is that I am redoing the middle code and am
thinking of organizing the loci structure in a DOM-like manner. Ie.
loci can have parent loci (the container or composite locus holding
them) which will make things additionally confusing. I just want to
see the code be as clear as possible and the node/node stuff is
confusing, IMO.
> BTW, about the BL nodes, I was thinking that since these always have
an
> Internet location, they could be referred to as a node of type
'locus'.
I'm confused by what you are talking about here. Do you mean the 'GMS'
layer?
Brad
More information about the Pipet-Devel
mailing list