07.01.2013 Views

David Defour - Université de Perpignan

David Defour - Université de Perpignan

David Defour - Université de Perpignan

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Helper Classes<br />

• StatusLineParser<br />

–Reads status line and breaks it into three parts: HTTP version,<br />

status co<strong>de</strong>, and message<br />

• Also isGood (status co<strong>de</strong> in the 200’s), isForwar<strong>de</strong>d (301/302)<br />

and isBad (anything else) methods<br />

• UrlParser<br />

602<br />

jeudi 26 janvier 12<br />

–Breaks a URL like http://host:port/path into the host, port, and<br />

path parts. Uses 80 if no port specified.<br />

–Note that the builtin URL class already does this. See next<br />

lecture. But Android has no builtin support for protocols other<br />

than HTTP, so learning to do it yourself is important.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!