Search in sources :

Example 1 with RSSService

use of com.codename1.io.services.RSSService in project CodenameOne by codenameone.

the class RSSReader method sendRequest.

/**
 * Send the request to the server, will only work once. This is called implicitly
 * when the list is initialized
 */
public void sendRequest() {
    if (service == null) {
        service = new RSSService(url, limit);
        if (iconPlaceholder != null) {
            service.setIconPlaceholder(iconPlaceholder);
        }
        service.addResponseListener(new EventHandler());
        if (blockList) {
            Progress p = new Progress(progressTitle, service, displayProgressPercentage);
            p.setAutoShow(true);
            p.setDisposeOnCompletion(true);
        }
        setHint(progressTitle);
        NetworkManager.getInstance().addToQueue(service);
    }
}
Also used : RSSService(com.codename1.io.services.RSSService)

Aggregations

RSSService (com.codename1.io.services.RSSService)1