Class Header
java.lang.Object
com.azure.core.util.Header
- Direct Known Subclasses:
HttpHeader
-
Constructor Summary
ConstructorsConstructorDescriptionCreate a Header instance using the provided name and value.Create a Header instance using the provided name and values.Create a Header instance using the provided name and values. -
Method Summary
Modifier and TypeMethodDescriptionvoidAdd a new value to the end of the Header.getName()Gets the header name.getValue()Gets the combined, comma-separated value of thisHeader, taking into account all values provided.String[]Gets the comma separated value as an array.Returns all values associated with this header, represented as an unmodifiable list of strings.toString()Gets the String representation of the header.
-
Constructor Details
-
Header
Create a Header instance using the provided name and value.- Parameters:
name- the name of the header.value- the value of the header.- Throws:
NullPointerException- ifnameis null.
-
Header
Create a Header instance using the provided name and values.- Parameters:
name- the name of the header.values- the values of the header.- Throws:
NullPointerException- ifnameis null.
-
Header
Create a Header instance using the provided name and values.- Parameters:
name- the name of the header.values- the values of the header.- Throws:
NullPointerException- ifnameis null.
-
-
Method Details
-
getName
-
getValue
-
getValues
-
getValuesList
-
addValue
Add a new value to the end of the Header.- Parameters:
value- the value to add
-
toString
-