Hi
This method is used to read DRM protected file.
Code:
public java.io.InputStream IAPClientPaymentManager.getDRMResourceAsStream(java.lang.String name)
It does not throw exception instead it returns 'null' in case of error or requested resource is not found -- i.e. does not produce any errors.
Code:
public void purchaseCompleted(int status, String purchaseTicket) {
// Protected resource file
String resourceFile = "/res/drm/data/resourceid_123456/resource.img";
if (status == IAPClientPaymentListener.OK) {
InputStream input = manager.getDRMResourceAsStream(resourceFile);
if(input != null){
// Make the purchased content available to the user in the application UI
}
}
}