A mutable URL load request that is independent of protocol or URL scheme.
- iOS 2.0+
- macOS 10.2+
- UIKit for Mac 13.0+Beta
- tvOS 9.0+
- watchOS 2.0+
NSMutable is a subclass of
NSURLRequest that allows you to change the request’s properties.
NSMutable only represents information about the request. Use other classes, such as
NSURLSession, to send the request to a server. See Fetching Website Data into Memory and Uploading Data to a Website for an introduction to these techniques.
Classes that create a network operation based on a request make a deep copy of that request. Thus, changing the request after creating a network operation has no effect on the ongoing operation. For example, if you use
data to create a data task from a request, and then later change the request, the data task continues using the original request.