Important: The information in this document is obsolete and should not be used for new development.
MyDownloadCompleted
Responds to notification that a request to download data referenced by a Cyberdog item and save it to disk has been completed.
void MyDownloadCompleted (Environment* ev, CyberItem* item, CDDownloadEvent eventCode, FSSpec* destFile, Ptr userDataPtr);
ev
- A pointer to the SOM environment parameter used to pass exceptions.
item
- A pointer to the Cyberdog item whose data was to be downloaded.
eventCode
- A code that indicates whether the data referenced by the Cyberdog item was downloaded and saved to a file successfully.
destFile
- A pointer to the file specification where the data referenced by the Cyberdog item was stored.
userDataPtr
- A pointer to data that may be useful when a download operation has completed.
DISCUSSION
The download part calls your download notification function when it is finished trying to download the content referenced by a Cyberdog item and save it to disk. You register your download notification function when you call thePostDownloadRequest
method. Your notification function can test theeventCode
parameter to determine whether the download operation succeeded, failed, or was canceled.The
userDataPtr
parameter contains a pointer to data that may be useful when responding to notification that a download request has been completed. For example, this parameter might point to a C++ class that defines a method that is called if the Cyberdog item is downloaded successfully.SEE ALSO
TheCDDownloadEvent
type (page 175).
TheCyberDownloadExtension::PostDownloadRequest
method (page 215).