Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package com.octo.android.robospice.spicelist.okhttp;
 
 import java.util.List;
 
 
An adapter that is optimized for com.octo.android.robospice.spicelist.SpiceListView instances. It offers to update ImageViews contained in com.octo.android.robospice.spicelist.SpiceListItemView instances with images loaded from the network. All you have to do is to Override com.octo.android.robospice.spicelist.BaseSpiceArrayAdapter.createRequest(java.lang.Object,int,int,int) to define a bitmapRequest for each object in the list that is associated an image to display. Also please note that in your com.octo.android.robospice.spicelist.BaseSpiceArrayAdapter.getView(int,android.view.View,android.view.ViewGroup) method, you must call com.octo.android.robospice.spicelist.BaseSpiceArrayAdapter.updateListItemViewAsynchronously(java.lang.Object,com.octo.android.robospice.spicelist.SpiceListItemView) in order for your com.octo.android.robospice.spicelist.SpiceListItemView to be updated automagically.

Parameters:
<T> the type of data displayed by the list.
Author(s):
sni
public abstract class OkHttpSpiceArrayAdapter<T> extends BaseSpiceArrayAdapter<T> {
    // ----------------------------
    // --- CONSTRUCTOR
    // ----------------------------
    public OkHttpSpiceArrayAdapter(Context contextOkHttpBitmapSpiceManager spiceManagerBinary) {
        this(contextspiceManagerBinarynew ArrayList<T>());
    }
    public OkHttpSpiceArrayAdapter(Context contextOkHttpBitmapSpiceManager spiceManagerBinary, T[] objects) {
        this(contextspiceManagerBinary, Arrays.asList(objects));
    }

    
Used for testing only.
    protected OkHttpSpiceArrayAdapter(Context contextOkHttpBitmapSpiceManager spiceManagerBinaryList<T> objects) {
        super(contextspiceManagerBinaryobjects);
    }
New to GrepCode? Check out our FAQ X