use of org.gluu.asimba.util.ldap.sp.RequestorEntry in project oxTrust by GluuFederation.
the class AsimbaAddSPAction method refresh.
public void refresh() {
log.info("refresh() SP call");
spRequestor = new RequestorEntry();
}
use of org.gluu.asimba.util.ldap.sp.RequestorEntry in project oxTrust by GluuFederation.
the class UpdateAsimbaSPRequestorAction method clearEdit.
public void clearEdit() {
log.info("clearEdit() SPRequestor call");
spRequestor = new RequestorEntry();
editEntryInum = null;
newEntry = true;
uploadedCertBytes = null;
}
use of org.gluu.asimba.util.ldap.sp.RequestorEntry in project oxTrust by GluuFederation.
the class AsimbaService method searchRequestors.
/**
* Search by pattern
*
* @param pattern Pattern
* @param sizeLimit Maximum count of results
* @return List of scopes
* @throws Exception
*/
public List<RequestorEntry> searchRequestors(String pattern, int sizeLimit) throws Exception {
// filter
String[] targetArray = new String[] { pattern };
Filter idFilter = Filter.createSubstringFilter(OxTrustConstants.uniqueIdentifier, null, targetArray, null);
Filter friendlyNameFilter = Filter.createSubstringFilter(OxTrustConstants.friendlyName, null, targetArray, null);
Filter descriptionFilter = Filter.createSubstringFilter(OxTrustConstants.description, null, targetArray, null);
Filter inameFilter = Filter.createSubstringFilter(OxTrustConstants.iname, null, targetArray, null);
Filter searchFilter = Filter.createORFilter(idFilter, friendlyNameFilter, descriptionFilter, inameFilter);
// search
List<LDAPRequestorEntry> entries = ldapEntryManager.findEntries(getDnForLDAPRequestorEntry(null), LDAPRequestorEntry.class, searchFilter, sizeLimit);
// convert result
List<RequestorEntry> ret = new ArrayList<RequestorEntry>();
for (LDAPRequestorEntry entry : entries) {
ret.add(entry.getEntry());
}
return ret;
}
use of org.gluu.asimba.util.ldap.sp.RequestorEntry in project oxTrust by GluuFederation.
the class AsimbaService method loadRequestors.
public List<RequestorEntry> loadRequestors() {
List<LDAPRequestorEntry> entries = ldapEntryManager.findEntries(getDnForLDAPRequestorEntry(null), LDAPRequestorEntry.class, null);
List<RequestorEntry> result = new ArrayList<RequestorEntry>();
for (LDAPRequestorEntry entry : entries) {
result.add(entry.getEntry());
}
return result;
}
use of org.gluu.asimba.util.ldap.sp.RequestorEntry in project oxTrust by GluuFederation.
the class UpdateAsimbaSelectorAction method refresh.
public void refresh() {
log.info("refresh() Selector call");
if (searchPattern == null || "".equals(searchPattern)) {
//list loading
selectorList = asimbaService.loadSelectors();
} else {
// search mode, clear pattern
searchPattern = null;
}
// Load edit lists
idpList = new ArrayList<SelectItem>();
List<IDPEntry> idpListEntries = asimbaService.loadIDPs();
for (IDPEntry entry : idpListEntries) {
idpList.add(new SelectItem(entry.getId(), entry.getId(), entry.getFriendlyName()));
}
spRequestorList = new ArrayList<SelectItem>();
List<RequestorEntry> spRequestorListEntries = asimbaService.loadRequestors();
for (RequestorEntry entry : spRequestorListEntries) {
spRequestorList.add(new SelectItem(entry.getId(), entry.getId(), entry.getFriendlyName()));
}
}
Aggregations