def METHOD_NAME(self):
    tc = CMakeToolchain(self)
    if Version(self.version) < "2.2.0":
        tc.variables["BUILD_TESTS"] = False
        tc.variables["BUILD_EXAMPLES"] = False
    else:
        tc.variables["JSON_VALIDATOR_BUILD_TESTS"] = False
        tc.variables["JSON_VALIDATOR_BUILD_EXAMPLES"] = False
    if self.options.json_diagnostics:
        tc.preprocessor_definitions["JSON_DIAGNOSTICS"] = '1'
    if Version(self.version) < "2.1.0":
        nlohmann_json_includedirs = self.dependencies["nlohmann_json"].cpp_info.aggregated_components().includedirs
        tc.variables["NLOHMANN_JSON_DIR"] = ";".join([p.replace("\\", "/") for p in nlohmann_json_includedirs])
    tc.METHOD_NAME()
    deps = CMakeDeps(self)
    deps.METHOD_NAME()