Class CorsConfig.BuilderBase.CorsConfigImpl

java.lang.Object
io.helidon.webserver.cors.CorsConfig.BuilderBase.CorsConfigImpl
All Implemented Interfaces:
Prototype.Api, Prototype.Factory<CorsFeature>, CorsConfig, Supplier<CorsFeature>
Enclosing class:
CorsConfig.BuilderBase<BUILDER extends CorsConfig.BuilderBase<BUILDER,PROTOTYPE>,PROTOTYPE extends CorsConfig>

protected static class CorsConfig.BuilderBase.CorsConfigImpl extends Object implements CorsConfig, Supplier<CorsFeature>
Generated implementation of the prototype, can be extended by descendant prototype implementations.
  • Constructor Details

    • CorsConfigImpl

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

    • build

      public CorsFeature build()
      Description copied from interface: Prototype.Factory
      Create a new instance of the runtime type from this config object.
      Specified by:
      build in interface Prototype.Factory<CorsFeature>
      Returns:
      new configured runtime instance
    • get

      public CorsFeature get()
      Specified by:
      get in interface Supplier<CorsFeature>
    • weight

      public double weight()
      Description copied from interface: CorsConfig
      Weight of the CORS feature. As it is used by other features, the default is quite high: 850.0.
      Specified by:
      weight in interface CorsConfig
      Returns:
      weight of the feature
    • sockets

      public Set<String> sockets()
      Description copied from interface: CorsConfig
      List of sockets to register this feature on. If empty, it would get registered on all sockets.
      Specified by:
      sockets in interface CorsConfig
      Returns:
      socket names to register on, defaults to empty (all available sockets)
    • name

      public String name()
      Description copied from interface: CorsConfig
      Name of this instance.
      Specified by:
      name in interface CorsConfig
      Returns:
      instance name
    • enabled

      public boolean enabled()
      Description copied from interface: CorsConfig
      This feature can be disabled.
      Specified by:
      enabled in interface CorsConfig
      Returns:
      whether the feature is enabled
    • config

      public Optional<Config> config()
      Description copied from interface: CorsConfig
      Access to config that was used to create this feature.
      Specified by:
      config in interface CorsConfig
      Returns:
      configuration
    • 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