Package org.gatein.pc.api

Examples of org.gatein.pc.api.PortletContext


      }

      List<String> handles = new ArrayList<String>(numberOfClones);
      for (Object portletContext : portletContexts)
      {
         PortletContext context = (PortletContext)portletContext;
         String id = context.getId();
         handles.add(id);
      }
      if (log.isDebugEnabled())
      {
         log.debug("Attempting to destroy clones: " + handles);
View Full Code Here


            handle,
            portletState,
            new Holder<Lifetime>(),
            new Holder<List<Extension>>()
         );
         PortletContext newPortletContext = PortletContext.createPortletContext(handle.value, portletState.value, false);
         portlet.setPortletContext(newPortletContext);
         return newPortletContext;
      }
      catch (Exception e)
      {
View Full Code Here

               if (ParameterValidation.existsAndIsNotEmpty(importedPortlets))
               {
                  for (ImportedPortlet importedPortlet : importedPortlets)
                  {
                     org.oasis.wsrp.v2.PortletContext portletContext = importedPortlet.getNewPortletContext();
                     PortletContext apiPC = PortletContext.createPortletContext(portletContext.getPortletHandle(), portletContext.getPortletState(), false);
                     // we need to reference the resulting PortletContext so that it can then be used properly
                     importIdToPortletContext.put(importedPortlet.getImportID(), PortletContext.reference(getProducerId(), apiPC));
                  }
               }
View Full Code Here

                StatefulPortletContext<C> updatedCtx = (StatefulPortletContext<C>) instanceCtx.getModifiedContext();
                C portletState = uiPortlet.getModifiedState(updatedCtx);
                uiPortlet.update(portletState);
            } else {
                // todo: fix me as this shouldn't probably be done only for the WSRP case
                PortletContext clonedContext = instanceCtx.getClonedContext();
                if (clonedContext != null) {
                    C state = uiPortlet.getClonedState(clonedContext);
                    uiPortlet.update(state);
                }
            }
View Full Code Here

         return;
      }

      //
      PortletInvoker portletInvoker = getApplicationComponent(PortletInvoker.class);
      PortletContext portletContext = uiPortlet_.getPortletContext();

      //

      PropertyChange[] propertyChanges = new PropertyChange[uiFormInputs.size()];
View Full Code Here

            uiPortlet.update(portletState);
         }
         else
         {
            // todo: fix me as this shouldn't probably be done only for the WSRP case
            PortletContext clonedContext = instanceCtx.getClonedContext();
            if (clonedContext != null)
            {
               WSRP wsrp = new WSRP();
               wsrp.setPortletId(clonedContext.getId());
               wsrp.setCloned(true); // mark the state as cloned

               // if we have an associated state, record it as well...
               if (clonedContext instanceof StatefulPortletContext)
               {
View Full Code Here

      return invocation;
   }

   public void update(PropertyChange... changes) throws Exception
   {
      PortletContext portletContext = getPortletContext();

      //
      PortletInvoker portletInvoker = getApplicationComponent(PortletInvoker.class);

      // Get marshalled version
View Full Code Here

         {
            PortletInvoker portletInvoker = getApplicationComponent(PortletInvoker.class);
            DataStorage dataStorage = getApplicationComponent(DataStorage.class);
            String applicationId = dataStorage.getId(state.getApplicationState());
            ModelAdapter<S, C> adapter = ModelAdapter.getAdapter(state.getApplicationType());
            PortletContext producerOfferedPortletContext = adapter.getProducerOfferedPortletContext(applicationId);
            org.gatein.pc.api.Portlet producedOfferedPortlet;
           
            try
            {
              producedOfferedPortlet = portletInvoker.getPortlet(producerOfferedPortletContext);
View Full Code Here

      }

      List<String> handles = new ArrayList<String>(numberOfClones);
      for (Object portletContext : portletContexts)
      {
         PortletContext context = (PortletContext)portletContext;
         String id = context.getId();
         handles.add(id);
      }
      log.debug("Attempting to destroy clones: " + handles);

      try
View Full Code Here

            propertyList,
            handle,
            portletState,
            new Holder<List<Extension>>()
         );
         PortletContext newPortletContext = PortletContext.createPortletContext(handle.value, portletState.value);
         portlet.setPortletContext(newPortletContext);
         return newPortletContext;
      }
      catch (Exception e)
      {
View Full Code Here

TOP

Related Classes of org.gatein.pc.api.PortletContext

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.