Package SCons :: Module Environment :: Class BuilderWrapper
[show private | hide private]
[frames | no frames]

Class BuilderWrapper

MethodWrapper --+
                |
               BuilderWrapper


A MethodWrapper subclass that that associates an environment with a Builder.

This mainly exists to wrap the __call__() function so that all calls to Builders can have their argument lists massaged in the same way (treat a lone argument as the source, treat two arguments as target then source, make sure both target and source are lists) without having to have cut-and-paste code to do it.

As a bit of obsessive backwards compatibility, we also intercept attempts to get or set the "env" or "builder" attributes, which were the names we used before we put the common functionality into the MethodWrapper base class. We'll keep this around for a while in case people shipped Tool modules that reached into the wrapper (like the Tool/qt.py module does, or did). There shouldn't be a lot attribute fetching or setting on these, so a little extra work shouldn't hurt.


Method Summary
  __call__(self, target, source, *args, **kw)
  __getattr__(self, name)
  __repr__(self)
  __setattr__(self, name, value)
  __str__(self)
    Inherited from MethodWrapper
  __init__(self, object, method, name)
  clone(self, new_object)
Returns an object that re-binds the underlying "method" to the specified new object.

Generated by Epydoc 2.1 on Wed Dec 12 09:39:31 2007 http://epydoc.sf.net