How it works...

You will remember that we retrieved XML data that looks like this:

<?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet title="XSL_formatting" type="text/xsl" href="/shared/bsp/xsl/rss/nolsol.xsl"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/"      xmlns:content="http://purl.org/rss/1.0/modules/content/"      xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"      xmlns:media="http://search.yahoo.com/mrss/">    <channel>        <title><![CDATA[BBC News - Home]]></title>        <description><![CDATA[BBC News - Home]]></description>        <link>http://www.bbc.co.uk/news/</link>        <image>                 <url>http://news.bbcimg.co.uk/nol/shared/img/bbc_news_120x60.gif</url>            <title>BBC News - Home</title>            <link>http://www.bbc.co.uk/news/</link>        </image> <generator>RSS ...

Get Swift 4 Programming Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.