MockHttpHeaders class

Implemented types

Constructors

MockHttpHeaders()

Properties

chunkedTransferEncoding bool
Whether the connection uses chunked transfer encoding.
getter/setter pairinherited
contentLength int
The value of the contentLengthHeader header, if any.
getter/setter pairinherited
contentType ContentType?
The ContentType of the contentTypeHeader header, if any.
getter/setter pairinherited
date DateTime?
The date specified by the dateHeader header, if any.
getter/setter pairinherited
expires DateTime?
The date and time specified by the expiresHeader header, if any.
getter/setter pairinherited
hashCode int
The hash code for this object.
no setterinherited
host String?
The value of the hostHeader header, if any.
getter/setter pairinherited
ifModifiedSince DateTime?
The date and time specified by the ifModifiedSinceHeader header, if any.
getter/setter pairinherited
persistentConnection bool
Whether the connection is persistent (keep-alive).
getter/setter pairinherited
port int?
The value of the port part of the hostHeader header, if any.
getter/setter pairinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

add(String name, Object value, {bool preserveHeaderCase = false}) → void
Adds a header value.
inherited
clear() → void
Removes all headers.
inherited
forEach(void action(String name, List<String> values)) → void
Performs the action on each header.
inherited
noFolding(String name) → void
Disables folding for the header named name when sending the HTTP header.
inherited
noSuchMethod(Invocation invocation, {Object? returnValue, Object? returnValueForMissingStub = deferToDefaultResponse}) → dynamic
Handles method stubbing, method call verification, and real method calls.
inherited
remove(String name, Object value) → void
Removes a specific value for a header name.
inherited
removeAll(String name) → void
Removes all values for the specified header name.
inherited
set(String name, Object value, {bool preserveHeaderCase = false}) → void
Sets the header name to value.
inherited
toString() String
A string representation of this object.
inherited
value(String name) String?
Convenience method for the value for a single valued header.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited
operator [](String name) List<String>?
The values for the header named name.
inherited