MCPcopy Create free account
hub / github.com/apache/fory / get_field_identifier

Method get_field_identifier

compiler/fory_compiler/generators/rust.py:183–188  ·  view source on GitHub ↗

Get the sanitized field name within one message from the cache.

(self, message: Message, field: Field)

Source from the content-addressed store, hash-verified

181 return self._module_identifier_cache[self._cache_key(message)]
182
183 def get_field_identifier(self, message: Message, field: Field) -> str:
184 """Get the sanitized field name within one message from the cache."""
185 self._ensure_name_caches(self._schema_for_node(message))
186 return self._field_identifier_cache[self._cache_key(message)][
187 self._cache_key(field)
188 ]
189
190 def get_union_case_identifier(self, union: Union, field: Field) -> str:
191 """Get the sanitized variant name for one union case from the cache"""

Callers 2

generate_debug_implMethod · 0.95
generate_fieldMethod · 0.95

Calls 3

_ensure_name_cachesMethod · 0.95
_schema_for_nodeMethod · 0.95
_cache_keyMethod · 0.95

Tested by

no test coverage detected