java.lang.Object
io.confluent.kafka.schemaregistry.rules.cel.avro.AvroRegistry
All Implemented Interfaces:
org.projectnessie.cel.common.types.ref.TypeAdapter, org.projectnessie.cel.common.types.ref.TypeProvider, org.projectnessie.cel.common.types.ref.TypeRegistry

public final class AvroRegistry extends Object implements org.projectnessie.cel.common.types.ref.TypeRegistry
CEL-Java TypeRegistry to use Avro objects as input values for CEL scripts.

The implementation does not support the construction of Avro objects in CEL expressions and therefore returning Avro objects from CEL expressions is not possible/implemented and results in UnsupportedOperationExceptions.

  • Method Details

    • newRegistry

      public static org.projectnessie.cel.common.types.ref.TypeRegistry newRegistry()
    • copy

      public org.projectnessie.cel.common.types.ref.TypeRegistry copy()
      Specified by:
      copy in interface org.projectnessie.cel.common.types.ref.TypeRegistry
    • register

      public void register(Object t)
      Specified by:
      register in interface org.projectnessie.cel.common.types.ref.TypeRegistry
    • registerType

      public void registerType(org.projectnessie.cel.common.types.ref.Type... types)
      Specified by:
      registerType in interface org.projectnessie.cel.common.types.ref.TypeRegistry
    • enumValue

      public org.projectnessie.cel.common.types.ref.Val enumValue(String enumName)
      Specified by:
      enumValue in interface org.projectnessie.cel.common.types.ref.TypeProvider
    • findIdent

      public org.projectnessie.cel.common.types.ref.Val findIdent(String identName)
      Specified by:
      findIdent in interface org.projectnessie.cel.common.types.ref.TypeProvider
    • findType

      public com.google.api.expr.v1alpha1.Type findType(String typeName)
      Specified by:
      findType in interface org.projectnessie.cel.common.types.ref.TypeProvider
    • findFieldType

      public org.projectnessie.cel.common.types.ref.FieldType findFieldType(String messageType, String fieldName)
      Specified by:
      findFieldType in interface org.projectnessie.cel.common.types.ref.TypeProvider
    • newValue

      public org.projectnessie.cel.common.types.ref.Val newValue(String typeName, Map<String,org.projectnessie.cel.common.types.ref.Val> fields)
      Specified by:
      newValue in interface org.projectnessie.cel.common.types.ref.TypeProvider
    • nativeToValue

      public org.projectnessie.cel.common.types.ref.Val nativeToValue(Object value)
      Specified by:
      nativeToValue in interface org.projectnessie.cel.common.types.ref.TypeAdapter