def _valueForName(obj, name, executeCallables=False):
    nameChunks=name.split('.')
    for i in range(len(nameChunks)):
        key = nameChunks[i]
        if hasattr(obj, 'has_key') and key in obj:
            nextObj = obj[key]
        else:
            try:
                nextObj = getattr(obj, key)
            except __HOLE__:
                _raiseNotFoundException(key, obj)

        if executeCallables and hasattr(nextObj, '__call__') and not _isInstanceOrClass(nextObj):
            obj = nextObj()
        else:
            obj = nextObj
    return obj
dataset/ETHPy150Open binhex/moviegrabber/lib/site-packages/Cheetah/NameMapper.py/_valueForName