Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/main/java/org/apache/commons/lang3/AnnotationUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public class AnnotationUtils {
*/
private static final ToStringStyle TO_STRING_STYLE = new ToStringStyle() {

/** Serialization version */
/** Serialization version. */
private static final long serialVersionUID = 1L;

{
Expand Down Expand Up @@ -232,10 +232,10 @@ && isValidAnnotationMemberType(m.getReturnType())) {
* @param a the Annotation for a hash code calculation is desired, not
* {@code null}
* @return the calculated hash code
* @throws RuntimeException if an {@link Exception} is encountered during
* annotation member access
* @throws IllegalStateException if an annotation method invocation returns
* {@code null}
* @throws RuntimeException if an {@link Exception} is encountered during
* annotation member access
*/
public static int hashCode(final Annotation a) {
int result = 0;
Expand Down
60 changes: 31 additions & 29 deletions src/main/java/org/apache/commons/lang3/AppendableJoiner.java
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
* This class is immutable and thread-safe.
* </p>
*
* @param <T> the type of elements to join.
* @param <T> the type of elements to join
* @see Appendable
* @see StringBuilder
* @see String#join(CharSequence, CharSequence...)
Expand All @@ -86,7 +86,7 @@ public final class AppendableJoiner<T> {
/**
* Builds instances of {@link AppendableJoiner}.
*
* @param <T> the type of elements to join.
* @param <T> the type of elements to join
*/
public static final class Builder<T> implements Supplier<AppendableJoiner<T>> {

Expand All @@ -99,7 +99,9 @@ public static final class Builder<T> implements Supplier<AppendableJoiner<T>> {
/** The delimiter that separates each element. */
private CharSequence delimiter;

/** The consumer used to render each element of type {@code T} onto an {@link Appendable}. */
/**
* The consumer used to render each element of type {@code T} onto an {@link Appendable}.
*/
private FailableBiConsumer<Appendable, T, IOException> appender;

/**
Expand All @@ -120,8 +122,8 @@ public AppendableJoiner<T> get() {
/**
* Sets the delimiter that separates each element.
*
* @param delimiter The delimiter that separates each element.
* @return {@code this} instance.
* @param delimiter the delimiter that separates each element
* @return {@code this} instance
*/
public Builder<T> setDelimiter(final CharSequence delimiter) {
this.delimiter = delimiter;
Expand All @@ -131,8 +133,8 @@ public Builder<T> setDelimiter(final CharSequence delimiter) {
/**
* Sets the consumer used to render each element of type {@code T} onto an {@link Appendable}.
*
* @param appender The consumer used to render each element of type {@code T} onto an {@link Appendable}.
* @return {@code this} instance.
* @param appender the consumer used to render each element of type {@code T} onto an {@link Appendable}
* @return {@code this} instance
*/
public Builder<T> setElementAppender(final FailableBiConsumer<Appendable, T, IOException> appender) {
this.appender = appender;
Expand All @@ -142,8 +144,8 @@ public Builder<T> setElementAppender(final FailableBiConsumer<Appendable, T, IOE
/**
* Sets the sequence of characters to be used at the beginning.
*
* @param prefix The sequence of characters to be used at the beginning.
* @return {@code this} instance.
* @param prefix the sequence of characters to be used at the beginning
* @return {@code this} instance
*/
public Builder<T> setPrefix(final CharSequence prefix) {
this.prefix = prefix;
Expand All @@ -153,8 +155,8 @@ public Builder<T> setPrefix(final CharSequence prefix) {
/**
* Sets the sequence of characters to be used at the end.
*
* @param suffix The sequence of characters to be used at the end.
* @return {@code this} instance.
* @param suffix the sequence of characters to be used at the end
* @return {@code this} instance
*/
public Builder<T> setSuffix(final CharSequence suffix) {
this.suffix = suffix;
Expand All @@ -166,8 +168,8 @@ public Builder<T> setSuffix(final CharSequence suffix) {
/**
* Creates a new builder.
*
* @param <T> The type of elements.
* @return a new builder.
* @param <T> the type of elements
* @return a new builder
*/
public static <T> Builder<T> builder() {
return new Builder<>();
Expand Down Expand Up @@ -265,9 +267,9 @@ private AppendableJoiner(final CharSequence prefix, final CharSequence suffix, f
/**
* Joins stringified objects from the given Iterable into a StringBuilder.
*
* @param stringBuilder The target.
* @param elements The source.
* @return The given StringBuilder.
* @param stringBuilder the target
* @param elements the source
* @return the given StringBuilder
*/
public StringBuilder join(final StringBuilder stringBuilder, final Iterable<T> elements) {
return joinI(stringBuilder, prefix, suffix, delimiter, appender, elements);
Expand All @@ -276,9 +278,9 @@ public StringBuilder join(final StringBuilder stringBuilder, final Iterable<T> e
/**
* Joins stringified objects from the given array into a StringBuilder.
*
* @param stringBuilder The target.
* @param elements The source.
* @return the given target StringBuilder.
* @param stringBuilder the target
* @param elements the source
* @return the given target StringBuilder
*/
public StringBuilder join(final StringBuilder stringBuilder, @SuppressWarnings("unchecked") final T... elements) {
return joinSB(stringBuilder, prefix, suffix, delimiter, appender, elements);
Expand All @@ -287,11 +289,11 @@ public StringBuilder join(final StringBuilder stringBuilder, @SuppressWarnings("
/**
* Joins stringified objects from the given Iterable into an Appendable.
*
* @param <A> the Appendable type.
* @param appendable The target.
* @param elements The source.
* @return The given StringBuilder.
* @throws IOException If an I/O error occurs
* @param <A> the Appendable type
* @param appendable the target
* @param elements the source
* @return the given StringBuilder
* @throws IOException if an I/O error occurs
*/
public <A extends Appendable> A joinA(final A appendable, final Iterable<T> elements) throws IOException {
return joinIterable(appendable, prefix, suffix, delimiter, appender, elements);
Expand All @@ -300,11 +302,11 @@ public <A extends Appendable> A joinA(final A appendable, final Iterable<T> elem
/**
* Joins stringified objects from the given array into an Appendable.
*
* @param <A> the Appendable type.
* @param appendable The target.
* @param elements The source.
* @return The given StringBuilder.
* @throws IOException If an I/O error occurs
* @param <A> the Appendable type
* @param appendable the target
* @param elements the source
* @return the given StringBuilder
* @throws IOException if an I/O error occurs
*/
public <A extends Appendable> A joinA(final A appendable, @SuppressWarnings("unchecked") final T... elements) throws IOException {
return joinA(appendable, prefix, suffix, delimiter, appender, elements);
Expand Down
18 changes: 9 additions & 9 deletions src/main/java/org/apache/commons/lang3/ArchUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -42,9 +42,9 @@ public class ArchUtils {
/**
* Adds the given {@link Processor} with the given key {@link String} to the map.
*
* @param key The key as {@link String}.
* @param processor The {@link Processor} to add.
* @throws IllegalStateException If the key already exists.
* @param key the key as {@link String}
* @param processor the {@link Processor} to add
* @throws IllegalStateException if the key already exists
*/
private static void addProcessor(final String key, final Processor processor) {
if (ARCH_TO_PROCESSOR.containsKey(key)) {
Expand All @@ -56,9 +56,9 @@ private static void addProcessor(final String key, final Processor processor) {
/**
* Adds the given {@link Processor} with the given keys to the map.
*
* @param keys The keys.
* @param processor The {@link Processor} to add.
* @throws IllegalStateException If the key already exists.
* @param keys the keys
* @param processor the {@link Processor} to add
* @throws IllegalStateException if the key already exists
*/
private static void addProcessors(final Processor processor, final String... keys) {
Streams.of(keys).forEach(e -> addProcessor(e, processor));
Expand All @@ -71,7 +71,7 @@ private static void addProcessors(final Processor processor, final String... key
* Important: The {@code "os.arch"} system property returns the architecture used by the JVM not of the operating system.
* </p>
*
* @return A {@link Processor} when supported, else {@code null}.
* @return a {@link Processor} when supported, else {@code null}
*/
public static Processor getProcessor() {
return getProcessor(SystemProperties.getOsArch());
Expand All @@ -81,8 +81,8 @@ public static Processor getProcessor() {
* Gets a {@link Processor} object the given value {@link String}. The {@link String} must be like a value returned by the {@code "os.arch"} system
* property.
*
* @param value A {@link String} like a value returned by the {@code os.arch} System Property.
* @return A {@link Processor} when it exists, else {@code null}.
* @param value a {@link String} like a value returned by the {@code os.arch} System Property
* @return a {@link Processor} when it exists, else {@code null}
*/
public static Processor getProcessor(final String value) {
return ARCH_TO_PROCESSOR.get(value);
Expand Down
66 changes: 33 additions & 33 deletions src/main/java/org/apache/commons/lang3/ArrayFill.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ public final class ArrayFill {
/**
* Fills and returns the given array, assigning the given {@code boolean} value to each element of the array.
*
* @param a the array to be filled (may be null).
* @param val the value to be stored in all elements of the array.
* @return the given array.
* @param a the array to be filled (may be null)
* @param val the value to be stored in all elements of the array
* @return the given array
* @see Arrays#fill(boolean[],boolean)
* @since 3.18.0
*/
Expand All @@ -48,9 +48,9 @@ public static boolean[] fill(final boolean[] a, final boolean val) {
/**
* Fills and returns the given array, assigning the given {@code byte} value to each element of the array.
*
* @param a the array to be filled (may be null).
* @param val the value to be stored in all elements of the array.
* @return the given array.
* @param a the array to be filled (may be null)
* @param val the value to be stored in all elements of the array
* @return the given array
* @see Arrays#fill(byte[],byte)
*/
public static byte[] fill(final byte[] a, final byte val) {
Expand All @@ -63,9 +63,9 @@ public static byte[] fill(final byte[] a, final byte val) {
/**
* Fills and returns the given array, assigning the given {@code char} value to each element of the array.
*
* @param a the array to be filled (may be null).
* @param val the value to be stored in all elements of the array.
* @return the given array.
* @param a the array to be filled (may be null)
* @param val the value to be stored in all elements of the array
* @return the given array
* @see Arrays#fill(char[],char)
*/
public static char[] fill(final char[] a, final char val) {
Expand All @@ -78,9 +78,9 @@ public static char[] fill(final char[] a, final char val) {
/**
* Fills and returns the given array, assigning the given {@code double} value to each element of the array.
*
* @param a the array to be filled (may be null).
* @param val the value to be stored in all elements of the array.
* @return the given array.
* @param a the array to be filled (may be null)
* @param val the value to be stored in all elements of the array
* @return the given array
* @see Arrays#fill(double[],double)
*/
public static double[] fill(final double[] a, final double val) {
Expand All @@ -93,9 +93,9 @@ public static double[] fill(final double[] a, final double val) {
/**
* Fills and returns the given array, assigning the given {@code float} value to each element of the array.
*
* @param a the array to be filled (may be null).
* @param val the value to be stored in all elements of the array.
* @return the given array.
* @param a the array to be filled (may be null)
* @param val the value to be stored in all elements of the array
* @return the given array
* @see Arrays#fill(float[],float)
*/
public static float[] fill(final float[] a, final float val) {
Expand All @@ -108,9 +108,9 @@ public static float[] fill(final float[] a, final float val) {
/**
* Fills and returns the given array, assigning the given {@code int} value to each element of the array.
*
* @param a the array to be filled (may be null).
* @param val the value to be stored in all elements of the array.
* @return the given array.
* @param a the array to be filled (may be null)
* @param val the value to be stored in all elements of the array
* @return the given array
* @see Arrays#fill(int[],int)
*/
public static int[] fill(final int[] a, final int val) {
Expand All @@ -123,9 +123,9 @@ public static int[] fill(final int[] a, final int val) {
/**
* Fills and returns the given array, assigning the given {@code long} value to each element of the array.
*
* @param a the array to be filled (may be null).
* @param val the value to be stored in all elements of the array.
* @return the given array.
* @param a the array to be filled (may be null)
* @param val the value to be stored in all elements of the array
* @return the given array
* @see Arrays#fill(long[],long)
*/
public static long[] fill(final long[] a, final long val) {
Expand All @@ -138,9 +138,9 @@ public static long[] fill(final long[] a, final long val) {
/**
* Fills and returns the given array, assigning the given {@code short} value to each element of the array.
*
* @param a the array to be filled (may be null).
* @param val the value to be stored in all elements of the array.
* @return the given array.
* @param a the array to be filled (may be null)
* @param val the value to be stored in all elements of the array
* @return the given array
* @see Arrays#fill(short[],short)
*/
public static short[] fill(final short[] a, final short val) {
Expand All @@ -158,12 +158,12 @@ public static short[] fill(final short[] a, final short val) {
* state.
* </p>
*
* @param <T> type of elements of the array.
* @param array array to be initialized.
* @param generator a function accepting an index and producing the desired value for that position.
* @param <T> type of elements of the array
* @param array array to be initialized
* @param generator a function accepting an index and producing the desired value for that position
* @param <E> the kind of thrown exception or error
* @return the input array
* @param <E> The kind of thrown exception or error.
* @throws E Thrown by the given {@code generator}.
* @throws E thrown by the given {@code generator}
* @see Arrays#setAll(Object[], IntFunction)
* @since 3.18.0
*/
Expand All @@ -179,10 +179,10 @@ public static <T, E extends Throwable> T[] fill(final T[] array, final FailableI
/**
* Fills and returns the given array, assigning the given {@code T} value to each element of the array.
*
* @param <T> the array type.
* @param a the array to be filled (may be null).
* @param val the value to be stored in all elements of the array.
* @return the given array.
* @param <T> the array type
* @param a the array to be filled (may be null)
* @param val the value to be stored in all elements of the array
* @return the given array
* @see Arrays#fill(Object[],Object)
*/
public static <T> T[] fill(final T[] a, final T val) {
Expand Down
Loading
Loading