From bf3f86e66edcc22d787a99198118e7b2ad71ecd9 Mon Sep 17 00:00:00 2001 From: lipengwei <lipengwei@nianben.com> Date: Tue, 07 Jul 2020 08:43:24 +0800 Subject: [PATCH] 2.1.1 --- frameworks/AFNetworking.framework/Headers/WKWebView+AFNetworking.h | 22 +++++++++++----------- 1 files changed, 11 insertions(+), 11 deletions(-) diff --git a/frameworks/AFNetworking.framework/Headers/UIWebView+AFNetworking.h b/frameworks/AFNetworking.framework/Headers/WKWebView+AFNetworking.h similarity index 83% rename from frameworks/AFNetworking.framework/Headers/UIWebView+AFNetworking.h rename to frameworks/AFNetworking.framework/Headers/WKWebView+AFNetworking.h index b9a56af..680fedf 100644 --- a/frameworks/AFNetworking.framework/Headers/UIWebView+AFNetworking.h +++ b/frameworks/AFNetworking.framework/Headers/WKWebView+AFNetworking.h @@ -1,4 +1,4 @@ -// UIWebView+AFNetworking.h +// WkWebView+AFNetworking.h // Copyright (c) 2011–2016 Alamofire Software Foundation ( http://alamofire.org/ ) // // Permission is hereby granted, free of charge, to any person obtaining a copy @@ -26,47 +26,47 @@ #if TARGET_OS_IOS #import <UIKit/UIKit.h> +#import <WebKit/WebKit.h> NS_ASSUME_NONNULL_BEGIN @class AFHTTPSessionManager; -/** - This category adds methods to the UIKit framework's `UIWebView` class. The methods in this category provide increased control over the request cycle, including progress monitoring and success / failure handling. - - @discussion When using these category methods, make sure to assign `delegate` for the web view, which implements `–webView:shouldStartLoadWithRequest:navigationType:` appropriately. This allows for tapped links to be loaded through AFNetworking, and can ensure that `canGoBack` & `canGoForward` update their values correctly. - */ -@interface UIWebView (AFNetworking) +@interface WKWebView (AFNetworking) /** - The session manager used to download all requests. + The session manager used to download all request */ @property (nonatomic, strong) AFHTTPSessionManager *sessionManager; /** Asynchronously loads the specified request. - + @param request A URL request identifying the location of the content to load. This must not be `nil`. + @param navigation The WKNavigation object that containts information for tracking the loading progress of a webpage. This must not be `nil`. @param progress A progress object monitoring the current download progress. @param success A block object to be executed when the request finishes loading successfully. This block returns the HTML string to be loaded by the web view, and takes two arguments: the response, and the response string. @param failure A block object to be executed when the data task finishes unsuccessfully, or that finishes successfully, but encountered an error while parsing the response data. This block has no return value and takes a single argument: the error that occurred. */ - (void)loadRequest:(NSURLRequest *)request + navigation:(WKNavigation * _Nonnull)navigation progress:(NSProgress * _Nullable __autoreleasing * _Nullable)progress success:(nullable NSString * (^)(NSHTTPURLResponse *response, NSString *HTML))success failure:(nullable void (^)(NSError *error))failure; /** Asynchronously loads the data associated with a particular request with a specified MIME type and text encoding. - + @param request A URL request identifying the location of the content to load. This must not be `nil`. + @param navigation The WKNavigation object that containts information for tracking the loading progress of a webpage. This must not be `nil`. @param MIMEType The MIME type of the content. Defaults to the content type of the response if not specified. @param textEncodingName The IANA encoding name, as in `utf-8` or `utf-16`. Defaults to the response text encoding if not specified. -@param progress A progress object monitoring the current download progress. + @param progress A progress object monitoring the current download progress. @param success A block object to be executed when the request finishes loading successfully. This block returns the data to be loaded by the web view and takes two arguments: the response, and the downloaded data. @param failure A block object to be executed when the data task finishes unsuccessfully, or that finishes successfully, but encountered an error while parsing the response data. This block has no return value and takes a single argument: the error that occurred. */ - (void)loadRequest:(NSURLRequest *)request + navigation:(WKNavigation * _Nonnull)navigation MIMEType:(nullable NSString *)MIMEType textEncodingName:(nullable NSString *)textEncodingName progress:(NSProgress * _Nullable __autoreleasing * _Nullable)progress -- Gitblit v1.8.0