diff options
| author | bculkin2442 <bjculkin@mix.wvu.edu> | 2016-05-07 12:51:23 -0400 |
|---|---|---|
| committer | bculkin2442 <bjculkin@mix.wvu.edu> | 2016-05-07 12:51:23 -0400 |
| commit | 87ae1dfc8d8cb7b51d7bda4750ce841bbe691cfc (patch) | |
| tree | 290f31282898bd39300c70646c6fe2b65832886a /BJC-Utils2/src/main/java/bjc/utils/funcutils | |
| parent | fb7d03388e298258563c22abda1bd46cdaf991b7 (diff) | |
General changes
Diffstat (limited to 'BJC-Utils2/src/main/java/bjc/utils/funcutils')
| -rw-r--r-- | BJC-Utils2/src/main/java/bjc/utils/funcutils/StringUtils.java | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/BJC-Utils2/src/main/java/bjc/utils/funcutils/StringUtils.java b/BJC-Utils2/src/main/java/bjc/utils/funcutils/StringUtils.java index 2f8aa09..9401b7e 100644 --- a/BJC-Utils2/src/main/java/bjc/utils/funcutils/StringUtils.java +++ b/BJC-Utils2/src/main/java/bjc/utils/funcutils/StringUtils.java @@ -74,8 +74,14 @@ public class StringUtils { } } + /** + * Print out a deque with a special case for easily showing a deque is empty + * @param <ContainedType> The type in the deque + * @param queue The deque to print + * @return A string version of the deque, with allowance for an empty deque + */ public static <ContainedType> String printDeque( - Deque<ContainedType> queuedTrees) { - return queuedTrees.isEmpty() ? "(none)" : queuedTrees.toString(); + Deque<ContainedType> queue) { + return queue.isEmpty() ? "(none)" : queue.toString(); } } |
