Examples of canAddMixin()


Examples of javax.jcr.Node.canAddMixin()

        Node node = testRootNode.addNode(nodeName4, nodeType);

        // try to make it versionable if it is not
        if (!node.isNodeType(mixVersionable)) {
            if (node.canAddMixin(mixVersionable)) {
                node.addMixin(mixVersionable);
            } else {
                throw new NotExecutableException("Failed to set up required test items.");
            }
        }
View Full Code Here

Examples of org.exoplatform.services.jcr.core.ExtendedNode.canAddMixin()

      LOG.debug("Changing Permission on node: " + pathToChange);

      ExtendedNode chNode = (ExtendedNode) session.getItem(pathToChange);
      if (!chNode.isNodeType("exo:privilegeable"))
      {
         if (chNode.canAddMixin("exo:privilegeable"))
            chNode.addMixin("exo:privilegeable");
         else
            throw new RepositoryException("Can't add mixin");
      }
      // log.info("PERMS-SIZE:" + permissions.length);
View Full Code Here

Examples of org.exoplatform.services.jcr.impl.core.NodeImpl.canAddMixin()

{

   public boolean execute(Context ctx) throws Exception
   {
      NodeImpl node = (NodeImpl)ctx.get("currentItem");
      if (node != null && node.canAddMixin("exo:owneable"))
      {
         node.addMixin("exo:owneable");
      }
      return false;
   }
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.