Class RuleContext.FieldContext

java.lang.Object
io.confluent.kafka.schemaregistry.rules.RuleContext.FieldContext
All Implemented Interfaces:
AutoCloseable
Enclosing class:
RuleContext

public class RuleContext.FieldContext extends Object implements AutoCloseable
  • Constructor Details

  • Method Details

    • getContainingMessage

      public Object getContainingMessage()
    • getFullName

      public String getFullName()
    • getName

      public String getName()
    • getFieldDescriptor

      public Object getFieldDescriptor()
      The producer's own handle on the field, for formats that have one: a protobuf FieldDescriptor. Null for Avro and JSON Schema, whose walks carry no such object.

      getName() and getFullName() are the registered schema's names for the field, which can differ from the producer's under a compatible rename, and RuleContext.Type collapses distinctions the format makes — a uint64 and an int64 both arrive as RuleContext.Type.LONG, and Java has no unsigned primitive to carry the difference in the value either. An executor that has to present the value faithfully therefore goes through this rather than re-deriving the field from a name.

    • getType

      public RuleContext.Type getType()
    • setType

      public void setType(RuleContext.Type type)
    • isInCombined

      public boolean isInCombined()
    • getTags

      public Set<String> getTags()
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable