def METHOD_NAME(self):
    if self.settings.compiler.get_safe("cppstd"):
        check_min_cppstd(self, self._min_cppstd)
    minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False)
    if minimum_version and Version(self.settings.compiler.version) < minimum_version:
        raise ConanInvalidConfiguration(
            f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support."
        )
    if Version(self.version) == "0.17.0" and Version(self.settings.compiler.get_safe("cppstd")) > "17":
        raise ConanInvalidConfiguration(f"{self.ref} does not support C++{self.settings.compiler.cppstd}")
    if hasattr(self, "settings_build") and cross_building(self, skip_x64_x86=True):
        raise ConanInvalidConfiguration(f"{self.ref} does not support cross building")
    if self.options.shared and is_msvc(self) and "d" in msvc_runtime_flag(self):
        raise ConanInvalidConfiguration(f"shared {self.ref} is not supported with MTd/MDd runtime")
    # This is a workround.
    # If jsonnet is shared, rapidyaml must be built as shared,
    # or the c4core functions that rapidyaml depends on will not be able to be found.
    # This seems to be a issue of rapidyaml.
    # https://github.com/conan-io/conan-center-index/pull/9786#discussion_r829887879
    if self.options.shared and Version(self.version) >= "0.18.0" and self.dependencies["rapidyaml"].options.shared == False:
        raise ConanInvalidConfiguration(f"shared {self.ref} requires rapidyaml to be built as shared")