summaryrefslogtreecommitdiff
path: root/BJC-Utils2/src/main/java/bjc/utils/data/IPair.java
diff options
context:
space:
mode:
Diffstat (limited to 'BJC-Utils2/src/main/java/bjc/utils/data/IPair.java')
-rw-r--r--BJC-Utils2/src/main/java/bjc/utils/data/IPair.java15
1 files changed, 11 insertions, 4 deletions
diff --git a/BJC-Utils2/src/main/java/bjc/utils/data/IPair.java b/BJC-Utils2/src/main/java/bjc/utils/data/IPair.java
index 9da7d22..fcf2b05 100644
--- a/BJC-Utils2/src/main/java/bjc/utils/data/IPair.java
+++ b/BJC-Utils2/src/main/java/bjc/utils/data/IPair.java
@@ -16,7 +16,8 @@ public interface IPair<L, R> {
* The function to apply to the right value.
* @return A new pair containing the two modified values.
*/
- <L2, R2> IPair<L2, R2> apply(Function<L, L2> lf, Function<R, R2> rf);
+ public <L2, R2> IPair<L2, R2> apply(Function<L, L2> lf,
+ Function<R, R2> rf);
/**
* Collapse this pair to a single value. Does not change the internal
@@ -26,8 +27,14 @@ public interface IPair<L, R> {
* The function to use to collapse the pair.
* @return The collapsed value.
*/
- <E> E merge(BiFunction<L, R, E> bf);
-
- void doWith(BiConsumer<L, R> bc);
+ public <E> E merge(BiFunction<L, R, E> bf);
+ /**
+ * Execute an action with the values of this pair. Has no effect on the
+ * internal contents
+ *
+ * @param bc
+ * The action to execute on the values
+ */
+ public void doWith(BiConsumer<L, R> bc);
} \ No newline at end of file