use of org.apache.syncope.client.console.rest.ResourceRestClient in project syncope by apache.
the class ConnObjectListViewPanel method reloadItems.
private List<ConnObjectTO> reloadItems(final String resource, final String anyType, final String cookie) {
Pair<String, List<ConnObjectTO>> items = new ResourceRestClient().listConnObjects(resource, anyType, SIZE, cookie, new SortParam<>(ConnIdSpecialName.UID, true));
nextPageCookie = items.getLeft();
return items.getRight();
}
use of org.apache.syncope.client.console.rest.ResourceRestClient in project syncope by apache.
the class HistoryConfDetails method addCurrentInstanceConf.
@SuppressWarnings("unchecked")
private void addCurrentInstanceConf() {
T conf = null;
if (selectedHistoryConfTO instanceof ConnInstanceHistoryConfTO) {
ConnInstanceTO current = new ConnectorRestClient().read(ConnInstanceHistoryConfTO.class.cast(selectedHistoryConfTO).getConnInstanceTO().getKey());
conf = (T) new ConnInstanceHistoryConfTO();
((ConnInstanceHistoryConfTO) conf).setConnInstanceTO(current);
} else if (selectedHistoryConfTO instanceof ResourceHistoryConfTO) {
ResourceTO current = new ResourceRestClient().read(ResourceHistoryConfTO.class.cast(selectedHistoryConfTO).getResourceTO().getKey());
conf = (T) new ResourceHistoryConfTO();
((ResourceHistoryConfTO) conf).setResourceTO(current);
}
if (conf != null) {
conf.setCreator(selectedHistoryConfTO.getCreator());
conf.setKey("current");
availableHistoryConfTOs.add(conf);
}
}
Aggregations