Coder Social home page Coder Social logo

mlimagecache's Introduction

MLImageCache

Simple yet powerful asynchronous image cache

MLImageCache has been written as an alternative to clumsy SDWebCache. It is based on NSOperation / NSOperationQueue combo, which gives it additional features and safety.

The highlights:

  • Two .m files and .h files. Just drag to your project and go. You can also use CocoaPods.
  • Asynchronous download and disk read gives it an unmatched speed. It does not interfere with scrolling.
  • Uses ARC and is carefully engineered not to induce strong reference cycles. It's memory reliability is thoroughly tested.
  • It downloads only one copy of an image no matter how many times has it been requested.
  • If multiple downloads are initiated with the same image view, only the last one is processed (important for reusable cells in table views)
  • It can download arbitrary data, not only images.
  • It supports prioritization and simultaneous downloads based on NSOperationQueue priority system.

Installation

Use CocoaPods or copy those 4 files directly into the project.

How to use it?

#import "UIImageView+Cache.h"

...

[self.imageView mll_setImageWithURL: self.urlToImage ];

or simply 

[self.imageView setImageWithURL: self.urlToImage ];

if it does not collide with other libs.

And that's it! You can replace SDImageCache instantly. For more advanced features see MLImageCache.h

mlimagecache's People

Contributors

mll avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.