UIImageView(FWImagePlugin)
@interface UIImageView (FWImagePlugin)
/// 自定义图片插件,未设置时自动从插件池加载
@property (nonatomic, strong, nullable) id<FWImagePlugin> fw_imagePlugin NS_REFINED_FOR_SWIFT;
/// 当前正在加载的网络图片URL
@property (nonatomic, copy, readonly, nullable) NSURL *fw_imageURL NS_REFINED_FOR_SWIFT;
/// 加载网络图片,优先加载插件,默认使用框架网络库
- (void)fw_setImageWithURL:(nullable id)url NS_REFINED_FOR_SWIFT;
/// 加载网络图片,支持占位,优先加载插件,默认使用框架网络库
- (void)fw_setImageWithURL:(nullable id)url
placeholderImage:(nullable UIImage *)placeholderImage NS_REFINED_FOR_SWIFT;
/// 加载网络图片,支持占位和回调,优先加载插件,默认使用框架网络库
- (void)fw_setImageWithURL:(nullable id)url
placeholderImage:(nullable UIImage *)placeholderImage
completion:(nullable void (^)(UIImage * _Nullable image, NSError * _Nullable error))completion NS_REFINED_FOR_SWIFT;
/// 加载网络图片,支持占位、选项、回调和进度,优先加载插件,默认使用框架网络库
- (void)fw_setImageWithURL:(nullable id)url
placeholderImage:(nullable UIImage *)placeholderImage
options:(FWWebImageOptions)options
context:(nullable NSDictionary<FWImageCoderOptions, id> *)context
completion:(nullable void (^)(UIImage * _Nullable image, NSError * _Nullable error))completion
progress:(nullable void (^)(double progress))progress NS_REFINED_FOR_SWIFT;
/// 取消加载网络图片请求
- (void)fw_cancelImageRequest NS_REFINED_FOR_SWIFT;
/// 创建动画ImageView视图,优先加载插件,默认UIImageView
+ (UIImageView *)fw_animatedImageView NS_SWIFT_NAME(__fw_animatedImageView()) NS_REFINED_FOR_SWIFT;
@end
Undocumented
-
自定义图片插件,未设置时自动从插件池加载
Declaration
Objective-C
@property (nonatomic, strong, nullable) id<FWImagePlugin> fw_imagePlugin;
-
当前正在加载的网络图片URL
Declaration
Objective-C
@property (nonatomic, copy, readonly, nullable) NSURL *fw_imageURL;
-
加载网络图片,优先加载插件,默认使用框架网络库
Declaration
Objective-C
- (void)fw_setImageWithURL:(nullable id)url;
-
加载网络图片,支持占位,优先加载插件,默认使用框架网络库
Declaration
Objective-C
- (void)fw_setImageWithURL:(nullable id)url placeholderImage:(nullable UIImage *)placeholderImage;
-
加载网络图片,支持占位和回调,优先加载插件,默认使用框架网络库
Declaration
Objective-C
- (void)fw_setImageWithURL:(nullable id)url placeholderImage:(nullable UIImage *)placeholderImage completion: (nullable void (^)(UIImage *_Nullable __strong, NSError *_Nullable __strong))completion;
-
加载网络图片,支持占位、选项、回调和进度,优先加载插件,默认使用框架网络库
Declaration
Objective-C
- (void)fw_setImageWithURL:(nullable id)url placeholderImage:(nullable UIImage *)placeholderImage options:(FWWebImageOptions)options context: (nullable NSDictionary<FWImageCoderOptions, id> *)context completion: (nullable void (^)(UIImage *_Nullable __strong, NSError *_Nullable __strong))completion progress:(nullable void (^)(double))progress;
-
取消加载网络图片请求
Declaration
Objective-C
- (void)fw_cancelImageRequest;
-
创建动画ImageView视图,优先加载插件,默认UIImageView
Declaration
Objective-C
+ (nonnull UIImageView *)fw_animatedImageView;