Download BREW Developer Training

Transcript
BREW® Developer Training
Lab 5.3
‹
Working with Web Content
339
Before You Start
Before starting this exercise, you should have:
•
Completed the previous labs
Description
The purpose of this lab is to read a text file from the web and display it on the screen.
APIs Used
ISHELL_CreateInstance() - open IWeb interface
IWEB_GetResponse() - initiate web connection, open IWEBRESP interface
IWEBRESP_GetInfo() - get web response, get ISOURCE interface
ISOURCE_Readable() - register callback to read data
ISOURCE_Read() - read data from web
IWEBRESP_Release() - release IWEBRESP and ISOURCE interfaces
IWEB_Release() - release IWEB interface
IFILEMGR_OpenFile() – open file for writing, get IFile interface
IFILE_Write() – write web data to file
IFILE_Release() – close file
QUALCOMM Confidential and Proprietary
339