- java.lang.Object
-
- io.netty5.util.DomainMappingBuilder<V>
-
- Type Parameters:
V- concrete type of value objects
@Deprecated public final class DomainMappingBuilder<V> extends Object
Deprecated.UseDomainWildcardMappingBuilderinstead.Builder for immutableDomainNameMappinginstances.
-
-
Constructor Summary
Constructors Constructor Description DomainMappingBuilder(int initialCapacity, V defaultValue)Deprecated.Constructor with initial capacity of the map holding the mappingsDomainMappingBuilder(V defaultValue)Deprecated.Constructor with default initial capacity of the map holding the mappings
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description DomainMappingBuilder<V>add(String hostname, V output)Deprecated.Adds a mapping that maps the specified (optionally wildcard) host name to the specified output value.DomainNameMapping<V>build()Deprecated.Creates a new instance of immutableDomainNameMappingAttempts to add new mappings to the result object will causeUnsupportedOperationExceptionto be thrown
-
-
-
Constructor Detail
-
DomainMappingBuilder
public DomainMappingBuilder(V defaultValue)
Deprecated.Constructor with default initial capacity of the map holding the mappings- Parameters:
defaultValue- the default value forDomainNameMapping.map(String)to return when nothing matches the input
-
DomainMappingBuilder
public DomainMappingBuilder(int initialCapacity, V defaultValue)Deprecated.Constructor with initial capacity of the map holding the mappings- Parameters:
initialCapacity- initial capacity for the internal mapdefaultValue- the default value forDomainNameMapping.map(String)to return when nothing matches the input
-
-
Method Detail
-
add
public DomainMappingBuilder<V> add(String hostname, V output)
Deprecated.Adds a mapping that maps the specified (optionally wildcard) host name to the specified output value. Null values are forbidden for both hostnames and values.DNS wildcard is supported as hostname. For example, you can use
*.netty.ioto matchnetty.ioanddownloads.netty.io.- Parameters:
hostname- the host name (optionally wildcard)output- the output value that will be returned byDomainNameMapping.map(String)when the specified host name matches the specified input host name
-
build
public DomainNameMapping<V> build()
Deprecated.Creates a new instance of immutableDomainNameMappingAttempts to add new mappings to the result object will causeUnsupportedOperationExceptionto be thrown- Returns:
- new
DomainNameMappinginstance
-
-