public abstract class TreeNodeFilter extends org.osgl.Osgl.F2<java.util.List<? extends TreeNode>,TreeNode,java.lang.Boolean>
A TreeNodeFilter can be applied to a TreeNode and check if it applied to the filter
| Modifier and Type | Class and Description |
|---|---|
static class |
TreeNodeFilter.Common |
| Constructor and Description |
|---|
TreeNodeFilter() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Boolean |
apply(java.util.List<? extends TreeNode> path,
TreeNode theNode)
Apply the filter on a
TreeNode and check the result. |
protected abstract boolean |
test(java.util.List<? extends TreeNode> path,
TreeNode theNode)
Sub class should implement the filter logic in this method
|
public final java.lang.Boolean apply(java.util.List<? extends TreeNode> path, TreeNode theNode)
Apply the filter on a TreeNode and check the result.
This method will call the test(List, TreeNode) to get the result
path - a list of tree node that are ancestors of the nodetheNode - the tree node to be evaluatedtrue if the node applied to the filter or false otherwiseprotected abstract boolean test(java.util.List<? extends TreeNode> path, TreeNode theNode)
Sub class should implement the filter logic in this method
path - a list of tree node that are ancestors of the nodetheNode - the tree node to be evaluatedtrue if the node applied to the filter or false otherwiseCopyright © 2014–2017 ActFramework. All rights reserved.