Warning: Use of undefined constant _FILE_ - assumed '_FILE_' (this will throw an Error in a future version of PHP) in /home/bolyarco/www-ikratko/ogrelab/wp-content/plugins/ad-blocker-stats-vip/ad-blocker-stats-vip.php on line 13

Warning: count(): Parameter must be an array or an object that implements Countable in /home/bolyarco/www-ikratko/ogrelab/wp-content/plugins/microkids-related-posts/microkids-related-posts.php on line 645

Dynamic ListView using Volley and NetworkImageView

Posted / Публикувана 2013-05-30 in category / в категория: Android

Warning: count(): Parameter must be an array or an object that implements Countable in /home/bolyarco/www-ikratko/ogrelab/wp-content/plugins/microkids-related-posts/microkids-related-posts.php on line 645

Just added new example to the Android Volley Examples project which shows how to use Volley to populate dynamically ListView including loading of images using NetworkImageView. It also uses a simple read-ahead technique in order to load next page of data when the user reaches close to the end of the current page in order to minimize the wait.

dynamic-list-view-volley

4 Responses to “Dynamic ListView using Volley and NetworkImageView”

  1. none Says:

    Why you use StringRequest in this example?

  2. Ogi Bankov / Огнян Банков Says:

    Probably you mean why not use JsonObjectRequest?
    I needed just a small part of the returned JSON string and needed the raw string just to be able more easily to see what fields I will need.
    In "real" application it will be more straightforward to use JsonObjectRequest of course….

  3. none Says:

    One more question about StringRequest.
    A small piece of code:

    return new Response.Listener(){
    @Override
    public void onResponse(String response) {

    Log.d("Response.Listener", response);

    }

    I thought it would be one String, which I can then parse.
    But in LogCat I see a few calls Log.d. And as a result, I can not make parsing …. Any ideas? Thank you.

  4. Ogi Bankov / Огнян Банков Says:

    I am afraid I am not understanding exactly what you mean? Did you execute just one request? Or you use this listener for several requests?