Package org.infoglue.cms.entities.structure

Examples of org.infoglue.cms.entities.structure.SiteNode


     
      QueryResults results = oql.execute();
   
    while(results.hasMore())
        {
          SiteNode siteNode = (SiteNodeImpl)results.next();
          siteNodes.add(siteNode);
        }

    results.close();
    oql.close();
View Full Code Here


     
      QueryResults results = oql.execute();
   
    while(results.hasMore())
        {
          SiteNode siteNode = (SiteNode)results.next();
          siteNodes.add(siteNode);
        }

    results.close();
    oql.close();
View Full Code Here

    }
   
    ServiceBindingController.deleteServiceBindingsReferencingSiteNodeVersion(siteNodeVersion, db);
      SiteNodeStateController.getController().deleteAccessRights("SiteNodeVersion", siteNodeVersion.getId(), db);
     
    SiteNode siteNode = siteNodeVersion.getOwningSiteNode();

    if(siteNode != null)
      siteNode.getSiteNodeVersions().remove(siteNodeVersion);

    db.remove(siteNodeVersion);
  }
View Full Code Here

  /**
   * This method deletes a siteNode and also erases all the children and all versions.
   */
  public void markForDeletion(SiteNodeVO siteNodeVO, Database db, boolean forceDelete, InfoGluePrincipal infogluePrincipal, Map<SiteNodeVO, List<ReferenceBean>> contactPersons) throws ConstraintException, SystemException, Exception
  {
    SiteNode siteNode = getSiteNodeWithId(siteNodeVO.getSiteNodeId(), db);
    SiteNode parent = siteNode.getParentSiteNode();
    boolean notifyResponsibleOnReferenceChange = CmsPropertyHandler.getNotifyResponsibleOnReferenceChange();
    logger.info("notifyResponsibleOnReferenceChange:" + notifyResponsibleOnReferenceChange);
    if(parent != null)
    {
      Iterator childSiteNodeIterator = parent.getChildSiteNodes().iterator();
      while(childSiteNodeIterator.hasNext())
      {
          SiteNode candidate = (SiteNode)childSiteNodeIterator.next();
          if(candidate.getId().equals(siteNodeVO.getSiteNodeId()))
            markForDeletionRecursive(siteNode, db, forceDelete, infogluePrincipal, contactPersons, notifyResponsibleOnReferenceChange);
      }
    }
    else
    {
View Full Code Here

        @SuppressWarnings("unchecked")
    Collection<SiteNode> children = siteNode.getChildSiteNodes();
    Iterator<SiteNode> i = children.iterator();
    while(i.hasNext())
    {
      SiteNode childSiteNode = i.next();
      markForDeletionRecursive(childSiteNode, db, forceDelete, infoGluePrincipal, contactPersons, notifyContactPersons);
       }

    if(forceDelete || getIsDeletable(siteNode, infoGluePrincipal, db))
      {
View Full Code Here

       
      beginTransaction(db);
   
        try
        {
          SiteNode siteNode = getSiteNodeWithId(siteNodeId, db);
          siteNode.setIsDeleted(false);
       
      while(siteNode.getParentSiteNode() != null && siteNode.getParentSiteNode().getIsDeleted())
      {
        siteNode = siteNode.getParentSiteNode();
        siteNode.setIsDeleted(false);
      }

        commitTransaction(db);
        }
        catch(Exception e)
View Full Code Here

        oql.bind(repositoryId);
       
      QueryResults results = oql.execute(Database.READONLY);
      while(results.hasMore())
            {
        SiteNode siteNode = (SiteNode)results.next();
        Integer siteNodeRepositoryId = siteNode.getRepository().getRepositoryId();
        Integer siteNodeId = siteNode.getSiteNodeId();

        if((AccessRightController.getController().getIsPrincipalAuthorized(db, infoGluePrincipal, "Repository.Read", siteNodeRepositoryId.toString()) && AccessRightController.getController().getIsPrincipalAuthorized(db, infoGluePrincipal, "Repository.Write", siteNodeRepositoryId.toString()))
          && (AccessRightController.getController().getIsPrincipalAuthorized(db, infoGluePrincipal, "SiteNodeVersion.Read", siteNodeId.toString()) && AccessRightController.getController().getIsPrincipalAuthorized(db, infoGluePrincipal, "SiteNodeVersion.Write", siteNodeId.toString())))
        {
          siteNode.getValueObject().getExtraProperties().put("repositoryMarkedForDeletion", siteNode.getRepository().getIsDeleted());
          siteNodeVOListMarkedForDeletion.add(siteNode.getValueObject());
        }
            }
           
      results.close();
      oql.close();
View Full Code Here

             oql.bind(currentDate);

          QueryResults results = oql.execute(Database.READONLY);
        while(results.hasMore())
            {
          SiteNode siteNode = (SiteNodeImpl)results.next();
          siteNodeVOList.add(siteNode.getValueObject());
            }

        results.close();
        oql.close();
         
View Full Code Here

             oql.bind(principal.getName());

          QueryResults results = oql.execute(Database.READONLY);
        while(results.hasMore())
            {
          SiteNode siteNode = (SiteNodeImpl)results.next();
          siteNodeVOList.add(siteNode.getValueObject());
            }

        results.close();
        oql.close();
         
View Full Code Here

     
    }      

    public SiteNodeVO update(SiteNodeVO siteNodeVO, Database db) throws ConstraintException, SystemException
    {
      SiteNode siteNode = (SiteNode)getObjectWithId(SiteNodeImpl.class, siteNodeVO.getId(), db);
    siteNode.setVO(siteNodeVO);

        return siteNode.getValueObject();
    }       
View Full Code Here

TOP

Related Classes of org.infoglue.cms.entities.structure.SiteNode

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.