public void handleButton1Request(RequestInvocationEvent event) throws ModelControlException {
  FSAuthDomainsModel model=(FSAuthDomainsModel)getModel();
  AMPropertySheet ps=(AMPropertySheet)getChild(PROPERTIES);
  try {
    Map values=ps.getAttributeValues(model.getDataMap(),false,model);
    String name=(String)getDisplayFieldValue(model.TF_NAME);
    if ((name == null) || (name.length() < 1)) {
      setInlineAlertMessage(CCAlert.TYPE_ERROR,"message.error",model.getLocalizedString("authdomain.authentication.domain.name.missing.message"));
      psModel.setErrorProperty("nameProperty",true);
      forwardTo();
    }
 else {
      CCAddRemove addRemoveList=(CCAddRemove)getChild(ADD_REMOVE_PROVIDERS);
      addRemoveList.restoreStateData();
      CCAddRemoveModel addRemoveModel=(CCAddRemoveModel)addRemoveList.getModel();
      Set providers=new HashSet(getSelectedValues(addRemoveModel));
      model.createAuthenticationDomain(values,providers);
      Object[] params={name};
      String message=MessageFormat.format(model.getLocalizedString("authentication.domain.create.message"),params);
      setPageSessionAttribute(FederationViewBean.MESSAGE_TEXT,message);
      backTrail();
      FederationViewBean vb=(FederationViewBean)getViewBean(FederationViewBean.class);
      passPgSessionMap(vb);
      vb.forwardTo(getRequestContext());
    }
  }
 catch (  AMConsoleException e) {
    setInlineAlertMessage(CCAlert.TYPE_ERROR,"message.error",e.getMessage());
    forwardTo();
  }
}

public void handleButton1Request ( RequestInvocationEvent event ) throws ModelControlException { FSAuthDomainsModel model = ( FSAuthDomainsModel ) getModel ( ) ; AMPropertySheet ps = ( AMPropertySheet ) getChild ( PROPERTIES ) ; try { Map values = ps . getAttributeValues ( model . getDataMap ( ) , false , model ) ; String name = ( String ) getDisplayFieldValue ( model . TF_NAME ) ; if ( ( name == null ) || ( name . length ( ) < 1 ) ) { setInlineAlertMessage ( CCAlert . TYPE_ERROR , "message.error" , model . getLocalizedString ( "authdomain.authentication.domain.name.missing.message" ) ) ; psModel . setErrorProperty ( "nameProperty" , true ) ; forwardTo ( ) ; } else { CCAddRemove addRemoveList = ( CCAddRemove ) getChild ( ADD_REMOVE_PROVIDERS ) ; addRemoveList . restoreStateData ( ) ; CCAddRemoveModel addRemoveModel = ( CCAddRemoveModel ) addRemoveList . getModel ( ) ; Set providers = new HashSet ( getSelectedValues ( addRemoveModel ) ) ; model . createAuthenticationDomain ( values , providers ) ; Object [ ] params = { name } ; String message = MessageFormat . format ( model . getLocalizedString ( "authentication.domain.create.message" ) , params ) ; setPageSessionAttribute ( FederationViewBean . MESSAGE_TEXT , message ) ; backTrail ( ) ; FederationViewBean vb = ( FederationViewBean ) getViewBean ( FederationViewBean . class ) ; passPgSessionMap ( vb ) ; vb . forwardTo ( getRequestContext ( ) ) ; } } catch ( AMConsoleException e ) { setInlineAlertMessage ( CCAlert . TYPE_ERROR , "message.error" , e . getMessage ( ) ) ; forwardTo ( ) ; } }
handles save button request . save
