def METHOD_NAME(result, set_ref, scheduler="credit"):
    """
    Get the value of set_ref.
    :param result: CmdResult struct
    :param set_ref: the parameter has been set
    :param scheduler: the scheduler of xen(default is credit)
    """
    output = result.stdout.strip()
    if not re.search("Scheduler", output):
        test.fail("Output is not standard:\n%s" % output)
    result_lines = output.splitlines()
    set_value = None
    for line in result_lines:
        key_value = line.split(":")
        key = key_value[0].strip()
        value = key_value[1].strip()
        if key == "Scheduler":
            if value != scheduler:
                test.cancel("This test do not support"
                            " %s scheduler." % scheduler)
        elif key == set_ref:
            set_value = value
            break
    return set_value