Class Message<H extends MessageHeaders, B>
java.lang.Object
org.apache.hc.core5.http.Message<H,B>
- Type Parameters:
H- message head type.B- message body type.
Generic message consisting of a message head and a message body.
- Since:
- 5.0
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbody()Gets the message body.error()static <H extends MessageHeaders, B>
Message<H, B> Create a new message with the given head and error.getBody()Gets the message body.getHead()Gets the message head.head()Gets the message head.static <H extends MessageHeaders, B>
Message<H, B> of(H head, B body) Create a new message with the given head and body, and no error.toString()
-
Field Details
-
head
-
body
-
error
-
-
Constructor Details
-
Message
-
Message
-
Message
-
-
Method Details
-
of
Create a new message with the given head and body, and no error.- Parameters:
head- The message head.body- The message body.- Since:
- 5.5
-
error
Create a new message with the given head and error.- Parameters:
head- The message head.error- The untyped object containing error details.- Since:
- 5.5
-
head
-
getHead
-
body
-
getBody
-
error
- Since:
- 5.5
-
toString
-