use of com.tencentcloudapi.vod.v20180717.models.PullEventsResponse in project cloud-sdk by mizhousoft.
the class QCloudVODServiceImpl method pullEvents.
/**
* {@inheritDoc}
*/
@Override
public List<VodEvent> pullEvents() throws CloudSDKException {
try {
PullEventsRequest req = new PullEventsRequest();
PullEventsResponse resp = vodClient.PullEvents(req);
EventContent[] list = resp.getEventSet();
if (null != list) {
List<VodEvent> events = new ArrayList<>(list.length);
for (EventContent item : list) {
VodEvent event = convertToEvent(item);
events.add(event);
}
return events;
}
return new ArrayList<>(0);
} catch (TencentCloudSDKException e) {
throw new CloudSDKException(e.getErrorCode(), e.getMessage(), e);
}
}
Aggregations