Skip to content
dmottcouk edited this page Oct 29, 2015 · 17 revisions

Description

This is a updated (For Android 6 / SDK 23) version of the program which allows you to search the BBC radio listings by Genre

The Genres which you can get today's radio listings for are

Classic Pop and Rock
HipHop, R&B & Dance
Classical (the one I use :-) )
Jazz
Country
Pop
Dance
Rock & Indie
Desi
Soul & Raggae
Easy Listening, Sound Tracks, Musicals
World
Folk

You can search for keywords within the genres like "look for Beethoven in Classical" (my favourite)

Technical details

Technique used is an XMLPullParser for URL
http://www.bbc.co.uk/programmes/genres/music/

Changes for SDK 23

a) using compatibility library - public class MainActivity extends AppCompatActivity

b) Replace the apache HttpGet with HttpURLConnection to get the inputstream

//DefaultHttpClient client = new DefaultHttpClient();
//HttpGet method = new HttpGet(new URI(url));
//HttpResponse res = client.execute(method);
//return res.getEntity().getContent();

    URL url2 = new URL(url);
    HttpURLConnection urlConnection = (HttpURLConnection) url2.openConnection();
    InputStream in = new BufferedInputStream(urlConnection.getInputStream());

Screenshots

Top screen

Help screen

Listing

Details screen

Clone this wiki locally