com.google.android.apps.picview.request.PicasaAlbumsUrl

Here are the examples of the java api class com.google.android.apps.picview.request.PicasaAlbumsUrl taken from open source projects.

1. AlbumListActivity#doAlbumsRequest()

View license
/**
   * Loads the albums for the given user.
   * 
   * TODO: This is Picasa specific.
   */
private void doAlbumsRequest(String userName) {
    // Use text field value.
    PicasaAlbumsUrl url = new PicasaAlbumsUrl(userName);
    AsyncRequestTask request = new AsyncRequestTask(cachedWebRequestFetcher, url.getUrl(), false, "Loading albums...", this, new RequestCallback() {

        @Override
        public void success(String data) {
            AlbumListActivity.this.albums = Album.parseFromPicasaXml(data);
            Log.d(TAG, "Albums loaded: " + AlbumListActivity.this.albums.size());
            showAlbums();
        }

        @Override
        public void error(String message) {
            Log.e(TAG, "Could not load albums: " + message);
            showError("Error while fetching albums");
        }
    });
    request.execute();
}