def _is_parameter_for(name, container, docmap):
    """
    @rtype: C{boolean}
    @return: True if C{name} is the name of a parameter for the
    routine C{container}, given the DocMap C{docmap}.
    """
    if docmap is None or not docmap.has_key(container): return 0
    container_doc = docmap.get(container)
    if container.is_routine():
        for param in container_doc.parameter_list():
            if param.name() == name: return 1
    return 0