Class ClientAltSvcConfig.BuilderBase<BUILDER extends ClientAltSvcConfig.BuilderBase<BUILDER, PROTOTYPE>, PROTOTYPE extends ClientAltSvcConfig>
- Type Parameters:
BUILDER- type of the builder extending this abstract builderPROTOTYPE- type of the prototype interface that would be built byPrototype.Builder.buildPrototype()
- All Implemented Interfaces:
Prototype.Builder<BUILDER, PROTOTYPE>, ConfigBuilderSupport.ConfiguredBuilder<BUILDER, PROTOTYPE>
- Direct Known Subclasses:
ClientAltSvcConfig.Builder
- Enclosing interface:
ClientAltSvcConfig
ClientAltSvcConfig.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classGenerated implementation of the prototype, can be extended by descendant prototype implementations. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddProtocol(String protocol) Allowed alternative service protocol identifiers.addProtocols(Set<String> protocols) Allowed alternative service protocol identifiers.Clear all protocols.config()Configuration used to configure this instance.Update builder from configuration (node of this type).booleanenabled()Whether alternative service handling is enabled.enabled(boolean enabled) Whether alternative service handling is enabled.from(ClientAltSvcConfig prototype) Update this builder from an existing prototype instance.from(ClientAltSvcConfig.BuilderBase<?, ?> builder) Update this builder from an existing prototype builder instance.protected voidHandles providers and decorators.Allowed alternative service protocol identifiers.Allowed alternative service protocol identifiers.toString()protected voidValidates required properties.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface Prototype.Builder
buildPrototype, self
-
Constructor Details
-
BuilderBase
protected BuilderBase()Protected to support extensibility.
-
-
Method Details
-
from
Update this builder from an existing prototype instance. This method disables automatic service discovery.- Parameters:
prototype- existing prototype to update this builder from- Returns:
- updated builder instance
-
from
Update this builder from an existing prototype builder instance.- Parameters:
builder- existing builder prototype to update this builder from- Returns:
- updated builder instance
-
config
Update builder from configuration (node of this type). If a value is present in configuration, it would override currently configured values.- Specified by:
configin interfaceConfigBuilderSupport.ConfiguredBuilder<BUILDER extends ClientAltSvcConfig.BuilderBase<BUILDER, PROTOTYPE>, PROTOTYPE extends ClientAltSvcConfig>- Parameters:
config- configuration instance used to obtain values to update this builder- Returns:
- updated builder instance
-
enabled
Whether alternative service handling is enabled.This option defaults to
true. Setting it tofalsedisables alternative service handling even when this configuration is present.- Parameters:
enabled- whether alternative service handling is enabled- Returns:
- updated builder instance
- See Also:
-
clearProtocols
-
protocols
Allowed alternative service protocol identifiers.An empty set permits every available client protocol that supports alternative services. A non-empty set is an exact, case-sensitive allow-list of opaque ALPN protocol identifiers; it is not validated against the protocols currently provided by the client. Each Java character in the range
U+0000throughU+00FFmaps one-to-one to an identifier byte. Each identifier must contain between1and255bytes, inclusive, when this policy is enabled.- Parameters:
protocols- allowed alternative service protocol identifiers- Returns:
- updated builder instance
- See Also:
-
addProtocols
Allowed alternative service protocol identifiers.An empty set permits every available client protocol that supports alternative services. A non-empty set is an exact, case-sensitive allow-list of opaque ALPN protocol identifiers; it is not validated against the protocols currently provided by the client. Each Java character in the range
U+0000throughU+00FFmaps one-to-one to an identifier byte. Each identifier must contain between1and255bytes, inclusive, when this policy is enabled.- Parameters:
protocols- allowed alternative service protocol identifiers- Returns:
- updated builder instance
- See Also:
-
addProtocol
Allowed alternative service protocol identifiers.An empty set permits every available client protocol that supports alternative services. A non-empty set is an exact, case-sensitive allow-list of opaque ALPN protocol identifiers; it is not validated against the protocols currently provided by the client. Each Java character in the range
U+0000throughU+00FFmaps one-to-one to an identifier byte. Each identifier must contain between1and255bytes, inclusive, when this policy is enabled.- Parameters:
protocol- add single allowed alternative service protocol identifiers- Returns:
- updated builder instance
- See Also:
-
enabled
public boolean enabled()Whether alternative service handling is enabled.This option defaults to
true. Setting it tofalsedisables alternative service handling even when this configuration is present.- Returns:
- whether alternative service handling is enabled
-
protocols
Allowed alternative service protocol identifiers.An empty set permits every available client protocol that supports alternative services. A non-empty set is an exact, case-sensitive allow-list of opaque ALPN protocol identifiers; it is not validated against the protocols currently provided by the client. Each Java character in the range
U+0000throughU+00FFmaps one-to-one to an identifier byte. Each identifier must contain between1and255bytes, inclusive, when this policy is enabled.- Returns:
- allowed alternative service protocol identifiers
-
toString
-
preBuildPrototype
protected void preBuildPrototype()Handles providers and decorators. -
validatePrototype
protected void validatePrototype()Validates required properties. -
config
-