iOS Network: Request to modify a URL via Nsmutableurlrequest

Source: Internet
Author: User

Problem:

A URL request can be changed or unchanged. A mutable URL request can be modified after it has been initialized, and an immutable URL request cannot be modified.  You can create a modifiable URL request through Nsmutableurlrequest. Example: Modifying a timeout for a request URL after assigning and initializing a request
@" http://www.apple.com "  *url =
settimeoutinterval:30.0f];
Set the requested URL and timeout after the request has been allocated and initialized:
@" http://www.apple.com "
New
[URLRequest settimeoutinterval:30.0f]; [URLRequest Seturl:url];
Nsmutableurlrequest is created without having to specify a specific URL, which can be set according to our requirements. This allows us to easily adapt our access request to the needs of our clients.

iOS Network: Request to modify a URL via Nsmutableurlrequest

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.