Class DefaultDescriptorPool

  • All Implemented Interfaces:
    CelDescriptorPool

    @Immutable
    @Internal
    public final class DefaultDescriptorPool
    extends java.lang.Object
    implements CelDescriptorPool
    A descriptor pool that has descriptors pre-loaded for well-known types defined by WellKnownProto.

    CEL Library Internals. Do Not Use.

    • Field Detail

      • INSTANCE

        public static final DefaultDescriptorPool INSTANCE
        A DefaultDescriptorPool instance with just well known types loaded.
    • Method Detail

      • getWellKnownProtoDescriptor

        public static com.google.protobuf.Descriptors.Descriptor getWellKnownProtoDescriptor​(WellKnownProto wellKnownProto)
      • findDescriptor

        public java.util.Optional<com.google.protobuf.Descriptors.Descriptor> findDescriptor​(java.lang.String name)
        Description copied from interface: CelDescriptorPool
        Finds the descriptor by fully qualified message type.
        Specified by:
        findDescriptor in interface CelDescriptorPool
      • findExtensionDescriptor

        public java.util.Optional<com.google.protobuf.Descriptors.FieldDescriptor> findExtensionDescriptor​(com.google.protobuf.Descriptors.Descriptor containingDescriptor,
                                                                                                           java.lang.String fieldName)
        Description copied from interface: CelDescriptorPool
        Finds the corresponding field descriptor for an extension field on a message. The field name must be fully-qualified.
        Specified by:
        findExtensionDescriptor in interface CelDescriptorPool
      • getExtensionRegistry

        public com.google.protobuf.ExtensionRegistry getExtensionRegistry()
        Description copied from interface: CelDescriptorPool
        Retrieves the registered extension registry. This is specifically needed to handle unpacking Any messages containing Proto2 extension messages.
        Specified by:
        getExtensionRegistry in interface CelDescriptorPool