public class BeanClass implements javax.ejb.SessionBean {
public Collection ejbFindByPrimaryKey (String key) throws FinderException{
PrimaryKey pKey = new PrimaryKey(key);
Возвращает набор;
searchByPrimaryKey(pKey);
if (pKey.exists())
результат = pKey;
return result;
else
throw new ObjectNotFoundException("Первичный ключ "+ key + " не найден");
}
}
|
|