//
// EGOImageLoader.h
// EGOImageLoading
//
// Created by Shaun Harrison on 9/15/09.
// Copyright (c) 2009-2010 enormego
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
//
#import <Foundation/Foundation.h>
#ifndef __EGOIL_USE_BLOCKS
#define __EGOIL_USE_BLOCKS 0
#endif
#ifndef __EGOIL_USE_NOTIF
#define __EGOIL_USE_NOTIF 1
#endif
@protocol EGOImageLoaderObserver;
@interface EGOImageLoader : NSObject/*<NSURLConnectionDelegate>*/ {
@private
NSDictionary* _currentConnections;
NSMutableDictionary* currentConnections;
#if __EGOIL_USE_BLOCKS
dispatch_queue_t _operationQueue;
#endif
NSLock* connectionsLock;
}
+ (EGOImageLoader*)sharedImageLoader;
- (BOOL)isLoadingImageURL:(NSURL*)aURL;
#if __EGOIL_USE_NOTIF
- (void)loadImageForURL:(NSURL*)aURL observer:(id<EGOImageLoaderObserver>)observer;
- (UIImage*)imageForURL:(NSURL*)aURL shouldLoadWithObserver:(id<EGOImageLoaderObserver>)observer;
- (void)removeObserver:(id<EGOImageLoaderObserver>)observer;
- (void)removeObserver:(id<EGOImageLoaderObserver>)observer forURL:(NSURL*)aURL;
#endif
#if __EGOIL_USE_BLOCKS
- (void)loadImageForURL:(NSURL*)aURL completion:(void (^)(UIImage* image, NSURL* imageURL, NSError* error))completion;
- (void)loadImageForURL:(NSURL*)aURL style:(NSString*)style styler:(UIImage* (^)(UIImage* image))styler completion:(void (^)(UIImage* image, NSURL* imageURL, NSError* error))completion;
#endif
- (BOOL)hasLoadedImageURL:(NSURL*)aURL;
- (void)cancelLoadForURL:(NSURL*)aURL;
- (void)clearCacheForURL:(NSURL*)aURL;
- (void)clearCacheForURL:(NSURL*)aURL style:(NSString*)style;
@property(nonatomic,retain) NSDictionary* currentConnections;
@end
@protocol EGOImageLoaderObserver<NSObject>
@optional
- (void)imageLoaderDidLoad:(NSNotification*)notification; // Object will be EGOImageLoader, userInfo will contain imageURL and image
- (void)imageLoaderDidFailToLoad:(NSNotification*)notification; // Object will be EGOImageLoader, userInfo will contain error
@end
没有合适的资源?快使用搜索试试~ 我知道了~
资源推荐
资源详情
资源评论
收起资源包目录
RTEGOImageLoaderTest.zip (60个子文件)
RTEGOImageLoaderTest
RTEGOImageLoaderTest
RTEGOImageLoaderTest-Prefix.pch 343B
RTEGOImageLoaderTest-Info.plist 1KB
ImageCell.h 355B
AppDelegate.h 293B
EGOImageLoading
.gitignore 62B
EGOCache
EGOCache.m 10KB
EGOCache.h 3KB
.git 33B
.gitmodules 86B
EGOImageLoader
EGOImageLoader.h 3KB
EGOImageLoadConnection.h 2KB
EGOImageLoadConnection.m 3KB
EGOImageLoader.m 12KB
.DS_Store 6KB
EGOImageButton
EGOImageButton.h 2KB
EGOImageButton.m 3KB
EGOImageView
EGOImageView.m 4KB
EGOImageView.h 2KB
.git
HEAD 23B
ORIG_HEAD 41B
packed-refs 94B
index 2KB
FETCH_HEAD 105B
objects
pack
pack-9b91249661243a9429732ddb7a3e7bbeb55e02ae.pack 94KB
pack-9b91249661243a9429732ddb7a3e7bbeb55e02ae.idx 6KB
info
config 387B
modules
EGOCache
HEAD 41B
packed-refs 192B
index 192B
objects
pack
pack-334ebb5ea76f92d084bb1799d0956867076eb911.pack 26KB
pack-334ebb5ea76f92d084bb1799d0956867076eb911.idx 5KB
info
config 339B
logs
HEAD 390B
refs
heads
master 184B
remotes
origin
HEAD 184B
refs
tags
heads
master 41B
remotes
origin
HEAD 32B
logs
HEAD 193B
refs
heads
master 193B
remotes
origin
HEAD 193B
refs
tags
heads
master 41B
remotes
origin
HEAD 32B
ImageViewController.m 750B
placeholder.png 363B
MainViewController.h 319B
en.lproj
InfoPlist.strings 45B
Default-568h@2x.png 18KB
ImageViewController.h 312B
main.m 352B
Default@2x.png 16KB
MainViewController.m 10KB
Default.png 6KB
AppDelegate.m 2KB
.DS_Store 6KB
ImageCell.m 1KB
RTEGOImageLoaderTest.xcodeproj
project.xcworkspace
contents.xcworkspacedata 165B
xcuserdata
Ryan.xcuserdatad
UserInterfaceState.xcuserstate 16KB
project.pbxproj 19KB
xcuserdata
Ryan.xcuserdatad
xcschemes
RTEGOImageLoaderTest.xcscheme 3KB
xcschememanagement.plist 492B
共 60 条
- 1
唐韧_Ryan
- 粉丝: 3082
- 资源: 26
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 三菱PLC例程源码fx2nplc与三台丹佛斯变频器458通讯定位.定尺源程序
- 三菱PLC例程源码FX2NPLC与安川G7变频器通讯(原创)有注释,MEMOBUS的写方式
- 三菱PLC例程源码FX2NPLC与A700变频器RUT通讯
- 小智搜搜-必备搜索工具,搜索快启更胜一筹
- 三菱PLC例程源码FX2NPLC和变频器,F930通讯控制的程序有注解拉丝机程序
- 三菱PLC例程源码FX2NPLC+2AD+4ADTC+2DA+电阻尺+编码器+PID温控
- 安装和配置指引,通俗易懂
- 三菱PLC例程源码FX2NPLC+2AD+4ADTC+2DA+电阻尺+编码器+PID温控完整注释程式+UG330人机
- 三菱PLC例程源码FX2N-INV通讯程序
- 三菱PLC例程源码FX2N-INV通讯
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功
- 1
- 2
- 3
- 4
- 5
- 6
前往页