Examples of IPortletCookie


Examples of org.jasig.portal.portlet.om.IPortletCookie

     
      boolean found = false;
      final String name = cookie.getName();
        final EntityManager entityManager = this.getEntityManager();
        for (final Iterator<IPortletCookie> portletCookieItr = portletCookies.iterator(); portletCookieItr.hasNext(); ) {
          final IPortletCookie portletCookie = portletCookieItr.next();
          if (name.equals(portletCookie.getName())) {
              //Delete cookies with a maxAge of 0
              if (cookie.getMaxAge() == 0) {
                  portletCookieItr.remove();
                  entityManager.remove(portletCookie);
              }
              else {
                  portletCookie.updateFromCookie(cookie);
              }
             
              found = true;
              break;
          }
        }
       
        if (!found) {
            IPortletCookie newPortletCookie = new PortletCookieImpl(portalCookie, cookie);
            portletCookies.add(newPortletCookie);
        }
       
    entityManager.persist(portalCookie);
   
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.