@@ -14,14 +14,16 @@ * file. */ #import "OFStream.h" #import "OFHTTPRequest.h" +#import "OFHTTPCookie.h" OF_ASSUME_NONNULL_BEGIN @class OFDictionary OF_GENERIC(KeyType, ObjectType); +@class OFArray OF_GENERIC(ObjectType); /*! * @class OFHTTPResponse OFHTTPResponse.h ObjFW/OFHTTPResponse.h * * @brief A class for representing an HTTP request reply as a stream. @@ -29,10 +31,11 @@ @interface OFHTTPResponse: OFStream { of_http_request_protocol_version_t _protocolVersion; short _statusCode; OFDictionary OF_GENERIC(OFString*, OFString*) *_headers; + OFArray OF_GENERIC(OFHTTPCookie*) *_cookies; } /*! * The status code of the reply to the HTTP request. */ @@ -42,10 +45,16 @@ * The headers of the reply to the HTTP request. */ @property OF_NULLABLE_PROPERTY (copy) OFDictionary OF_GENERIC(OFString*, OFString*) *headers; +/*! + * The cookies to set of the reply to the HTTP request. + */ +@property OF_NULLABLE_PROPERTY (copy) + OFArray OF_GENERIC(OFHTTPCookie*) *cookies; + /*! * @brief Sets the protocol version of the HTTP request reply. * * @param protocolVersion The protocol version of the HTTP request reply */