Class ContextRecordConfig.BuilderBase.ContextRecordConfigImpl

java.lang.Object
io.helidon.common.context.http.ContextRecordConfig.BuilderBase.ContextRecordConfigImpl
All Implemented Interfaces:
Prototype.Api, ContextRecordConfig
Enclosing class:
ContextRecordConfig.BuilderBase<BUILDER extends ContextRecordConfig.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends ContextRecordConfig>

protected static class ContextRecordConfig.BuilderBase.ContextRecordConfigImpl extends Object implements ContextRecordConfig
Generated implementation of the prototype, can be extended by descendant prototype implementations.
  • Constructor Details

    • ContextRecordConfigImpl

      protected ContextRecordConfigImpl(ContextRecordConfig.BuilderBase<?,?> builder)
      Create an instance providing a builder.
      Parameters:
      builder - extending builder base of this prototype
  • Method Details

    • header

      public HeaderName header()
      Description copied from interface: ContextRecordConfig
      Name of the header to use when sending the context value over the network.
      Specified by:
      header in interface ContextRecordConfig
      Returns:
      header name
    • classifier

      public Optional<String> classifier()
      Description copied from interface: ContextRecordConfig
      String classifier of the value that will be used with Context.get(Object, Class).
      Specified by:
      classifier in interface ContextRecordConfig
      Returns:
      classifier to use, defaults to header name
    • defaultValue

      public Optional<String> defaultValue()
      Description copied from interface: ContextRecordConfig
      Default value to send if not configured in context.
      Specified by:
      defaultValue in interface ContextRecordConfig
      Returns:
      default value, used for non-array records, or when only a single value is desired as a default for array
    • defaultValues

      public List<String> defaultValues()
      Description copied from interface: ContextRecordConfig
      Default values to send if not configured in context. In case default values is an empty array, it will not be sent over the network if not present in context.
      Specified by:
      defaultValues in interface ContextRecordConfig
      Returns:
      default values, used for array records; if this record is not an array, only the first value will be used
    • array

      public boolean array()
      Description copied from interface: ContextRecordConfig
      Whether to treat the option as an array of strings. This would be read from the context as an array.
      Specified by:
      array in interface ContextRecordConfig
      Returns:
      whether the record is an array
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

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

      public int hashCode()
      Overrides:
      hashCode in class Object