def METHOD_NAME(self, filebase):
    caseroot = self.get_value("CASEROOT")
    cfile = os.path.join(caseroot, filebase)
    lfile = os.path.join(caseroot, "LockedFiles", filebase)
    components = self.get_values("COMP_CLASSES")
    if os.path.isfile(cfile):
        objname = filebase.split(".")[0]
        if objname == "env_build":
            f1obj = self.get_env("build")
            f2obj = EnvBuild(caseroot, lfile, read_only=True)
        elif objname == "env_mach_pes":
            f1obj = self.get_env("mach_pes")
            f2obj = EnvMachPes(caseroot, lfile, components=components, read_only=True)
        elif objname == "env_case":
            f1obj = self.get_env("case")
            f2obj = EnvCase(caseroot, lfile, read_only=True)
        elif objname == "env_batch":
            f1obj = self.get_env("batch")
            f2obj = EnvBatch(caseroot, lfile, read_only=True)
        else:
            logging.warning(
                "Locked XML file '{}' is not current being handled".format(filebase)
            )
            return
        diffs = f1obj.compare_xml(f2obj)
        if diffs:
            logging.warning("File {} has been modified".format(lfile))
            toggle_build_status = False
            for key in diffs.keys():
                if key != "BUILD_COMPLETE":
                    logging.warning(
                        "  found difference in {} : case {} locked {}".format(
                            key, repr(diffs[key][0]), repr(diffs[key][1])
                        )
                    )
                    toggle_build_status = True
            if objname == "env_mach_pes":
                expect(False, "Invoke case.setup --reset ")
            elif objname == "env_case":
                expect(
                    False,
                    "Cannot change file env_case.xml, please"
                    " recover the original copy from LockedFiles",
                )
            elif objname == "env_build":
                if toggle_build_status:
                    logging.warning("Setting build complete to False")
                    self.set_value("BUILD_COMPLETE", False)
                    if "PIO_VERSION" in diffs:
                        self.set_value("BUILD_STATUS", 2)
                        logging.critical(
                            "Changing PIO_VERSION requires running "
                            "case.build --clean-all and rebuilding"
                        )
                    else:
                        self.set_value("BUILD_STATUS", 1)
            elif objname == "env_batch":
                expect(
                    False,
                    "Batch configuration has changed, please run case.setup --reset",
                )
            else:
                expect(False, "'{}' diff was not handled".format(objname))