Package it.eng.spago.base

Examples of it.eng.spago.base.SessionContainer


        synchronized (session) {
            RequestContainer parentRequestContainer = (RequestContainer) session
                    .getAttribute(Constants.REQUEST_CONTAINER);
            if (!Navigator.isNavigatorEnabled()) {
                if (parentRequestContainer == null)
                    requestContainer.setSessionContainer(new SessionContainer(true));
                else
                    requestContainer.setSessionContainer(parentRequestContainer
                            .getSessionContainer());
            }
            else {
                if (parentRequestContainer == null)
                    requestContainer.setSessionContainer(new SessionContainer(true));
                else {
                    requestContainer.setSessionContainer(new SessionContainer(false));
                    requestContainer.setParent(parentRequestContainer);
                } // if (parentRequestContainer == null) else
            } // if (!Navigator.isNavigatorEnabled())
            session.setAttribute(Constants.REQUEST_CONTAINER, requestContainer);
        } // synchronized (session)
View Full Code Here


    // define the spago paginator and list object
    PaginatorIFace paginator = new GenericPaginator();
    ListIFace list = new GenericList();
    // recover lov object 
    RequestContainer requestContainer = getRequestContainer();
    SessionContainer session = requestContainer.getSessionContainer();
    ModalitiesValue modVal = (ModalitiesValue) session.getAttribute(SpagoBIConstants.MODALITY_VALUE_OBJECT);
    // get the lov provider
    String looProvider = modVal.getLovProvider();
    // get from the request the type of lov
    String typeLov = LovDetailFactory.getLovTypeCode(looProvider);
    // get the usser profile
    IEngUserProfile profile = null;
    profile = (IEngUserProfile)session.getAttribute(SpagoBIConstants.USER_PROFILE_FOR_TEST);
    if(profile==null) {
      SessionContainer permSess = session.getPermanentContainer();
      profile = (IEngUserProfile) permSess.getAttribute(IEngUserProfile.ENG_USER_PROFILE);
    } else {
      session.delAttribute(SpagoBIConstants.USER_PROFILE_FOR_TEST);
    }
    // based on lov type fill the spago list and paginator object
    SourceBean rowsSourceBean = null;
View Full Code Here

    Iterator it = objectsList.iterator();
    while (it.hasNext()) {
      Menu menu= (Menu) it.next();
      /* ********* start luca changes *************** */
      RequestContainer reqCont = ChannelUtilities.getRequestContainer(httpRequest);
      SessionContainer sessionContainer = reqCont.getSessionContainer();
      SessionContainer permanentSession = sessionContainer.getPermanentContainer();
      IEngUserProfile profile = (IEngUserProfile)permanentSession.getAttribute(IEngUserProfile.ENG_USER_PROFILE);
      /* ********* end luca changes ***************** */
      if (initialPath != null) {
        if (initialPath.equalsIgnoreCase(menu.getName())) addItemForJSTree(htmlStream, menu, true);
        else addItemForJSTree(htmlStream, menu, false);
      } else {
View Full Code Here

  }
 

  public static String getCurrentTheme(RequestContainer reqCont){
    SessionContainer sessCont = reqCont.getSessionContainer();
    SessionContainer permSess = sessCont.getPermanentContainer();   
    String currTheme=(String)permSess.getAttribute(SpagoBIConstants.THEME);

    if(currTheme!=null){
      return currTheme;
    }
    else{
View Full Code Here

      // set into import manager the association import mode
      impManager.setImpAssMode(assMode);

    RequestContainer requestContainer = this.getRequestContainer();
    SessionContainer session = requestContainer.getSessionContainer();
    session.setAttribute(ImportExportConstants.IMPORT_MANAGER, impManager);
   
    // start import operations
    if (impManager.getImpAssMode().equals(IImportManager.IMPORT_ASS_PREDEFINED_MODE) && !impManager.associateAllExportedRolesByUserAssociation()) {
      response.setAttribute(ImportExportConstants.PUBLISHER_NAME, "ImportExportSkipRoleAssociation");
    } else {
View Full Code Here

    private void associateRoles(SourceBean request, SourceBean response) throws EMFUserError {
  logger.debug("IN");
  IImportManager impManager = null;
  try {
      RequestContainer requestContainer = this.getRequestContainer();
      SessionContainer session = requestContainer.getSessionContainer();
      impManager = (IImportManager) session.getAttribute(ImportExportConstants.IMPORT_MANAGER);
      impManager.openSession();
      MetadataAssociations metaAss = impManager.getMetadataAssociation();
      if (!request.containsAttribute("ROLES_ASSOCIATIONS_SKIPPED")) {
      // the roles associations form was submitted
      List expRoleIds = request.getAttributeAsList("expRole");
View Full Code Here

    private void associateEngines(SourceBean request, SourceBean response) throws EMFUserError {
  logger.debug("IN");
  IImportManager impManager = null;
  try {
    RequestContainer requestContainer = this.getRequestContainer();
    SessionContainer session = requestContainer.getSessionContainer();
    impManager = (IImportManager)session.getAttribute(ImportExportConstants.IMPORT_MANAGER);
    impManager.openSession();
    MetadataAssociations metaAss = impManager.getMetadataAssociation();
    if (!request.containsAttribute("ENGINES_ASSOCIATIONS_SKIPPED")) {
      List expEngineIds = request.getAttributeAsList("expEngine");
      Iterator iterExpEngines = expEngineIds.iterator();
View Full Code Here

    private void associateDataSources(SourceBean request, SourceBean response) throws EMFUserError {
  logger.debug("IN");
  IImportManager impManager = null;
  try {
    RequestContainer requestContainer = this.getRequestContainer();
    SessionContainer session = requestContainer.getSessionContainer();
    impManager = (IImportManager)session.getAttribute(ImportExportConstants.IMPORT_MANAGER);
    impManager.openSession();
    MetadataAssociations metaAss = impManager.getMetadataAssociation();
    List expDsIds = request.getAttributeAsList("expConn");
    Iterator iterExpConn = expDsIds.iterator();
    while(iterExpConn.hasNext()){
View Full Code Here

      overwrite = Boolean.parseBoolean(overwriteStr);
    } catch (Exception e) {
      logger.warn("Overwrite parameter is not a valid boolean; default value (that is false) will be considered.");
    }
      RequestContainer requestContainer = this.getRequestContainer();
      SessionContainer session = requestContainer.getSessionContainer();
      impManager = (IImportManager) session.getAttribute(ImportExportConstants.IMPORT_MANAGER);
      impManager.openSession();
      impManager.importObjects(overwrite, session);
      ImportResultInfo iri = impManager.commitAllChanges();
      response.setAttribute(ImportExportConstants.IMPORT_RESULT_INFO, iri);
    AssociationFile assFile = impManager.getAssociationFile();
View Full Code Here

     * @throws EMFUserError
     */
    private void exitImport(SourceBean request, SourceBean response) throws EMFUserError {
  logger.debug("IN");
  RequestContainer requestContainer = this.getRequestContainer();
  SessionContainer session = requestContainer.getSessionContainer();
  IImportManager impManager = (IImportManager) session.getAttribute(ImportExportConstants.IMPORT_MANAGER);
  impManager.stopImport();
  try {
      response.setAttribute(ImportExportConstants.PUBLISHER_NAME, "ImportExportLoopbackStopImport");
  } catch (SourceBeanException sbe) {
      logger.error("Error while populating response source bean ", sbe);
View Full Code Here

TOP

Related Classes of it.eng.spago.base.SessionContainer

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.