初步介绍
Android Picasso-强大的图片下载缓存类库这篇文章已经写得很好了。
创建Picasso对象
Picasso.with(context)
让我们看看具体的代码
public static Picasso with(Context context) {
if (singleton == null) {
synchronized (Picasso.class) {
if (singleton == null) {
singleton = new Builder(context).build();
}
}
}
return singleton;
}