def AddEnumDescriptor(self, enum_desc):

    if not isinstance(enum_desc, descriptor.EnumDescriptor):
      raise TypeError('Expected instance of descriptor.EnumDescriptor.')

    self._enum_descriptors[enum_desc.full_name] = enum_desc
    self.AddFileDescriptor(enum_desc.file)
Adds an EnumDescriptor to the pool.
dataset/ETHPy150Open sklearn-theano/sklearn-theano/sklearn_theano/externals/google/protobuf/descriptor_pool.py/DescriptorPool.AddEnumDescriptor