StringResponse class

Response that writes the bytes provided in body to the response.

Inheritance

Constructors

StringResponse({dynamic body, int statusCode = 200, Map<String, dynamic>? headers, String? mimeType, String? charset, List<Cookie>? cookies})
StringResponse.cloneFrom(Response response, {dynamic body, int? statusCode, String? mimeType, String? charset})
factory

Properties

body String?
Body of the response
getter/setter pairinherited
cookies List<Cookie>
Cookies
finalinherited
hashCode int
The hash code for this object.
no setterinherited
headers JaguarHttpHeaders
Headers
finalinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
statusCode int
Status code of the response
getter/setter pairinherited

Methods

deleteCookie(String name, {String path = '/'}) → void
deleteCookie deletes a cookie with given name. Use path to specify the path from which the cookie has to be removed.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited
writeAllButBody(HttpResponse resp) → void
inherited
writeResponse(HttpResponse resp) → void
Writes body of the HTTP response from body property
override

Operators

operator ==(Object other) bool
The equality operator.
inherited