Search in sources :

Example 11 with SMDescriptionData

use of com.sun.identity.console.service.model.SMDescriptionData in project OpenAM by OpenRock.

the class EntityDiscoveryDescriptionEditViewBean method getCurrentData.

protected SMDescriptionData getCurrentData() {
    int currentIdx = Integer.parseInt((String) getPageSessionAttribute(PGATTR_INDEX));
    SMDiscoEntryData data = (SMDiscoEntryData) getPageSessionAttribute(PG_SESSION_DISCO_ENTRY_DATA);
    return (SMDescriptionData) data.descData.get(currentIdx);
}
Also used : SMDiscoEntryData(com.sun.identity.console.service.model.SMDiscoEntryData) SMDescriptionData(com.sun.identity.console.service.model.SMDescriptionData)

Example 12 with SMDescriptionData

use of com.sun.identity.console.service.model.SMDescriptionData in project OpenAM by OpenRock.

the class RealmDiscoveryDescriptionEditViewBean method getCurrentData.

protected SMDescriptionData getCurrentData() {
    int currentIdx = Integer.parseInt((String) getPageSessionAttribute(PGATTR_INDEX));
    SMDiscoEntryData data = (SMDiscoEntryData) getPageSessionAttribute(PG_SESSION_DISCO_ENTRY_DATA);
    return (SMDescriptionData) data.descData.get(currentIdx);
}
Also used : SMDiscoEntryData(com.sun.identity.console.service.model.SMDiscoEntryData) SMDescriptionData(com.sun.identity.console.service.model.SMDescriptionData)

Example 13 with SMDescriptionData

use of com.sun.identity.console.service.model.SMDescriptionData in project OpenAM by OpenRock.

the class UMUserResourceOfferingEditViewBean method getCurrentServiceData.

protected SMDiscoEntryData getCurrentServiceData() {
    int currentIdx = Integer.parseInt((String) getPageSessionAttribute(PGATTR_INDEX));
    DiscoveryDataCache cache = DiscoveryDataCache.getInstance();
    String cacheID = (String) getPageSessionAttribute(UMUserResourceOfferingViewBean.DATA_ID);
    SMDiscoveryServiceData smEntry = cache.getData(getModel().getUserSSOToken(), cacheID);
    List resourceData = smEntry.getResourceData();
    SMDiscoEntryData smDisco = (SMDiscoEntryData) resourceData.get(currentIdx);
    if (getPageSessionAttribute(PGATTR_ORIG_MECH_ID) == null) {
        ArrayList list = new ArrayList();
        for (Iterator i = smDisco.descData.iterator(); i.hasNext(); ) {
            list.add(new SMDescriptionData((SMDescriptionData) i.next()));
        }
        setPageSessionAttribute(PGATTR_ORIG_MECH_ID, list);
    }
    return smDisco;
}
Also used : SMDiscoveryServiceData(com.sun.identity.console.service.model.SMDiscoveryServiceData) SMDiscoEntryData(com.sun.identity.console.service.model.SMDiscoEntryData) ArrayList(java.util.ArrayList) Iterator(java.util.Iterator) ArrayList(java.util.ArrayList) List(java.util.List) SMDescriptionData(com.sun.identity.console.service.model.SMDescriptionData) DiscoveryDataCache(com.sun.identity.console.service.model.DiscoveryDataCache)

Aggregations

SMDescriptionData (com.sun.identity.console.service.model.SMDescriptionData)13 SMDiscoEntryData (com.sun.identity.console.service.model.SMDiscoEntryData)6 AMConsoleException (com.sun.identity.console.base.model.AMConsoleException)2 Iterator (java.util.Iterator)2 DiscoveryDataCache (com.sun.identity.console.service.model.DiscoveryDataCache)1 SMDiscoveryServiceData (com.sun.identity.console.service.model.SMDiscoveryServiceData)1 CCActionTableModel (com.sun.web.ui.model.CCActionTableModel)1 CCAddRemoveModel (com.sun.web.ui.model.CCAddRemoveModel)1 CCAddRemove (com.sun.web.ui.view.addremove.CCAddRemove)1 ArrayList (java.util.ArrayList)1 HashSet (java.util.HashSet)1 List (java.util.List)1 Set (java.util.Set)1