Class DefaultHttp3Headers
java.lang.Object
io.netty.handler.codec.DefaultHeaders<CharSequence, CharSequence, Http3Headers>
io.netty.handler.codec.http3.DefaultHttp3Headers
- All Implemented Interfaces:
Headers<CharSequence, CharSequence, Http3Headers>, Http3Headers, Iterable<Map.Entry<CharSequence, CharSequence>>
public final class DefaultHttp3Headers
extends DefaultHeaders<CharSequence, CharSequence, Http3Headers>
implements Http3Headers
-
Nested Class Summary
Nested classes/interfaces inherited from class DefaultHeaders
DefaultHeaders.HeaderEntry<K,V>, DefaultHeaders.NameValidator<K>, DefaultHeaders.ValueValidator<V> Nested classes/interfaces inherited from interface Http3Headers
Http3Headers.PseudoHeaderName -
Field Summary
Fields inherited from class DefaultHeaders
head -
Constructor Summary
ConstructorsConstructorDescriptionCreate a new instance.DefaultHttp3Headers(boolean validate) Create a new instance.DefaultHttp3Headers(boolean validate, int arraySizeHint) Create a new instance. -
Method Summary
Modifier and TypeMethodDescriptionGets theHttp3Headers.PseudoHeaderName.AUTHORITYheader ornullif there is no such headerauthority(CharSequence value) Sets theHttp3Headers.PseudoHeaderName.AUTHORITYheaderclear()Removes all headers.booleancontains(CharSequence name, CharSequence value) Returnstrueif a header with thenameandvalueexists,falseotherwise.booleancontains(CharSequence name, CharSequence value, boolean caseInsensitive) Returnstrueif a header with thenameandvalueexists,falseotherwise.booleaninthashCode()method()Gets theHttp3Headers.PseudoHeaderName.METHODheader ornullif there is no such headermethod(CharSequence value) Sets theHttp3Headers.PseudoHeaderName.METHODheaderprotected DefaultHeaders.HeaderEntry<CharSequence, CharSequence> newHeaderEntry(int h, CharSequence name, CharSequence value, DefaultHeaders.HeaderEntry<CharSequence, CharSequence> next) path()Gets theHttp3Headers.PseudoHeaderName.PATHheader ornullif there is no such headerpath(CharSequence value) Sets theHttp3Headers.PseudoHeaderName.PATHheaderscheme()Gets theHttp3Headers.PseudoHeaderName.SCHEMEheader ornullif there is no such headerscheme(CharSequence value) Sets theHttp3Headers.PseudoHeaderName.SCHEMEheaderstatus()Gets theHttp3Headers.PseudoHeaderName.STATUSheader ornullif there is no such headerstatus(CharSequence value) Sets theHttp3Headers.PseudoHeaderName.STATUSheaderMethods inherited from class DefaultHeaders
add, add, add, add, addBoolean, addByte, addChar, addDouble, addFloat, addImpl, addInt, addLong, addObject, addObject, addObject, addShort, addTimeMillis, contains, contains, containsBoolean, containsByte, containsChar, containsDouble, containsFloat, containsInt, containsLong, containsObject, containsShort, containsTimeMillis, copy, equals, get, get, getAll, getAllAndRemove, getAndRemove, getAndRemove, getBoolean, getBoolean, getBooleanAndRemove, getBooleanAndRemove, getByte, getByte, getByteAndRemove, getByteAndRemove, getChar, getChar, getCharAndRemove, getCharAndRemove, getDouble, getDouble, getDoubleAndRemove, getDoubleAndRemove, getFloat, getFloat, getFloatAndRemove, getFloatAndRemove, getInt, getInt, getIntAndRemove, getIntAndRemove, getLong, getLong, getLongAndRemove, getLongAndRemove, getShort, getShort, getShortAndRemove, getShortAndRemove, getTimeMillis, getTimeMillis, getTimeMillisAndRemove, getTimeMillisAndRemove, hashCode, isEmpty, iterator, names, nameValidator, remove, set, set, set, set, setAll, setBoolean, setByte, setChar, setDouble, setFloat, setInt, setLong, setObject, setObject, setObject, setShort, setTimeMillis, size, toString, validateName, validateValue, valueConverter, valueIterator, valueValidatorMethods inherited from interface Headers
add, add, add, add, addBoolean, addByte, addChar, addDouble, addFloat, addInt, addLong, addObject, addObject, addObject, addShort, addTimeMillis, contains, containsBoolean, containsByte, containsChar, containsDouble, containsFloat, containsInt, containsLong, containsObject, containsShort, containsTimeMillis, get, get, getAll, getAllAndRemove, getAndRemove, getAndRemove, getBoolean, getBoolean, getBooleanAndRemove, getBooleanAndRemove, getByte, getByte, getByteAndRemove, getByteAndRemove, getChar, getChar, getCharAndRemove, getCharAndRemove, getDouble, getDouble, getDoubleAndRemove, getDoubleAndRemove, getFloat, getFloat, getFloatAndRemove, getFloatAndRemove, getInt, getInt, getIntAndRemove, getIntAndRemove, getLong, getLong, getLongAndRemove, getLongAndRemove, getShort, getShort, getShortAndRemove, getShortAndRemove, getTimeMillis, getTimeMillis, getTimeMillisAndRemove, getTimeMillisAndRemove, isEmpty, names, remove, set, set, set, set, setAll, setBoolean, setByte, setChar, setDouble, setFloat, setInt, setLong, setObject, setObject, setObject, setShort, setTimeMillis, sizeMethods inherited from interface Http3Headers
iterator, protocol, protocol, valueIteratorMethods inherited from interface Iterable
forEach, spliterator
-
Constructor Details
-
DefaultHttp3Headers
public DefaultHttp3Headers()Create a new instance.Header names will be validated according to rfc7540.
-
DefaultHttp3Headers
public DefaultHttp3Headers(boolean validate) Create a new instance.- Parameters:
validate-trueto validate header names according to rfc7540.falseto not validate header names.
-
DefaultHttp3Headers
public DefaultHttp3Headers(boolean validate, int arraySizeHint) Create a new instance.- Parameters:
validate-trueto validate header names according to rfc7540.falseto not validate header names.arraySizeHint- A hint as to how large the hash data structure should be. The next positive power of two will be used. An upper bound may be enforced.
-
-
Method Details
-
clear
Description copied from interface:HeadersRemoves all headers. After a call to this methodHeaders.size()equals0.- Specified by:
clearin interfaceHeaders<CharSequence, CharSequence, Http3Headers>- Overrides:
clearin classDefaultHeaders<CharSequence, CharSequence, Http3Headers>- Returns:
this
-
equals
- Overrides:
equalsin classDefaultHeaders<CharSequence, CharSequence, Http3Headers>
-
hashCode
public int hashCode()- Overrides:
hashCodein classDefaultHeaders<CharSequence, CharSequence, Http3Headers>
-
method
Description copied from interface:Http3HeadersSets theHttp3Headers.PseudoHeaderName.METHODheader- Specified by:
methodin interfaceHttp3Headers- Parameters:
value- the value for the header.- Returns:
- this instance itself.
-
scheme
Description copied from interface:Http3HeadersSets theHttp3Headers.PseudoHeaderName.SCHEMEheader- Specified by:
schemein interfaceHttp3Headers- Parameters:
value- the value for the header.- Returns:
- this instance itself.
-
authority
Description copied from interface:Http3HeadersSets theHttp3Headers.PseudoHeaderName.AUTHORITYheader- Specified by:
authorityin interfaceHttp3Headers- Parameters:
value- the value for the header.- Returns:
- this instance itself.
-
path
Description copied from interface:Http3HeadersSets theHttp3Headers.PseudoHeaderName.PATHheader- Specified by:
pathin interfaceHttp3Headers- Parameters:
value- the value for the header.- Returns:
- this instance itself.
-
status
Description copied from interface:Http3HeadersSets theHttp3Headers.PseudoHeaderName.STATUSheader- Specified by:
statusin interfaceHttp3Headers- Parameters:
value- the value for the header.- Returns:
- this instance itself.
-
method
Description copied from interface:Http3HeadersGets theHttp3Headers.PseudoHeaderName.METHODheader ornullif there is no such header- Specified by:
methodin interfaceHttp3Headers- Returns:
- the value of the header.
-
scheme
Description copied from interface:Http3HeadersGets theHttp3Headers.PseudoHeaderName.SCHEMEheader ornullif there is no such header- Specified by:
schemein interfaceHttp3Headers- Returns:
- the value of the header.
-
authority
Description copied from interface:Http3HeadersGets theHttp3Headers.PseudoHeaderName.AUTHORITYheader ornullif there is no such header- Specified by:
authorityin interfaceHttp3Headers- Returns:
- the value of the header.
-
path
Description copied from interface:Http3HeadersGets theHttp3Headers.PseudoHeaderName.PATHheader ornullif there is no such header- Specified by:
pathin interfaceHttp3Headers- Returns:
- the value of the header.
-
status
Description copied from interface:Http3HeadersGets theHttp3Headers.PseudoHeaderName.STATUSheader ornullif there is no such header- Specified by:
statusin interfaceHttp3Headers- Returns:
- the value of the header.
-
contains
Description copied from interface:HeadersReturnstrueif a header with thenameandvalueexists,falseotherwise.The
Object.equals(Object)method is used to test for equality ofvalue.- Specified by:
containsin interfaceHeaders<CharSequence, CharSequence, Http3Headers>- Overrides:
containsin classDefaultHeaders<CharSequence, CharSequence, Http3Headers>- Parameters:
name- the header namevalue- the header value of the header to find
-
contains
Description copied from interface:Http3HeadersReturnstrueif a header with thenameandvalueexists,falseotherwise.If
caseInsensitiveistruethen a case insensitive compare is done on the value.- Specified by:
containsin interfaceHttp3Headers- Parameters:
name- the name of the header to findvalue- the value of the header to findcaseInsensitive-truethen a case insensitive compare is run to compare values. otherwise a case sensitive compare is run to compare values.- Returns:
trueif its contained,falseotherwise.
-
newHeaderEntry
protected DefaultHeaders.HeaderEntry<CharSequence, CharSequence> newHeaderEntry(int h, CharSequence name, CharSequence value, DefaultHeaders.HeaderEntry<CharSequence, CharSequence> next) - Overrides:
newHeaderEntryin classDefaultHeaders<CharSequence, CharSequence, Http3Headers>
-