class_docstr: Dict-like container for Extension fields on proto instances.
  
  Note that in all cases we expect extension handles to be
  FieldDescriptors.
class_docstr_tok: ["Dict-like","container","for","Extension","fields","on","proto","instances",".","Note","that","in","all","cases","we","expect","extension","handles","to","be","FieldDescriptors","."]
code: def __contains__(self, extension_handle):
      _VerifyExtensionHandle(self._extended_message, extension_handle)
  
      if extension_handle not in self._extended_message._fields:
          return False
  
      if extension_handle.label == FieldDescriptor.LABEL_REPEATED:
          return bool(
              self._extended_message._fields.get(extension_handle)
          )
  
      if extension_handle.cpp_type == FieldDescriptor.CPPTYPE_MESSAGE:
          value = self._extended_message._fields.get(extension_handle)
          # pylint: disable=protected-access
          return value is not None and value._is_present_in_parent
  
      return True
  
file_path: catboost/contrib/python/protobuf/py2/google/protobuf/internal/extension_dict.py
imports: from google.protobuf.internal import type_checkers
  from google.protobuf.descriptor import FieldDescriptor
label_desc: Use image node_id 12 for calling the _ExtensionDict obj's underlying member method code with example usage: obj.__contains__(extension_handle) and returns: True, False, bool, unknown