import fnmatch


def getGlobValue(globs, path):
    """ Returns the value of the glob, where path matches

        @param globs: The glob list (C{[(glob, associated value)]})
        @type globs: C{list} of C{tuple}

        @param path: The path to match
        @type path: C{str}

        @return: The matched value or C{None}
        @rtype: any
    """

    result = None
    for glob in globs:
        if fnmatch.fnmatchcase(path, glob[0]):
            result = glob[1]
            break

    return result