use of de.vitero.schema.booking.Bookingid in project OpenOLAT by OpenOLAT.
the class ViteroManager method getVmsBookingById.
private Bookingtype getVmsBookingById(int id) throws VmsNotAvailableException {
if (id < 0)
return null;
try {
Bookingid bookingId = new Bookingid();
bookingId.setBookingid(id);
Bookingtype booking = getBookingWebService().getBookingById(bookingId);
return booking;
} catch (SOAPFaultException f) {
ErrorCode code = handleAxisFault(f);
switch(code) {
case invalidAttribut:
log.error("ids <= 0", f);
break;
case bookingDoesntExist:
log.error("The booking does not exist", f);
break;
default:
logAxisError("Cannot get booking by id: " + id, f);
}
return null;
} catch (WebServiceException e) {
if (e.getCause() instanceof ConnectException) {
throw new VmsNotAvailableException();
}
log.error("Cannot get booking by id: " + id, e);
return null;
}
}
use of de.vitero.schema.booking.Bookingid in project openolat by klemens.
the class ViteroManager method getVmsBookingById.
private Bookingtype getVmsBookingById(int id) throws VmsNotAvailableException {
if (id < 0)
return null;
try {
Bookingid bookingId = new Bookingid();
bookingId.setBookingid(id);
Bookingtype booking = getBookingWebService().getBookingById(bookingId);
return booking;
} catch (SOAPFaultException f) {
ErrorCode code = handleAxisFault(f);
switch(code) {
case invalidAttribut:
log.error("ids <= 0", f);
break;
case bookingDoesntExist:
log.error("The booking does not exist", f);
break;
default:
logAxisError("Cannot get booking by id: " + id, f);
}
return null;
} catch (WebServiceException e) {
if (e.getCause() instanceof ConnectException) {
throw new VmsNotAvailableException();
}
log.error("Cannot get booking by id: " + id, e);
return null;
}
}
Aggregations