public Attr[] attributes() {
return null;
}
public Client seek(AtrilSession oSes, String sClient) throws ElementNotFoundException, NotEnoughRightsException, DmsException, InstantiationException, IllegalAccessException {
if (sClient==null) throw new ElementNotFoundException("Client may not be null");
if (sClient.length()==0) throw new ElementNotFoundException("Client may not be empty");
final String sSanitizedBusinessName = Gadgets.removeChars(sClient, "\"*?").trim().toUpperCase();;
for (Client c : super.list(oSes)) {
if (c.getBusinessName().equals(sSanitizedBusinessName) || c.getBusinessName().equalsIgnoreCase(sClient) || c.getId().equals(sClient) || c.getTaxId().equalsIgnoreCase(sClient))
return c;
}
throw new ElementNotFoundException("Client "+sClient+"not found");
}