summaryrefslogtreecommitdiff
path: root/base/src/main/java/bjc/utils/funcutils/TreeUtils.java
diff options
context:
space:
mode:
authorBenjamin J. Culkin <bjculkin@mix.wvu.edu>2021-07-12 15:53:22 -0300
committerBenjamin J. Culkin <bjculkin@mix.wvu.edu>2021-07-12 15:53:22 -0300
commita24c1042499f76ff2d442ae133ef165011a7af4c (patch)
tree1a0bdff895b7dc2bd9e8006fe3b83805c7e56f4f /base/src/main/java/bjc/utils/funcutils/TreeUtils.java
parente55cb9852a106cff26517d7d1e85bc4b149884f3 (diff)
Formatting tweaks
Diffstat (limited to 'base/src/main/java/bjc/utils/funcutils/TreeUtils.java')
-rw-r--r--base/src/main/java/bjc/utils/funcutils/TreeUtils.java37
1 files changed, 17 insertions, 20 deletions
diff --git a/base/src/main/java/bjc/utils/funcutils/TreeUtils.java b/base/src/main/java/bjc/utils/funcutils/TreeUtils.java
index 41a01d8..daab8a1 100644
--- a/base/src/main/java/bjc/utils/funcutils/TreeUtils.java
+++ b/base/src/main/java/bjc/utils/funcutils/TreeUtils.java
@@ -6,21 +6,18 @@ import java.util.function.*;
import bjc.data.*;
import bjc.funcdata.*;
-/**
- * Implements various utilities for trees.
+/** Implements various utilities for trees.
*
- * @author Benjamin Culkin
- */
+ * @author Benjamin Culkin */
public class TreeUtils {
- /**
- * Convert a tree into a list of outline nodes that match a certain path.
+ /** Convert a tree into a list of outline nodes that match a certain path.
*
- * @param tre
- * The tree to outline.
- * @param leafMarker
- * The path to mark nodes with.
- * @return The list of marked paths.
- */
+ * @param <T> The type contained in the tree.
+ *
+ * @param tre The tree to outline.
+ * @param leafMarker The path to mark nodes with.
+ *
+ * @return The list of marked paths. */
public static <T> ListEx<ListEx<T>> outlineTree(Tree<T> tre, Predicate<T> leafMarker) {
ListEx<ListEx<T>> paths = new FunctionalList<>();
@@ -54,15 +51,15 @@ public class TreeUtils {
}
}
- /**
- * Performs 'variable substitution' or something along those lines on a tree.
+ /** Performs 'variable substitution' or something along those lines on a tree.
*
* @param <ContainedType> The type of element contained in the tree.
+ *
* @param tree The tree to do expansion in.
* @param marker The function to mark which nodes should be expanded.
* @param expander The function to expand nodes.
- * @return A transformed copy of the tree.
- */
+ *
+ * @return A transformed copy of the tree. */
public static <ContainedType> Tree<ContainedType> substitute(
Tree<ContainedType> tree,
Predicate<ContainedType> marker,
@@ -76,14 +73,14 @@ public class TreeUtils {
return tree;
}
- /**
- * Performs 'variable substitution' or something along those lines on a tree.
+ /** Performs 'variable substitution' or something along those lines on a tree.
*
* @param <ContainedType> The type of element contained in the tree.
+ *
* @param tree The tree to do expansion in.
* @param environment A map which contains the variables to substitute.
- * @return A transformed copy of the tree.
- */
+ *
+ * @return A transformed copy of the tree. */
public static <ContainedType> Tree<ContainedType> substitute(
Tree<ContainedType> tree,
MapEx<ContainedType, Tree<ContainedType>> environment) {