Search in sources :

Example 46 with OrderedSet

use of com.sun.identity.shared.datastruct.OrderedSet in project OpenAM by OpenRock.

the class WSPersonalProfileServiceViewBean method handleTblSupportedContainerButtonDeleteRequest.

/**
     * Handles remove supported container request.
     *
     * @param event Request Invocation Event.
     */
public void handleTblSupportedContainerButtonDeleteRequest(RequestInvocationEvent event) throws ModelControlException {
    setSubmitCycle(true);
    CCActionTable table = (CCActionTable) getChild(WSPersonalProfileServiceModelImpl.ATTRIBUTE_NAME_SUPPPORTED_CONTAINERS);
    table.restoreStateData();
    CCActionTableModel tblModel = (CCActionTableModel) propertySheetModel.getModel(WSPersonalProfileServiceModelImpl.ATTRIBUTE_NAME_SUPPPORTED_CONTAINERS);
    Integer[] selected = tblModel.getSelectedRows();
    if ((selected != null) && (selected.length > 0)) {
        OrderedSet tblValues = (OrderedSet) getPageSessionAttribute(WSPersonalProfileServiceModelImpl.ATTRIBUTE_NAME_SUPPPORTED_CONTAINERS);
        tblValues.removeAll(selected);
        setPageSessionAttribute(WSPersonalProfileServiceModelImpl.ATTRIBUTE_NAME_SUPPPORTED_CONTAINERS, tblValues);
        populateSupportedContainersTable(tblValues);
    }
    resetButtonState(TBL_SUPPORTED_CONTAINER_DELETE_BTN);
    forwardTo();
}
Also used : OrderedSet(com.sun.identity.shared.datastruct.OrderedSet) CCActionTableModel(com.sun.web.ui.model.CCActionTableModel) CCActionTable(com.sun.web.ui.view.table.CCActionTable)

Example 47 with OrderedSet

use of com.sun.identity.shared.datastruct.OrderedSet in project OpenAM by OpenRock.

the class WSPPServiceSupportedContainerEditViewBean method handleButton1Request.

protected void handleButton1Request(Map values) {
    WSPersonalProfileServiceViewBean vb = (WSPersonalProfileServiceViewBean) getViewBean(WSPersonalProfileServiceViewBean.class);
    Map mapAttrs = (Map) getPageSessionAttribute(WSPersonalProfileServiceViewBean.PROPERTY_ATTRIBUTE);
    OrderedSet containers = (OrderedSet) mapAttrs.get(WSPersonalProfileServiceModelImpl.ATTRIBUTE_NAME_SUPPPORTED_CONTAINERS);
    int index = Integer.parseInt((String) getPageSessionAttribute(PGATTR_INDEX));
    containers.set(index, mapToString(values));
    backTrail();
    unlockPageTrailForSwapping();
    passPgSessionMap(vb);
    vb.forwardTo(getRequestContext());
}
Also used : OrderedSet(com.sun.identity.shared.datastruct.OrderedSet) Map(java.util.Map)

Example 48 with OrderedSet

use of com.sun.identity.shared.datastruct.OrderedSet in project OpenAM by OpenRock.

the class WSPPServiceSupportedContainerEditViewBean method beginDisplay.

public void beginDisplay(DisplayEvent event) throws ModelControlException {
    super.beginDisplay(event);
    if (populateValues) {
        int index = Integer.parseInt((String) getPageSessionAttribute(PGATTR_INDEX));
        Map mapAttrs = (Map) getPageSessionAttribute(WSPersonalProfileServiceViewBean.PROPERTY_ATTRIBUTE);
        OrderedSet set = (OrderedSet) mapAttrs.get(WSPersonalProfileServiceModelImpl.ATTRIBUTE_NAME_SUPPPORTED_CONTAINERS);
        setValues((String) set.get(index));
    }
}
Also used : OrderedSet(com.sun.identity.shared.datastruct.OrderedSet) Map(java.util.Map)

Example 49 with OrderedSet

use of com.sun.identity.shared.datastruct.OrderedSet in project OpenAM by OpenRock.

the class WSPPServiceDSAttributeMapListEditViewBean method handleButton1Request.

protected void handleButton1Request(Map values) {
    WSPersonalProfileServiceViewBean vb = (WSPersonalProfileServiceViewBean) getViewBean(WSPersonalProfileServiceViewBean.class);
    Map mapAttrs = (Map) getPageSessionAttribute(WSPersonalProfileServiceViewBean.PROPERTY_ATTRIBUTE);
    OrderedSet mappings = (OrderedSet) mapAttrs.get(WSPersonalProfileServiceModelImpl.ATTRIBUTE_NAME_DS_ATTRIBUTE_MAP_LIST);
    int index = Integer.parseInt((String) getPageSessionAttribute(PGATTR_INDEX));
    String val = (String) values.get(ATTR_NAME) + "=" + (String) values.get(ATTR_MAPPING_ATTRIBUTE);
    mappings.set(index, val);
    backTrail();
    unlockPageTrailForSwapping();
    passPgSessionMap(vb);
    vb.forwardTo(getRequestContext());
}
Also used : OrderedSet(com.sun.identity.shared.datastruct.OrderedSet) Map(java.util.Map)

Example 50 with OrderedSet

use of com.sun.identity.shared.datastruct.OrderedSet in project OpenAM by OpenRock.

the class WSPPServiceDSAttributeMapListEditViewBean method beginDisplay.

public void beginDisplay(DisplayEvent event) throws ModelControlException {
    super.beginDisplay(event);
    if (populateValues) {
        int index = Integer.parseInt((String) getPageSessionAttribute(PGATTR_INDEX));
        Map mapAttrs = (Map) getPageSessionAttribute(WSPersonalProfileServiceViewBean.PROPERTY_ATTRIBUTE);
        OrderedSet set = (OrderedSet) mapAttrs.get(WSPersonalProfileServiceModelImpl.ATTRIBUTE_NAME_DS_ATTRIBUTE_MAP_LIST);
        setValues((String) set.get(index));
    }
}
Also used : OrderedSet(com.sun.identity.shared.datastruct.OrderedSet) Map(java.util.Map)

Aggregations

OrderedSet (com.sun.identity.shared.datastruct.OrderedSet)87 Map (java.util.Map)52 Set (java.util.Set)36 Iterator (java.util.Iterator)20 HashMap (java.util.HashMap)17 HashSet (java.util.HashSet)16 AMConsoleException (com.sun.identity.console.base.model.AMConsoleException)13 CCActionTableModel (com.sun.web.ui.model.CCActionTableModel)13 CCActionTable (com.sun.web.ui.view.table.CCActionTable)12 AMServiceProfileModel (com.sun.identity.console.base.model.AMServiceProfileModel)6 CaseInsensitiveHashSet (com.sun.identity.common.CaseInsensitiveHashSet)5 ArrayList (java.util.ArrayList)5 LinkedHashSet (java.util.LinkedHashSet)5 SMDiscoveryServiceData (com.sun.identity.console.service.model.SMDiscoveryServiceData)4 List (java.util.List)4 AuthPropertiesModel (com.sun.identity.console.authentication.model.AuthPropertiesModel)3 WSAuthHandlerEntry (com.sun.identity.console.webservices.model.WSAuthHandlerEntry)3 IdRepo (com.sun.identity.idm.IdRepo)3 Issuer (com.sun.identity.saml2.assertion.Issuer)3 SAML2Exception (com.sun.identity.saml2.common.SAML2Exception)3