for (NotesDocumentMock doc: documents) {
if (unid.equals(doc.getItemValueString(NCCONST.NCITM_UNID))) {
return doc;
}
}
throw new NotesConnectorException() {
@Override public String getMessage() {
return unid + " document is not found";
}
@Override public int getId() {
return NOTES_ERR_BAD_UNID;