Examples of removeChild()


Examples of org.hibernate.test.event.collection.ParentWithCollection.removeChild()

    listeners.clear();
    Session s = openSession();
    Transaction tx = s.beginTransaction();
    parent = ( ParentWithCollection ) s.get( parent.getClass(), parent.getId() );
    child = ( ChildEntity ) s.get( child.getClass(), child.getId() );
    parent.removeChild( child );
    s.delete( parent );
    tx.commit();
    s.close();
    int index = 0;
    checkResult( listeners, listeners.getInitializeCollectionListener(), parent, index++ );
View Full Code Here

Examples of org.hive2hive.core.model.FolderIndex.removeChild()

      FolderIndex oldParent = movedNode.getParent();
      oldParentKey = oldParent.getFileKeys().getPublic();

      // source's parent needs to be updated, no matter if it's root or not
      oldParent.removeChild(movedNode);

      // add to the new parent
      FolderIndex newParent = (FolderIndex) userProfile.getFileByPath(context.getDestination()
          .getParentFile(), networkManager.getSession().getRoot());
      movedNode.setParent(newParent);
View Full Code Here

Examples of org.htmlparser.tags.StyleTag.removeChild()

        if ( "a".equalsIgnoreCase( name ) ) {
          tag.setAttribute( "target", "_blank" );
        } else if ( "style".equalsIgnoreCase( name ) && tag instanceof StyleTag ) {
          StyleTag styleTag = (StyleTag) tag;
          if ( styleTag.getChildCount() > 0 ) {
            styleTag.removeChild( 0 );
          }
        } else if ( "img".equalsIgnoreCase( name ) && tag instanceof ImageTag ) {
          ImageTag imageTag = (ImageTag) tag;
          imageTag.setImageURL( "NOIMAGE" );
        }
View Full Code Here

Examples of org.jboss.as.controller.registry.Resource.removeChild()

            final PathElement element = i.next();
            if (element.isMultiTarget()) {
                throw MESSAGES.cannotRemove("*");
            }
            if (! i.hasNext()) {
                model = model.removeChild(element);
            } else {
                model = requireChild(model, element, address);
            }
        }
        return model;
View Full Code Here

Examples of org.jboss.cache.DataNode.removeChild()

                    log.warn("Attempted to delete the root node");
                }
                else
                {
                    DataNode parent = (DataNode) dNode.getParent();
                    parent.removeChild( dNode.getName() );
                }
                cache.notifyNodeRemoved(dNode.getFqn());
                cache.notifyNodeRemove(dNode.getFqn(), false);
            }
            else
View Full Code Here

Examples of org.jboss.cache.InternalNode.removeChild()

            if (trace) log.trace("removing NODE as it is a leaf: evict(" + fqn + ")");
            InternalNode parentNode = lookupInAllScopes(ctx, fqn.getParent());

            if (parentNode != null)
            {
               parentNode.removeChild(fqn.getLastElement());
               parentNode.setChildrenLoaded(false);
            }
            node.setValid(false, false);
            node.markAsDeleted(true);
            node.setDataLoaded(false);
View Full Code Here

Examples of org.jboss.cache.Node.removeChild()

   public void testLazyLoadingOnNodeRemoveChild() throws Exception
   {
      cache.getTransactionManager().begin();
      Node node = cache.getRoot().getChild(parent);
      node.removeChild(child.getLastElement());
      assert !node.hasChild(child.getLastElement()) : "Node should have removed child";
      WorkspaceNode n = getWorkspaceNode(parent);
      assert !n.isChildrenLoaded() : "Should not have loaded children";
      cache.getTransactionManager().commit();
   }
View Full Code Here

Examples of org.jboss.cache.NodeSPI.removeChild()

      prepareContextOptions();
      NodeSPI targetNode = cache.getNode(target);
      for (Object childname : targetNode.getChildrenNames())
      {
         prepareContextOptions();
         targetNode.removeChild(childname);
      }

      // set these flags to false if we have persistent state!
      targetNode.setDataLoaded(false);
      targetNode.setChildrenLoaded(false);
View Full Code Here

Examples of org.jboss.cache.OptimisticTreeNode.removeChild()

                 }

                 for (Iterator i = ((Set) deltas.get(1)).iterator(); i.hasNext();)
                 {
                    TreeNode child = (TreeNode) i.next();
                    current.removeChild(child.getName());
                 }

                  updateVersion = cache.getLockParentForChildInsertRemove();
              }
View Full Code Here

Examples of org.jboss.cache.optimistic.WorkspaceNode.removeChild()

      // pre-notify
      if (notify) notifier.notifyNodeRemoved(workspaceNode.getFqn(), true, workspaceNode.getData(), ctx);

      Fqn nodeFqn = workspaceNode.getFqn();
      parentNode.removeChild(nodeFqn.getLastElement());

      SortedMap<Fqn, WorkspaceNode> tailMap = workspace.getNodesAfter(workspaceNode.getFqn());

      for (WorkspaceNode toDelete : tailMap.values())
      {
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.