use of org.openntf.domino.NoteCollection in project org.openntf.domino by OpenNTF.
the class Database method getLocalNoteList.
public LocalNoteList getLocalNoteList() {
Set<SelectOption> noteClass = new java.util.HashSet<SelectOption>();
noteClass.add(SelectOption.DOCUMENTS);
NoteCollection nc = createNoteCollection(false);
nc.setSelectOptions(noteClass);
nc.buildCollection();
LocalNoteList result = new org.openntf.domino.big.impl.LocalNoteList(nc, new Date());
return result;
}
use of org.openntf.domino.NoteCollection in project org.openntf.domino by OpenNTF.
the class Database method getModifiedNoteCount.
/*
* (non-Javadoc)
*
* @see org.openntf.domino.ext.Database#getModifiedNoteCount(lotus.domino.DateTime, org.openntf.domino.NoteCollection.SelectOption)
*/
@Override
public int getModifiedNoteCount(final java.util.Date since, final Set<SelectOption> noteClass) {
if (since != null && since.after(this.getLastModifiedDate())) {
return 0;
}
NoteCollection nc = createNoteCollection(false);
if (since != null) {
nc.setSinceTime(since);
}
nc.setSelectOptions(noteClass);
nc.buildCollection();
return nc.getCount();
}
use of org.openntf.domino.NoteCollection in project org.openntf.domino by OpenNTF.
the class Agent method getProfileResults.
@Override
public org.openntf.domino.Document getProfileResults() {
try {
if (isProfiled()) {
NoteCollection nc = getParent().createNoteCollection(false);
String subject = " Profile";
if (getName().contains("|")) {
subject = Strings.left(getName(), "|") + subject;
} else {
if (getName().contains("(")) {
subject = Strings.right(Strings.left(getName(), ")"), "(") + subject;
} else {
subject = getName() + subject;
}
}
nc.setSelectProfiles(true);
nc.setSelectionFormula("Form=\"$BEProfileR7\" & Subject=\"" + subject + "\"");
nc.buildCollection();
if (!Strings.isBlankString(nc.getFirstNoteID())) {
return getParent().getDocumentByID(nc.getFirstNoteID());
}
}
return null;
} catch (Exception e) {
DominoUtils.handleException(e);
return null;
}
}
use of org.openntf.domino.NoteCollection in project org.openntf.domino by OpenNTF.
the class Agent method getUniversalID.
/*
* (non-Javadoc)
*
* @see org.openntf.domino.types.Design#getUniversalID()
*/
@Override
public String getUniversalID() {
NoteCollection notes = parent.createNoteCollection(false);
notes.add(this);
return notes.getUNID(notes.getFirstNoteID());
}
use of org.openntf.domino.NoteCollection in project org.openntf.domino by OpenNTF.
the class Agent method getNoteID.
/*
* (non-Javadoc)
*
* @see org.openntf.domino.types.Design#getNoteID()
*/
@Override
public String getNoteID() {
NoteCollection notes = parent.createNoteCollection(false);
notes.add(this);
return notes.getFirstNoteID();
}
Aggregations