Record Class HarRequest
java.lang.Object
java.lang.Record
de.sstoehr.harreader.model.HarRequest
public record HarRequest(@Nullable String method, @Nullable String url, @Nullable String httpVersion, @Nonnull List<HarCookie> cookies, @Nonnull List<HarHeader> headers, @Nonnull List<HarQueryParam> queryString, @Nonnull HarPostData postData, @Nonnull Long headersSize, @Nonnull Long bodySize, @Nullable String comment, @Nonnull Map<String,Object> additional)
extends Record
Information about a performed request.
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionHarRequest(String method, String url, String httpVersion, List<HarCookie> cookies, List<HarHeader> headers, List<HarQueryParam> queryString, HarPostData postData, Long headersSize, Long bodySize, String comment, Map<String, Object> additional) Creates an instance of aHarRequestrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theadditionalrecord component.bodySize()Returns the value of thebodySizerecord component.comment()Returns the value of thecommentrecord component.cookies()Returns the value of thecookiesrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.headers()Returns the value of theheadersrecord component.Returns the value of theheadersSizerecord component.Returns the value of thehttpVersionrecord component.method()Returns the value of themethodrecord component.postData()Returns the value of thepostDatarecord component.Returns the value of thequeryStringrecord component.voidsetAdditionalField(String key, Object value) final StringtoString()Returns a string representation of this record class.url()Returns the value of theurlrecord component.
-
Field Details
-
DEFAULT_SIZE
-
-
Constructor Details
-
HarRequest
public HarRequest() -
HarRequest
public HarRequest(@Nullable String method, @Nullable String url, @Nullable String httpVersion, @Nullable List<HarCookie> cookies, @Nullable List<HarHeader> headers, @Nullable List<HarQueryParam> queryString, @Nullable HarPostData postData, @Nullable Long headersSize, @Nullable Long bodySize, @Nullable String comment, @Nullable Map<String, Object> additional) Creates an instance of aHarRequestrecord class.- Parameters:
method- the value for themethodrecord componenturl- the value for theurlrecord componenthttpVersion- the value for thehttpVersionrecord componentcookies- the value for thecookiesrecord componentheaders- the value for theheadersrecord componentqueryString- the value for thequeryStringrecord componentpostData- the value for thepostDatarecord componentheadersSize- the value for theheadersSizerecord componentbodySize- the value for thebodySizerecord componentcomment- the value for thecommentrecord componentadditional- the value for theadditionalrecord component
-
-
Method Details
-
httpMethod
-
additional
-
setAdditionalField
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
method
Returns the value of themethodrecord component.- Returns:
- the value of the
methodrecord component
-
url
Returns the value of theurlrecord component.- Returns:
- the value of the
urlrecord component
-
httpVersion
Returns the value of thehttpVersionrecord component.- Returns:
- the value of the
httpVersionrecord component
-
cookies
-
headers
-
queryString
Returns the value of thequeryStringrecord component.- Returns:
- the value of the
queryStringrecord component
-
postData
Returns the value of thepostDatarecord component.- Returns:
- the value of the
postDatarecord component
-
headersSize
Returns the value of theheadersSizerecord component.- Returns:
- the value of the
headersSizerecord component
-
bodySize
Returns the value of thebodySizerecord component.- Returns:
- the value of the
bodySizerecord component
-
comment
Returns the value of thecommentrecord component.- Returns:
- the value of the
commentrecord component
-