@Override @Deprecated public boolean add(Node[] arr) { return original.getChildren().add(arr); }
/** Look for a node child of given name. * @param node node to search in * @param name name of child to look for * @return the found child, or <code>null</code> if there is no such child */ public static Node findChild(Node node, String name) { return node.getChildren().findChild(name); }
/** Create children. * @param or original node to take children from */ public Children(Node or) { this(or, or.getChildren().isLazy()); }
/** Package private constructor to allow construction only * @param node the node that has changed * @param newIndices new indexes of the nodes */ NodeReorderEvent(Node n, int[] newIndices) { super(n); this.newIndices = newIndices; this.currSnapshot = n.getChildren().snapshot(); }
@Override @Deprecated public boolean remove(Node[] arr) { return original.getChildren().remove(arr); }
/** Package private constructor to allow construction only * @param n node that should fire change * @param add true if nodes has been added * @param delta array of nodes that have changed * @param from nodes to find indices in */ NodeMemberEvent(Node n, boolean add, Node[] delta, Node[] from) { super(n); this.add = add; this.delta = delta; this.prevSnapshot = from != null ? Arrays.asList(from) : null; this.currSnapshot = n.getChildren().snapshot(); }
public void traverse(Node child){ // post order traversal for(Node each : child.getChildren()){ traverse(each); } this.printData(); }
@Override public int callGetNodesCount(boolean optimalResult) { return original.getChildren().getNodesCount(optimalResult); }
@Override public int callGetNodesCount(boolean optimalResult) { int cnt = 0; if (optimalResult) { cnt = original.getChildren().getNodesCount(true); } int ret = Children.this.getNodesCount(); LOG.log(Level.FINEST, "Count {1} gives {2}", new Object[]{cnt, ret}); return ret; }
public Node[] callGetNodes(boolean optimalResult) { Node[] hold = null; if (optimalResult) { hold = original.getChildren().getNodes(true); } hold = Children.this.getNodes(); return hold; }
public Node[] callGetNodes(boolean optimalResult) { Node[] hold = null; if (optimalResult) { hold = original.getChildren().getNodes(true); } hold = Children.this.getNodes(); return hold; }
public Node findChild(String name) { Node dontGC = original.getChildren().findChild(name); return Children.super.findChild(name); }
public Node findChild(String name) { original.getChildren().findChild(name); return Children.super.findChild(name); }
LOGGER.finer(" old original children: " + this.original.getChildren()); // NOI18N LOGGER.finer(" old original lazy support: " + this.original.getChildren().lazySupport); // NOI18N LOGGER.finer(" new original: " + original); // NOI18N LOGGER.finer(" new original children: " + original.getChildren()); // NOI18N LOGGER.finer(" new original lazy support: " + original.getChildren().lazySupport); // NOI18N LOGGER.finer(" Children adapter: " + nodeL); // NOI18N
private void updateKeys() { final boolean LOG_ENABLED = LOGGER.isLoggable(Level.FINER); if (LOG_ENABLED) { LOGGER.finer("updateKeys() " + this); // NOI18N } ChildrenAdapter cha = nodeL; if (cha != null) { if (LOG_ENABLED) { LOGGER.finer(" getting original nodes"); // NOI18N } Node[] arr = original.getChildren().getNodes(); if (LOG_ENABLED) { LOGGER.finer(" setKeys(), keys: " + Arrays.toString(arr)); // NOI18N } setKeys(arr); if (!origSupport.isInitialized()) { origSupport.notifySetEntries(); } } }
/** Find the node. * @return the found node * @exception IOException if the parent cannot be recreated * @exception NodeNotFoundException if the path is not valid (exception may be examined for details) */ public Node getNode() throws java.io.IOException { Node parentNode = parent.getNode(); Node child = parentNode.getChildren().findChild(path); if (child != null) { return child; } else { throw new NodeNotFoundException(parentNode, path, 0); } }
@Override void switchSupport(boolean toLazy) { try { Children.PR.enterWriteAccess(); ((Children.Keys) original.getChildren()).switchSupport(toLazy); super.switchSupport(toLazy); } finally { Children.PR.exitWriteAccess(); } }
private boolean checkSupportChanged() { FilterChildrenSupport support = (FilterChildrenSupport) entrySupport(); EntrySupport origSupport = original.getChildren().entrySupport(); if (support.originalSupport() != origSupport) { assert Children.MUTEX.isWriteAccess() : "Should be called only under write access"; // NOI18N changeSupport(null); return true; } else { return false; } }
Node foundChild = parentNode.getChildren().findChild(childPath); if (foundChild != node) { Logger.getLogger(DefaultHandle.class.getName()).log(Level.WARNING,
node.hasChanges() && node.getChildren().isEmpty()) { MongoDiffHistoryChangeItem diffItem = new MongoDiffHistoryChangeItem(); diffItem.setPath(node.getPropertyPath().toString());