Files
yinmeng-ios/xplan-ios/Base/UI/UIImageView/UIImageView+LoadImage.h
2021-09-27 11:15:28 +08:00

56 lines
1.7 KiB
Objective-C

//
// UIImageView+LoadImage.h
// xplan-ios
//
// Created by 冯硕 on 2021/9/17.
// 加载图片的类
#import <UIKit/UIKit.h>
#import "UIImageConstant.h"
NS_ASSUME_NONNULL_BEGIN
@interface UIImageView (LoadImage)
/// 加载图片
/// @param url 图片的链接地址
/// @param placeholderImage 站位图
/// @param type 类型 用于设置大小
/// @param cornerRadious 弧度
/// @param success 成功的回调
- (void)load_imageWithUrl:(NSString *)url
placeholderImage:(UIImage *)placeholderImage
type:(ImageType)type
cornerRadious:(CGFloat)cornerRadious
success:(void (^)(UIImage *image))success;
/// 加载图片 回调图片的
/// @param url 图片的链接地址
/// @param placeholderImage 站位图
/// @param success 成功了
- (void)load_imageWithUrl:(NSString *)url placeholderImage:(UIImage *)placeholderImage type:(ImageType)type success:(void (^)(UIImage *image))success;
/// 加载图片不需要成功的回调
/// @param url 图片的链接地址
/// @param placeholderImage 站位图
/// @param type 类型 用于设置大小
/// @param cornerRadious 弧度
- (void)load_imageWithUrl:(NSString *)url
placeholderImage:(UIImage *)placeholderImage
type:(ImageType)type
cornerRadious:(CGFloat)cornerRadious;
/// 加载图片 没有圆角的设置
/// @param url 图片的链接地址
/// @param placeholderImage 站位图
/// @param type 类型 用于设置大小
- (void)load_imageWithUrl:(NSString *)url placeholderImage:(UIImage *)placeholderImage type:(ImageType)type;
/// 加载图片 没有类型的设置
/// @param url 图片的链接地址
/// @param placeholderImage 站位图
- (void)load_imageWithUrl:(NSString *)url placeholderImage:(UIImage *)placeholderImage;
@end
NS_ASSUME_NONNULL_END