Class HttpCharset
java.lang.Object
org.apache.pekko.http.javadsl.model.HttpCharset
org.apache.pekko.http.scaladsl.model.HttpCharset
- All Implemented Interfaces:
Serializable
,Renderable
,SingletonValueRenderable
,WithQValue<HttpCharsetRange>
,scala.Equals
,scala.Product
public final class HttpCharset
extends HttpCharset
implements SingletonValueRenderable, WithQValue<HttpCharsetRange>, scala.Product, Serializable
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionscala.collection.immutable.Seq<String>
aliases()
static HttpCharset
static scala.util.Try<Charset>
findNioCharset
(String name) Java APIReturns the Charset for this charset if available or throws an exception otherwisetoRange()
Creates a range from this charset with qValue = 1.value()
Returns the name of this charset.withQValue
(float qValue) An alias for toRange(float).Methods inherited from class org.apache.pekko.http.javadsl.model.HttpCharset
toRange
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface scala.Equals
canEqual, equals
Methods inherited from interface scala.Product
productArity, productElement, productElementName, productElementNames, productIterator, productPrefix
Methods inherited from interface org.apache.pekko.http.impl.util.SingletonValueRenderable
render
Methods inherited from interface org.apache.pekko.http.scaladsl.model.WithQValue
withQValue
-
Constructor Details
-
HttpCharset
-
-
Method Details
-
custom
-
findNioCharset
-
value
Description copied from class:HttpCharset
Returns the name of this charset.- Specified by:
value
in interfaceSingletonValueRenderable
- Specified by:
value
in classHttpCharset
-
aliases
-
nioCharset
Returns the Charset for this charset if available or throws an exception otherwise- Specified by:
nioCharset
in classHttpCharset
-
charsetWithUtf8Failover
- Returns:
- this HttpCharset instance if this charset can be parsed to a
java.nio.charset.Charset
instance, otherwise returns the UTF-8 charset. - Since:
- 1.1.0
-
withQValue
Description copied from class:HttpCharset
An alias for toRange(float).- Specified by:
withQValue
in interfaceWithQValue<HttpCharsetRange>
- Specified by:
withQValue
in classHttpCharset
-
toRange
Description copied from class:HttpCharset
Creates a range from this charset with qValue = 1.- Overrides:
toRange
in classHttpCharset
-
getAliases
Java API- Specified by:
getAliases
in classHttpCharset
-