public void useNodes(Collection<Node> nodes) { // forces creation of the array ChildrenArray arr = getArray(null); arr.useNodes(this, nodes); // assign all there nodes the new children for (Node n : nodes) { n.assignTo(EntrySupportDefault.this.children, -1); n.fireParentNodeChange(null, children.parent); } }
/** Notifies that a set of nodes has been add to * children. It is necessary that the system is already * in consistent state, so any callbacks will return * valid values. * * @param nodes list of removed nodes */ void notifyAdd(Collection<Node> nodes) { if (LOGGER.isLoggable(Level.FINER)) { LOGGER.finer("notifyAdd: " + nodes); } // notify about parent change for (Node n : nodes) { n.assignTo(children, -1); n.fireParentNodeChange(null, children.parent); } Node[] arr = nodes.toArray(new Node[nodes.size()]); Node n = children.parent; if (n != null && children.getEntrySupport() == this) { n.fireSubNodesChange(true, arr, null); } }
Node n = (Node) it.next(); n.deassignFrom(children); n.fireParentNodeChange(children.parent, null);
n.fireParentNodeChange(null, children.parent);
Node node = nodes[i]; node.deassignFrom(Children.this); node.fireParentNodeChange(oldParent, null);
node.fireParentNodeChange(null, ch.parent); return node;
Node node = nodes[i]; node.assignTo(Children.this, i); node.fireParentNodeChange(null, parent);
for (Node node : removedNodes) { node.deassignFrom(children); node.fireParentNodeChange(children.parent, null);
public void useNodes (Collection nodes) { // forces creation of the array ChildrenArray arr = getArray (null); arr.useNodes (this, nodes); // assign all there nodes the new children Iterator it = nodes.iterator (); while (it.hasNext ()) { Node n = (Node)it.next (); n.assignTo (Children.this, -1); n.fireParentNodeChange (null, parent); } }
public void useNodes (Collection nodes) { // forces creation of the array ChildrenArray arr = getArray (null); arr.useNodes (this, nodes); // assign all there nodes the new children Iterator it = nodes.iterator (); while (it.hasNext ()) { Node n = (Node)it.next (); n.assignTo (Children.this, -1); n.fireParentNodeChange (null, parent); } }
/** Notifies that a set of nodes has been add to * children. It is necessary that the system is already * in consistent state, so any callbacks will return * valid values. * * @param nodes list of removed nodes */ private void notifyAdd (Collection nodes) { // notify about parent change Iterator it = nodes.iterator (); while (it.hasNext ()) { Node n = (Node)it.next (); n.assignTo (this, -1); n.fireParentNodeChange (null, parent); } Node[] arr = (Node[])nodes.toArray (new Node[nodes.size ()]); Node n = parent; if (n != null) { n.fireSubNodesChange ( true, arr, null ); } }
/** Notifies that a set of nodes has been add to * children. It is necessary that the system is already * in consistent state, so any callbacks will return * valid values. * * @param nodes list of removed nodes */ private void notifyAdd (Collection nodes) { // notify about parent change Iterator it = nodes.iterator (); while (it.hasNext ()) { Node n = (Node)it.next (); n.assignTo (this, -1); n.fireParentNodeChange (null, parent); } Node[] arr = (Node[])nodes.toArray (new Node[nodes.size ()]); Node n = parent; if (n != null) { n.fireSubNodesChange ( true, arr, null ); } }
Node n = (Node)it.next (); n.deassignFrom (this); n.fireParentNodeChange (parent, null);
Node n = (Node)it.next (); n.deassignFrom (this); n.fireParentNodeChange (parent, null);
/** Computes the nodes now. */ final Node[] justComputeNodes () { if (map == null) { map = new HashMap (17); // debug.append ("Map initialized\n"); // NOI18N // printStackTrace(); } LinkedList l = new LinkedList (); Iterator it = entries.iterator (); while (it.hasNext ()) { Entry entry = (Entry)it.next (); Info info = findInfo (entry); try { l.addAll (info.nodes ()); } catch (RuntimeException ex) { NodeOp.warning (ex); } } Node[] arr = (Node[])l.toArray (new Node[l.size ()]); // initialize parent nodes for (int i = 0; i < arr.length; i++) { Node n = arr[i]; n.assignTo (this, i); n.fireParentNodeChange (null, parent); } return arr; }
/** Computes the nodes now. */ final Node[] justComputeNodes () { if (map == null) { map = new HashMap (17); // debug.append ("Map initialized\n"); // NOI18N // printStackTrace(); } LinkedList l = new LinkedList (); Iterator it = entries.iterator (); while (it.hasNext ()) { Entry entry = (Entry)it.next (); Info info = findInfo (entry); try { l.addAll (info.nodes ()); } catch (RuntimeException ex) { NodeOp.warning (ex); } } Node[] arr = (Node[])l.toArray (new Node[l.size ()]); // initialize parent nodes for (int i = 0; i < arr.length; i++) { Node n = arr[i]; n.assignTo (this, i); n.fireParentNodeChange (null, parent); } return arr; }
Node node = nodes[i]; node.deassignFrom (Children.this); node.fireParentNodeChange (oldParent, null);
Node node = nodes[i]; node.deassignFrom (Children.this); node.fireParentNodeChange (oldParent, null);
Node node = nodes[i]; node.assignTo (Children.this, i); node.fireParentNodeChange (null, parent);
Node node = nodes[i]; node.assignTo (Children.this, i); node.fireParentNodeChange (null, parent);