retrieveCurrentProgramEvent, DATA_UNAVAILABLE. and ReadPermission
I've got this kind of code in my SIRequestor implementation:
publicvoid notifySuccess(SIRetrievable[] result){
String info =null;
if (result[0]instanceof ServiceDetails){
try{
((ServiceDetails)result[0]).getProgramSchedule().
retrieveCurrentProgramEvent(this);
}catch (SIException e){
e.printStackTrace();
}
}elseif (result[0]instanceof ProgramEvent){
ProgramEvent e = (ProgramEvent)result[0];
info = e.getName()
System.out.println("info"+info);
}
}
First I want to get ServiceDetails (for one Service) and it works fine. But when I call (or rather when my notifySuccess method calls) retrieveCurrentProgramEvent each time I get SIRequestFailureType with DATA_UNAVAILABLE reason.
I found something like this in JavaDoc for ProgramSchedule:
If the caller does not have javax.tv.service.ReadPermission(d.getLocator()) (where d is the current data event), this method will result in an SIRequestFailureType of DATA_UNAVAILABLE.
Is there any way I can fix this problem? Cause I'm lack of ideas.
Please help.

