Adds an array of cookies to the cookie storage if the storage’s cookie acceptance policy permits.
- iOS 2.0+
- macOS 10.2+
- Mac Catalyst 13.0+Beta
- tvOS 9.0+
- watchOS 2.0+
The cookies to add.
The URL associated with the added cookies.
The URL of the main HTML document for the top-level frame, if known. The value can be
nil. This URL is used to determine whether the cookie should be accepted if the cookie accept policy is
Accept Policy Only From Main Document Domain
Cookies in the array will replace existing cookies with the same name, domain, and path in the cookie storage. If the storage has an accept policy of
NSHTTPCookie, the cookies are ignored.
To store cookies from a set of response headers, an application can use
cookies passing a header field dictionary and then use this method to store the resulting cookies in accordance with the cookie storage’s cookie acceptance policy.
If you override this method, also override