Skip to content

Commit 3f50b96

Browse files
committed
Types: expand javadoc for component method
1 parent 3c27af4 commit 3f50b96

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/main/java/org/scijava/util/Types.java

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -494,6 +494,13 @@ public static Type array(final Type componentType) {
494494

495495
/**
496496
* Gets the component type of the given array type, or null if not an array.
497+
* <p>
498+
* If you have a {@link Class}, you can call {@link Class#getComponentType()}
499+
* for a narrower return type.
500+
* </p>
501+
* <p>
502+
* This is the opposite of {@link #array(Type)}.
503+
* </p>
497504
*/
498505
public static Type component(final Type type) {
499506
if (type instanceof Class) {

0 commit comments

Comments
 (0)