Skip to content

Commit 3cfe360

Browse files
committed
Add javadoc
1 parent bb1f72e commit 3cfe360

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

src/main/java/net/imglib2/algorithm/blocks/AbstractBlockSupplier.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66
import net.imglib2.util.CloseableThreadLocal;
77

88
/**
9+
* Boilerplate for {@link BlockSupplier} to simplify implementations.
10+
* <p>
911
* Implements {@link BlockSupplier#threadSafe()} as a wrapper that makes {@link
1012
* ThreadLocal} {@link BlockSupplier#independentCopy()} copies.
1113
*/

src/main/java/net/imglib2/algorithm/blocks/DefaultUnaryBlockOperator.java

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,23 @@
3838
import net.imglib2.util.Cast;
3939
import net.imglib2.util.CloseableThreadLocal;
4040

41+
/**
42+
* Default implementation of {@link UnaryBlockOperator}.
43+
* <p>
44+
* If you implement a {@code BlockProcessor<I,O>}, you typically wrap it with a
45+
* {@code DefaultUnaryBlockOperator}, specifying the source {@code S} and target
46+
* {@code T} ImgLib2 {@code NativeType}s corresponding to primitive array types
47+
* {@code I} and {@code O}, and the number of source and target dimension.
48+
* <p>
49+
* The {@link UnaryBlockOperator} can then be used in {@link
50+
* BlockSupplier#andThen(UnaryBlockOperator)} chains in a type- and
51+
* simensionality-safe manner.
52+
*
53+
* @param <S>
54+
* source type
55+
* @param <T>
56+
* target type
57+
*/
4158
public class DefaultUnaryBlockOperator< S extends NativeType< S >, T extends NativeType< T > > implements UnaryBlockOperator< S, T >
4259
{
4360
private final S sourceType;

0 commit comments

Comments
 (0)