use of org.apache.cxf.customer.CustomerNotFoundFault in project cxf by apache.
the class CustomerService method getCustomer.
@WebMethod
@WebResult(name = "customer")
public Customer getCustomer(@WebParam(name = "getCustomer") GetCustomer getCustomer) throws CustomerNotFoundFault {
Customer c = customers.get(getCustomer.getId());
if (c == null) {
CustomerNotFoundDetails details = new CustomerNotFoundDetails();
details.setId(getCustomer.getId());
throw new CustomerNotFoundFault(details);
}
return c;
}
Aggregations