- accept(T) - Method in interface com.diffplug.common.base.Box
-
Delegates to set().
- accept(double) - Method in interface com.diffplug.common.base.Box.Dbl
-
Delegates to set().
- accept(int) - Method in interface com.diffplug.common.base.Box.Int
-
Delegates to set().
- accept(T) - Method in interface com.diffplug.common.base.Box.Nullable
-
Delegates to set().
- accept(Consumer<? super L>, Consumer<? super R>) - Method in interface com.diffplug.common.base.Either
-
Accepts either the left or the right consumer as appropriate.
- accept(Throwable) - Method in class com.diffplug.common.base.Errors
-
Passes the given error to this Errors.
- accept(Throwable) - Method in class com.diffplug.common.base.Errors.Plugins.OnErrorThrowAssertion
-
- accept(T, U) - Method in interface com.diffplug.common.base.Throwing.Specific.BiConsumer
-
- accept(T, U) - Method in interface com.diffplug.common.base.Throwing.Specific.BiPredicate
-
- accept(T) - Method in interface com.diffplug.common.base.Throwing.Specific.Consumer
-
- acceptBoth(Consumer<? super L>, Consumer<? super R>, L, R) - Method in interface com.diffplug.common.base.Either
-
Accepts both the left and right consumers, using the default values to set the empty side.
- alwaysFalse() - Static method in class com.diffplug.common.base.Predicates
-
Returns a predicate that always evaluates to false
.
- alwaysTrue() - Static method in class com.diffplug.common.base.Predicates
-
Returns a predicate that always evaluates to true
.
- and(Iterable<? extends Predicate<? super T>>) - Static method in class com.diffplug.common.base.Predicates
-
Returns a predicate that evaluates to true
if each of its
components evaluates to true
.
- and(Predicate<? super T>...) - Static method in class com.diffplug.common.base.Predicates
-
Returns a predicate that evaluates to true
if each of its
components evaluates to true
.
- and(Predicate<? super T>, Predicate<? super T>) - Static method in class com.diffplug.common.base.Predicates
-
Returns a predicate that evaluates to true
if both of its
components evaluate to true
.
- apply(T, U) - Method in interface com.diffplug.common.base.Throwing.Specific.BiFunction
-
- apply(T) - Method in interface com.diffplug.common.base.Throwing.Specific.Function
-
- asOptionalLeft() - Method in interface com.diffplug.common.base.Either
-
Returns the left side as an Optional.
- asOptionalRight() - Method in interface com.diffplug.common.base.Either
-
Returns the right side as an Optional.
- asRuntime(Throwable) - Static method in class com.diffplug.common.base.Errors
-
Casts or wraps the given exception to be a RuntimeException.
- assertEqual() - Method in interface com.diffplug.common.base.TreeComparison.SameType
-
Asserts that the trees are equal.
- assertEqualBasedOn(BiPredicate<E, A>) - Method in class com.diffplug.common.base.TreeComparison
-
Asserts that the trees are equal, based on the given
BiPredicate
.
- assertEqualMappedBy(Function<? super E, ?>, Function<? super A, ?>) - Method in class com.diffplug.common.base.TreeComparison
-
- assignableFrom(Class<?>) - Static method in class com.diffplug.common.base.Predicates
-
Returns a predicate that evaluates to true
if the class being
tested is assignable from the given class.
- asTerminal() - Method in class com.diffplug.common.base.Errors
-
Converts this Consumer<Throwable>
to a Consumer<Optional<Throwable>>
.
- captureStackBelow(Class<?>...) - Static method in class com.diffplug.common.base.StackDumper
-
Captures all of the current stack which is below the given classes.
- charException(char) - Static method in exception com.diffplug.common.base.Unhandled
-
- childrenOf(T) - Method in interface com.diffplug.common.base.TreeDef
-
Returns all the children of the given node.
- classException(Object) - Static method in exception com.diffplug.common.base.Unhandled
-
- codePointsToString(IntStream) - Static method in class com.diffplug.common.base.MoreCollectors
-
Converts a stream of unicode code points into a String.
- com.diffplug.common.base - package com.diffplug.common.base
-
- compare(T, T) - Static method in enum com.diffplug.common.base.Comparison
-
Returns a Comparison result from the two given Comparables.
- compare(Comparator<T>, T, T) - Static method in enum com.diffplug.common.base.Comparison
-
Returns a Comparison result from the two values using a Comparator.
- Comparison - Enum in com.diffplug.common.base
-
Safe representation of the result of a comparison (better than int).
- compose(Function<? super T, ? extends R>, Consumer<? super R>) - Static method in class com.diffplug.common.base.Consumers
-
- compose(Function<B, C>, Function<A, ? extends B>) - Static method in class com.diffplug.common.base.Functions
-
Returns the composition of two functions.
- compose(Predicate<B>, Function<A, ? extends B>) - Static method in class com.diffplug.common.base.Predicates
-
Returns the composition of a function and a predicate.
- compose(Function<? super F, T>, Supplier<F>) - Static method in class com.diffplug.common.base.Suppliers
-
Returns a new supplier which is the composition of the provided function
and supplier.
- constant(E) - Static method in class com.diffplug.common.base.Functions
-
Creates a function that returns value
for any input.
- Consumers - Class in com.diffplug.common.base
-
Helper functions for manipulating
Consumer
.
- Consumers() - Constructor for class com.diffplug.common.base.Consumers
-
- contains(Pattern) - Static method in class com.diffplug.common.base.Predicates
-
Returns a predicate that evaluates to true
if the
CharSequence
being tested contains any match for the given
regular expression pattern.
- containsPattern(String) - Static method in class com.diffplug.common.base.Predicates
-
Returns a predicate that evaluates to true
if the
CharSequence
being tested contains any match for the given
regular expression pattern.
- copy() - Method in class com.diffplug.common.base.TreeNode
-
Creates a deep copy of this TreeNode.
- copy(TreeDef<T>, T) - Static method in class com.diffplug.common.base.TreeNode
-
Creates a hierarchy of TreeNodes that copies the structure and content of the given tree.
- copy(TreeDef<T>, T, Function<? super T, ? extends R>) - Static method in class com.diffplug.common.base.TreeNode
-
Creates a hierarchy of TreeNodes that copies the structure and content of the given tree,
using mapper
to calculate the content of the nodes.
- copyLeavesIn(TreeDef<T>, T, BiFunction<T, List<CopyType>, CopyType>) - Static method in class com.diffplug.common.base.TreeQuery
-
Copies the given tree of T to CopyType, starting at the leaf nodes
of the tree and moving in to the root node, which allows CopyType to
be immutable (but does not require it).
- copyRootOut(TreeDef<T>, T, BiFunction<T, CopyType, CopyType>) - Static method in class com.diffplug.common.base.TreeQuery
-
Copies the given tree of T to CopyType, starting at the root node
of the tree and moving out to the leaf nodes, which generally requires
CopyType to be mutable (if you want CopyType nodes to know who their
children are).
- create(L, R) - Static method in interface com.diffplug.common.base.Either
-
Creates a left or right, depending on which element is non-null.
- createHandling(Consumer<Throwable>) - Static method in class com.diffplug.common.base.Errors
-
Creates an Errors.Handling which passes any exceptions it receives
to the given handler.
- createLeft(L) - Static method in interface com.diffplug.common.base.Either
-
Creates an instance of Left.
- createRethrowing(Function<Throwable, RuntimeException>) - Static method in class com.diffplug.common.base.Errors
-
Creates an Errors.Rethrowing which transforms any exceptions it receives into a RuntimeException
as specified by the given function, and then throws that RuntimeException.
- createRight(R) - Static method in interface com.diffplug.common.base.Either
-
Creates an instance of Right.
- createTestData(String...) - Static method in class com.diffplug.common.base.TreeNode
-
Creates a hierarchy of TreeNode<String>
using an easy-to-read array of strings.
- decorateErrorsWith(Function<? super E, String>, Function<? super A, String>) - Method in class com.diffplug.common.base.TreeComparison
-
Decorates errors thrown by any assertions with the given functions.
- decorateErrorsWith(Function<? super T, String>) - Method in interface com.diffplug.common.base.TreeComparison.SameType
-
Decorates errors thrown by any assertions with the given functions.
- Default(double) - Constructor for class com.diffplug.common.base.Box.Dbl.Default
-
- Default(T) - Constructor for class com.diffplug.common.base.Box.Default
-
- Default(int) - Constructor for class com.diffplug.common.base.Box.Int.Default
-
- Default(T) - Constructor for class com.diffplug.common.base.Box.Nullable.Default
-
- defaultDialog(Throwable) - Static method in interface com.diffplug.common.base.Errors.Plugins
-
Default behavior of
Errors.dialog
is @{code JOptionPane.showMessageDialog} without a parent.
- defaultLog(Throwable) - Static method in interface com.diffplug.common.base.Errors.Plugins
-
Default behavior of
Errors.log
is @{code Throwable.printStackTrace()}.
- depthFirst(TreeDef<T>, T) - Static method in class com.diffplug.common.base.TreeIterable
-
Creates an Iterable
that starts at node
and iterates deeper into the tree in a depth-first order.
- depthFirst(TreeDef<T>, T) - Static method in class com.diffplug.common.base.TreeStream
-
Creates a Stream
that starts at node
and iterates deeper into the tree in a depth-first order.
- dialog() - Static method in class com.diffplug.common.base.Errors
-
Opens a dialog to notify the user of any exceptions.
- doNothing() - Static method in class com.diffplug.common.base.Consumers
-
A Consumer which does nothing.
- doubleException(double) - Static method in exception com.diffplug.common.base.Unhandled
-
- dump(String, List<StackTraceElement>) - Static method in class com.diffplug.common.base.StackDumper
-
Dumps the given message and stack to the system error console.
- dump(String, StackTraceElement[]) - Static method in class com.diffplug.common.base.StackDumper
-
Dumps the given message and stack to the system error console.
- dump(String, Throwable) - Static method in class com.diffplug.common.base.StackDumper
-
Dumps the given message and exception stack to the system error console
- dump(String) - Static method in class com.diffplug.common.base.StackDumper
-
Dumps the current stack to the system error console.
- dump(String, int, String...) - Static method in class com.diffplug.common.base.StackDumper
-
Dumps the first stackLimit
frames of the current stack to the system error console, excluding traces from classPrefixesToExclude
.
- dumpAll(String, Object) - Static method in class com.diffplug.common.base.FieldsAndGetters
-
Dumps all fields and getters of obj
to System.out
.
- dumpAll(String, Object, StringPrinter) - Static method in class com.diffplug.common.base.FieldsAndGetters
-
Dumps all fields and getters of obj
to printer
.
- dumpIf(String, Object, Predicate<String>, Predicate<Map.Entry<String, Object>>, StringPrinter) - Static method in class com.diffplug.common.base.FieldsAndGetters
-
Passes each field and getter of obj
to evalPredicate
, grabs its value if it passes, and if the value passes dumpPredicate
then it is dumped to printer
.
- dumpNonNull(String, Object) - Static method in class com.diffplug.common.base.FieldsAndGetters
-
Dumps all non-null fields and getters of obj
to System.out
.
- dumpNonNull(String, Object, StringPrinter) - Static method in class com.diffplug.common.base.FieldsAndGetters
-
Dumps all non-null fields and getters of obj
to printer
.
- dumpWhenSysErrContains(String) - Static method in class com.diffplug.common.base.StackDumper
-
Dumps a stack trace anytime trigger string is printed to System.err.
- dumpWhenSysOutContains(String) - Static method in class com.diffplug.common.base.StackDumper
-
Dumps a stack trace anytime the trigger string is printed to System.out.
- DurianPlugins - Class in com.diffplug.common.base
-
A programmatic and pluggable implementation of public static final
.
- fields(Object) - Static method in class com.diffplug.common.base.FieldsAndGetters
-
Returns a Stream
of all public fields and their values for the given object.
- fields(Object, Predicate<Field>) - Static method in class com.diffplug.common.base.FieldsAndGetters
-
Returns a Stream
of all public fields which match predicate
and their values for the given object.
- FieldsAndGetters - Class in com.diffplug.common.base
-
Utilities for obtaining the fields and getter methods of an object using reflection.
- FieldsAndGetters() - Constructor for class com.diffplug.common.base.FieldsAndGetters
-
- fieldsAndGetters(Object) - Static method in class com.diffplug.common.base.FieldsAndGetters
-
Returns a Stream
of all public fields and getter methods and their values for the given object.
- fieldsAndGetters(Object, Predicate<String>) - Static method in class com.diffplug.common.base.FieldsAndGetters
-
Returns a Stream
of all public fields and getter methods which match predicate
and their values for the given object.
- FieldsAndGetters.ObjectIsNull - Class in com.diffplug.common.base
-
Sentinel class for null objects.
- filter(Predicate<T>) - Method in interface com.diffplug.common.base.TreeDef
-
Creates a new TreeDef which whose childrenOf
method is filtered by the given predicate.
- filter(Predicate<T>) - Method in interface com.diffplug.common.base.TreeDef.Parented
-
Creates a new TreeDef.Parented
whose childrenOf
and parentOf
methods are filtered by predicate
.
- filteredList(List<T>, Predicate<T>) - Static method in interface com.diffplug.common.base.TreeDef
-
Returns a filtered version of the given list.
- findByContent(T) - Method in class com.diffplug.common.base.TreeNode
-
Searches breadth-first for the TreeNode with the given content.
- findByPath(T...) - Method in class com.diffplug.common.base.TreeNode
-
Finds a child TreeNode based on its path.
- findByPath(List<T>) - Method in class com.diffplug.common.base.TreeNode
-
- findByPath(TreeDef<T>, T, List<P>, BiPredicate<T, P>) - Static method in class com.diffplug.common.base.TreeQuery
-
Finds a child TreeNode based on its path.
- findByPath(TreeDef<T>, T, Function<? super T, ?>, List<P>, Function<? super P, ?>) - Static method in class com.diffplug.common.base.TreeQuery
-
Finds a child TreeNode based on its path.
- findByPath(TreeDef<T>, T, List<T>, Function<? super T, ?>) - Static method in class com.diffplug.common.base.TreeQuery
-
Finds a child TreeNode based on its path.
- floatException(float) - Static method in exception com.diffplug.common.base.Unhandled
-
- fold(Function<? super L, ? extends T>, Function<? super R, ? extends T>) - Method in interface com.diffplug.common.base.Either
-
Applies either the left or the right function as appropriate.
- forFile(Consumer<Throwable>) - Static method in interface com.diffplug.common.base.TreeDef
-
An instance of
TreeDef.Parented
for
File
.
- forMap(Map<K, V>) - Static method in class com.diffplug.common.base.Functions
-
Returns a function which performs a map lookup.
- forMap(Map<K, ? extends V>, V) - Static method in class com.diffplug.common.base.Functions
-
Returns a function which performs a map lookup with a default value.
- forPath(Consumer<Throwable>) - Static method in interface com.diffplug.common.base.TreeDef
-
An instance of
TreeDef.Parented
for
Path
.
- forPredicate(Predicate<T>) - Static method in class com.diffplug.common.base.Functions
-
Creates a function that returns the same boolean output as the given predicate for all inputs.
- forSupplier(Supplier<T>) - Static method in class com.diffplug.common.base.Functions
-
Returns a function that always returns the result of invoking
Supplier.get()
on
supplier
, regardless of its input.
- from(DoubleSupplier, DoubleConsumer) - Static method in interface com.diffplug.common.base.Box.Dbl
-
Creates a Box.Double from a Supplier and a Consumer.
- from(Supplier<T>, Consumer<T>) - Static method in interface com.diffplug.common.base.Box
-
Creates a Box from a Supplier and a Consumer.
- from(V, Function<V, T>, BiConsumer<V, T>) - Static method in interface com.diffplug.common.base.Box
-
Creates a Box from an argument and two functions which operate on that argument.
- from(IntSupplier, IntConsumer) - Static method in interface com.diffplug.common.base.Box.Int
-
Creates a Box.Double from a Supplier and a Consumer.
- from(Supplier<T>, Consumer<T>) - Static method in interface com.diffplug.common.base.Box.Nullable
-
Creates a Nullable from a Supplier and a Consumer.
- from(V, Function<V, T>, BiConsumer<V, T>) - Static method in interface com.diffplug.common.base.Box.Nullable
-
Creates a Nullable from an argument and two functions which operate on that argument.
- from(int) - Static method in enum com.diffplug.common.base.Comparison
-
Returns a Comparison from the given result of a call to Comparable.compareTo()
or Comparator.compare
.
- Functions - Class in com.diffplug.common.base
-
Helper functions for manipulating
Function
, copied from Guava.
- get() - Method in class com.diffplug.common.base.Box.Dbl.Default
-
- get() - Method in interface com.diffplug.common.base.Box.Dbl
-
Returns the boxed value.
- get() - Method in class com.diffplug.common.base.Box.Default
-
- get() - Method in class com.diffplug.common.base.Box.Int.Default
-
- get() - Method in interface com.diffplug.common.base.Box.Int
-
Returns the boxed value.
- get() - Method in class com.diffplug.common.base.Box.Nullable.Default
-
- get(Class<T>, T) - Static method in class com.diffplug.common.base.DurianPlugins
-
Returns an instance of pluginClass which is guaranteed to be identical throughout
the runtime existence of this library.
- get(Throwing.Supplier<T>) - Method in class com.diffplug.common.base.Errors.Rethrowing
-
Attempts to call supplier
and rethrows any exceptions as unchecked exceptions.
- get() - Method in interface com.diffplug.common.base.Throwing.Specific.Supplier
-
- getAsDouble() - Method in interface com.diffplug.common.base.Box.Dbl
-
Delegates to get().
- getAsInt() - Method in interface com.diffplug.common.base.Box.Int
-
Delegates to get().
- getChildren() - Method in class com.diffplug.common.base.TreeNode
-
Returns the children of this TreeNode.
- getContent() - Method in class com.diffplug.common.base.TreeNode
-
Returns the object which is encapsulated by this TreeNode.
- getLeft() - Method in interface com.diffplug.common.base.Either
-
Returns the left side.
- getLeft() - Method in class com.diffplug.common.base.Either.Left
-
- getLeft() - Method in class com.diffplug.common.base.Either.Right
-
- getParent() - Method in class com.diffplug.common.base.TreeNode
-
Returns the (possibly-null) parent of this TreeNode.
- getPath() - Method in class com.diffplug.common.base.TreeNode
-
Returns the path of this node, using the content's toString()
method and /
as the delimiter.
- getPath(Function<? super T, String>) - Method in class com.diffplug.common.base.TreeNode
-
Returns the path of this node, using the given toString
method and /
as the delimiter.
- getPath(Function<? super T, String>, String) - Method in class com.diffplug.common.base.TreeNode
-
Returns the path of this node, using the given toString
method and delimiter
.
- getRight() - Method in interface com.diffplug.common.base.Either
-
Returns the right side.
- getRight() - Method in class com.diffplug.common.base.Either.Left
-
- getRight() - Method in class com.diffplug.common.base.Either.Right
-
- getters(Object) - Static method in class com.diffplug.common.base.FieldsAndGetters
-
Returns a Stream
of all public getter methods and their return values for the given object.
- getters(Object, Predicate<Method>) - Static method in class com.diffplug.common.base.FieldsAndGetters
-
Returns a Stream
of all public getter methods which match predicate
and their return values for the given object.
- getWithDefault(Throwing.Supplier<T>, T) - Method in class com.diffplug.common.base.Errors.Handling
-
Attempts to call supplier
and returns onFailure
if an exception is thrown.
- obj - Variable in class com.diffplug.common.base.Box.Dbl.Default
-
The (possibly-null) object being held.
- obj - Variable in class com.diffplug.common.base.Box.Default
-
The (possibly-null) object being held.
- obj - Variable in class com.diffplug.common.base.Box.Int.Default
-
The (possibly-null) object being held.
- obj - Variable in class com.diffplug.common.base.Box.Nullable.Default
-
The (possibly-null) object being held.
- objectException(Object) - Static method in exception com.diffplug.common.base.Unhandled
-
- ObjectIsNull() - Constructor for class com.diffplug.common.base.FieldsAndGetters.ObjectIsNull
-
- of(double) - Static method in interface com.diffplug.common.base.Box.Dbl
-
Returns a Box wrapped around the given double.
- of(int) - Static method in interface com.diffplug.common.base.Box.Int
-
Returns a Box wrapped around the given double.
- of(T) - Static method in interface com.diffplug.common.base.Box.Nullable
-
Creates a Nullable of the given object.
- of(T) - Static method in interface com.diffplug.common.base.Box
-
Creates a Box holding the given value.
- of(TreeDef<E>, E, TreeDef<A>, A) - Static method in class com.diffplug.common.base.TreeComparison
-
- of(TreeDef<T>, T, T) - Static method in class com.diffplug.common.base.TreeComparison
-
- of(TreeNode<T>, TreeDef<T>, T) - Static method in class com.diffplug.common.base.TreeComparison
-
- of(TreeNode<T>, TreeDef<U>, U, Function<? super U, ? extends T>) - Static method in class com.diffplug.common.base.TreeComparison
-
- of(TreeNode<T>, TreeNode<T>) - Static method in class com.diffplug.common.base.TreeComparison
-
- of(Function<T, List<T>>) - Static method in interface com.diffplug.common.base.TreeDef
-
Creates a TreeDef which is implemented by the given function.
- of(Function<T, List<T>>, Function<T, T>) - Static method in interface com.diffplug.common.base.TreeDef.Parented
-
Creates a new TreeDef.Parented
which is implemented by the two given functions.
- ofInstance(T) - Static method in class com.diffplug.common.base.Suppliers
-
Returns a supplier that always supplies instance
.
- ofNull() - Static method in interface com.diffplug.common.base.Box.Nullable
-
Creates an Nullable holding null.
- OnErrorThrowAssertion() - Constructor for class com.diffplug.common.base.Errors.Plugins.OnErrorThrowAssertion
-
- operationException() - Static method in exception com.diffplug.common.base.Unhandled
-
- or(Iterable<? extends Predicate<? super T>>) - Static method in class com.diffplug.common.base.Predicates
-
Returns a predicate that evaluates to true
if any one of its
components evaluates to true
.
- or(Predicate<? super T>...) - Static method in class com.diffplug.common.base.Predicates
-
Returns a predicate that evaluates to true
if any one of its
components evaluates to true
.
- or(Predicate<? super T>, Predicate<? super T>) - Static method in class com.diffplug.common.base.Predicates
-
Returns a predicate that evaluates to true
if either of its
components evaluates to true
.
- set(double) - Method in class com.diffplug.common.base.Box.Dbl.Default
-
- set(double) - Method in interface com.diffplug.common.base.Box.Dbl
-
Sets the value which will later be returned by get().
- set(T) - Method in class com.diffplug.common.base.Box.Default
-
- set(int) - Method in class com.diffplug.common.base.Box.Int.Default
-
- set(int) - Method in interface com.diffplug.common.base.Box.Int
-
Sets the value which will later be returned by get().
- set(T) - Method in class com.diffplug.common.base.Box.Nullable.Default
-
- set(T) - Method in interface com.diffplug.common.base.Box.Nullable
-
Sets the value which will later be returned by get().
- set(T) - Method in interface com.diffplug.common.base.Box
-
Sets the value which will later be returned by get().
- setContent(T) - Method in class com.diffplug.common.base.TreeNode
-
Sets the object which is encapsulated by this TreeNode.
- shortException(short) - Static method in exception com.diffplug.common.base.Unhandled
-
- singleOrEmpty() - Static method in class com.diffplug.common.base.MoreCollectors
-
Collector which traverses a stream and returns either a single element
(if there was only one element) or empty (if there were 0 or more than 1
elements).
- singleOrEmptyShortCircuiting(Stream<T>) - Static method in class com.diffplug.common.base.MoreCollectors
-
- sortChildrenByContent(Comparator<? super T>) - Method in class com.diffplug.common.base.TreeNode
-
Recursively sorts all children using the given comparator of their content.
- sortChildrenByNode(Comparator<TreeNode<T>>) - Method in class com.diffplug.common.base.TreeNode
-
Recursively sorts all children using the given comparator of TreeNode.
- StackDumper - Class in com.diffplug.common.base
-
Utility methods for dumping the stack - arbitrarily or at specific trigger points (such as when a certain string prints to console).
- StackDumper() - Constructor for class com.diffplug.common.base.StackDumper
-
- stringException(String) - Static method in exception com.diffplug.common.base.Unhandled
-
- StringPrinter - Class in com.diffplug.common.base
-
Pipes strings to a Consumer<String>
through an API similar to PrintWriter and PrintStream.
- StringPrinter(Consumer<String>) - Constructor for class com.diffplug.common.base.StringPrinter
-
StringPrinter will pass all the strings it receives to the given consumer.
- stringsToLines(Consumer<String>) - Static method in class com.diffplug.common.base.StringPrinter
-
Given a consumer of lines, creates a stateful consumer of strings
which will combine its input until it finds a newline, and
split its input when it contains multiple newlines.
- supplierFunction() - Static method in class com.diffplug.common.base.Suppliers
-
Returns a function that accepts a supplier and returns the result of
invoking
Supplier.get()
on that supplier.
- Suppliers - Class in com.diffplug.common.base
-
Helper functions for manipulating
Supplier
, copied from Guava.
- suppress() - Static method in class com.diffplug.common.base.Errors
-
Suppresses errors entirely.
- synchronizedSupplier(Supplier<T>) - Static method in class com.diffplug.common.base.Suppliers
-
Returns a supplier whose get()
method synchronizes on
delegate
before calling it, making it thread-safe.
- systemErr() - Static method in class com.diffplug.common.base.StringPrinter
-
- systemOut() - Static method in class com.diffplug.common.base.StringPrinter
-
- test(T) - Method in interface com.diffplug.common.base.Throwing.Specific.Predicate
-
- Throwing - Interface in com.diffplug.common.base
-
Variations on the standard functional interfaces which throw Throwable.
- Throwing.BiConsumer<T,U> - Interface in com.diffplug.common.base
-
- Throwing.BiFunction<T,U,R> - Interface in com.diffplug.common.base
-
- Throwing.BiPredicate<T,U> - Interface in com.diffplug.common.base
-
- Throwing.Consumer<T> - Interface in com.diffplug.common.base
-
- Throwing.Function<T,R> - Interface in com.diffplug.common.base
-
- Throwing.Predicate<T> - Interface in com.diffplug.common.base
-
- Throwing.Runnable - Interface in com.diffplug.common.base
-
- Throwing.Specific - Interface in com.diffplug.common.base
-
Variations on the standard functional interfaces which throw a specific subclass of Throwable.
- Throwing.Specific.BiConsumer<T,U,E extends Throwable> - Interface in com.diffplug.common.base
-
- Throwing.Specific.BiFunction<T,U,R,E extends Throwable> - Interface in com.diffplug.common.base
-
- Throwing.Specific.BiPredicate<T,U,E extends Throwable> - Interface in com.diffplug.common.base
-
- Throwing.Specific.Consumer<T,E extends Throwable> - Interface in com.diffplug.common.base
-
- Throwing.Specific.Function<T,R,E extends Throwable> - Interface in com.diffplug.common.base
-
- Throwing.Specific.Predicate<T,E extends Throwable> - Interface in com.diffplug.common.base
-
- Throwing.Specific.Runnable<E extends Throwable> - Interface in com.diffplug.common.base
-
- Throwing.Specific.Supplier<T,E extends Throwable> - Interface in com.diffplug.common.base
-
- Throwing.Supplier<T> - Interface in com.diffplug.common.base
-
- toOutputStream(Charset) - Method in class com.diffplug.common.base.StringPrinter
-
Creates an OutputStream which will print its content to the given StringPrinter, encoding bytes according to the given Charset.
- toParent(TreeDef.Parented<T>, T) - Static method in class com.diffplug.common.base.TreeIterable
-
Creates an Iterable
that starts at node
and ends at its root parent.
- toParent(TreeDef.Parented<T>, T, T) - Static method in class com.diffplug.common.base.TreeQuery
-
Creates a mutable list whose first element is node
, and last element is parent
.
- toParent(TreeDef.Parented<T>, T) - Static method in class com.diffplug.common.base.TreeStream
-
Creates a Stream
that starts at node
and ends at its root parent.
- toPrintStream() - Method in class com.diffplug.common.base.StringPrinter
-
Creates a UTF-8 PrintStream which passes its content to this StringPrinter.
- toPrintStream(Charset) - Method in class com.diffplug.common.base.StringPrinter
-
Creates a PrintStream of the given charset, which passes its content to this StringPrinter.
- toPrintWriter() - Method in class com.diffplug.common.base.StringPrinter
-
Creates a PrintWriter which passes its content to this StringPrinter.
- toRoot(TreeDef.Parented<T>, T) - Static method in class com.diffplug.common.base.TreeQuery
-
Creates a mutable list whose first element is node
, and last element is its root parent.
- toString() - Method in class com.diffplug.common.base.Box.Dbl.Default
-
- toString() - Method in class com.diffplug.common.base.Box.Default
-
- toString() - Method in class com.diffplug.common.base.Box.Int.Default
-
- toString() - Method in class com.diffplug.common.base.Box.Nullable.Default
-
- toString() - Method in class com.diffplug.common.base.Either.Left
-
- toString() - Method in class com.diffplug.common.base.Either.Right
-
- toString() - Method in class com.diffplug.common.base.TreeNode
-
- toString(TreeDef<T>, T) - Static method in class com.diffplug.common.base.TreeQuery
-
Converts the entire tree into a string-based representation.
- toString(TreeDef<T>, T, Function<? super T, String>) - Static method in class com.diffplug.common.base.TreeQuery
-
Converts the entire tree into a string-based representation.
- toString(TreeDef<T>, T, Function<? super T, String>, String) - Static method in class com.diffplug.common.base.TreeQuery
-
Converts the entire tree into a string-based representation.
- toStringDeep() - Method in class com.diffplug.common.base.TreeNode
-
Returns a "deep" toString, including the entire tree below this level.
- toWriter() - Method in class com.diffplug.common.base.StringPrinter
-
Creates a Writer which passes its content to this StringPrinter.
- TreeComparison<E,A> - Class in com.diffplug.common.base
-
A mechanism for comparing trees.
- TreeComparison.SameType<T> - Interface in com.diffplug.common.base
-
An API for comparing trees which have been mapped to the same type.
- TreeDef<T> - Interface in com.diffplug.common.base
-
A function which defines a tree structure.
- treeDef() - Static method in class com.diffplug.common.base.TreeNode
-
- TreeDef.Parented<T> - Interface in com.diffplug.common.base
-
A pair of functions which define a doubly-linked tree, where nodes know about both their parent and their children.
- TreeIterable - Class in com.diffplug.common.base
-
Creates
Iterable
s that iterate across a tree defined by a
TreeDef
in various orders.
- TreeNode<T> - Class in com.diffplug.common.base
-
Class for manually constructing a tree, or for copying an existing tree.
- TreeNode(TreeNode<T>, T) - Constructor for class com.diffplug.common.base.TreeNode
-
Creates a TreeNode with the given parent and content.
- TreeNode(TreeNode<T>, T, int) - Constructor for class com.diffplug.common.base.TreeNode
-
Creates a TreeNode with the given parent, content, and initial child capacity.
- TreeQuery - Class in com.diffplug.common.base
-
Queries against
TreeDef
trees, e.g.
- TreeQuery() - Constructor for class com.diffplug.common.base.TreeQuery
-
- TreeStream - Class in com.diffplug.common.base
-
Creates
Stream
s that iterate across a tree defined by a
TreeDef
in various orders.
- wrap(Throwing.Supplier<T>) - Method in class com.diffplug.common.base.Errors.Rethrowing
-
Returns a Supplier which wraps supplier
and rethrows any exceptions as unchecked exceptions.
- wrap(Throwing.Function<T, R>) - Method in class com.diffplug.common.base.Errors.Rethrowing
-
Returns a Function which wraps function
and rethrows any exceptions as unchecked exceptions.
- wrap(Throwing.Predicate<T>) - Method in class com.diffplug.common.base.Errors.Rethrowing
-
Returns a Predicate which wraps predicate
and rethrows any exceptions as unchecked exceptions.
- wrap(Throwing.Runnable) - Method in class com.diffplug.common.base.Errors
-
Returns a Runnable whose exceptions are handled by this Errors.
- wrap(Throwing.Consumer<T>) - Method in class com.diffplug.common.base.Errors
-
Returns a Consumer whose exceptions are handled by this Errors.
- wrapAndDumpWhenContains(PrintStream, String) - Static method in class com.diffplug.common.base.StackDumper
-
Returns a PrintStream which will redirect all of its output to the source PrintStream.
- wrapFunction(Throwing.Function<T, R>) - Method in class com.diffplug.common.base.Errors.Rethrowing
-
Returns a Function which wraps function
and rethrows any exceptions as unchecked exceptions.
- wrapFunctionWithDefault(Throwing.Function<T, R>, R) - Method in class com.diffplug.common.base.Errors.Handling
-
Returns a Function which wraps function
and returns onFailure
if an exception is thrown.
- WrappedAsRuntimeException(Throwable) - Constructor for exception com.diffplug.common.base.Errors.WrappedAsRuntimeException
-
- wrapPredicate(Throwing.Predicate<T>) - Method in class com.diffplug.common.base.Errors.Rethrowing
-
Returns a Predicate which wraps predicate
and rethrows any exceptions as unchecked exceptions.
- wrapPredicateWithDefault(Throwing.Predicate<T>, boolean) - Method in class com.diffplug.common.base.Errors.Handling
-
Returns a Predicate which wraps predicate
and returns onFailure
if an exception is thrown.
- wrapWithDefault(Throwing.Supplier<T>, T) - Method in class com.diffplug.common.base.Errors.Handling
-
Returns a Supplier which wraps supplier
and returns onFailure
if an exception is thrown.
- wrapWithDefault(Throwing.Function<T, R>, R) - Method in class com.diffplug.common.base.Errors.Handling
-
Returns a Function which wraps function
and returns onFailure
if an exception is thrown.
- wrapWithDefault(Throwing.Predicate<T>, boolean) - Method in class com.diffplug.common.base.Errors.Handling
-
Returns a Predicate which wraps predicate
and returns onFailure
if an exception is thrown.