11 from .D3PDObject
import D3PDObject
12 from AthenaConfiguration.ComponentFactory
import CompFactory
14 D3PD = CompFactory.D3PD
23 """Helper for setting up an association to a set of contained objects.
25 parent: The parent D3PDobject or block.
26 assoctool: The class for the (single) association tool.
27 prefix: Prefix to add to the contained variables, if any.
28 level: Level of detail for the block.
29 blockname: Name for the block.
31 Extra arguments are passed to the association tool.
34 blockname = assoctool.__name__
36 def maker (name, prefix, object_name, **kw2):
37 assoc = assoctool (name +
'Assoc', **kw2)
39 (name, Prefix = prefix, Associator = assoc)
41 obj = D3PDObject (maker, prefix)
42 parent.defineBlock (level, blockname, obj, **kw)