Simple syntax for array creation.

This commit is contained in:
Gary Gregory 2022-03-04 08:58:14 -05:00
parent 5588a9bdee
commit 2431972cc0
4 changed files with 4 additions and 4 deletions

View File

@ -41,7 +41,7 @@ import org.apache.commons.collections4.comparators.TransformingComparator;
*/
public class ComparatorUtils {
private static final Comparator[] EMPTY_COMPARATOR_ARRAY = new Comparator[0];
private static final Comparator[] EMPTY_COMPARATOR_ARRAY = {};
/**
* Don't allow instances.

View File

@ -37,7 +37,7 @@ import org.apache.commons.collections4.iterators.IteratorChain;
*/
public class HasherBloomFilter extends AbstractBloomFilter {
/** The bit representation for an empty Bloom filter. */
private static final long[] EMPTY = new long[0];
private static final long[] EMPTY = {};
/**
* The internal hasher representation.

View File

@ -33,7 +33,7 @@ import org.apache.commons.collections4.Transformer;
*/
public class ChainedTransformer<T> implements Transformer<T, T>, Serializable {
private static final Transformer[] EMPTY_TRANSFORMER_ARRAY = new Transformer[0];
private static final Transformer[] EMPTY_TRANSFORMER_ARRAY = {};
/** Serial version UID */
private static final long serialVersionUID = 3514945074733160196L;

View File

@ -47,7 +47,7 @@ import org.apache.commons.collections4.collection.CompositeCollection;
*/
public class CompositeMap<K, V> extends AbstractIterableMap<K, V> implements Serializable {
private static final Map[] EMPTY_MAP_ARRAY = new Map[0];
private static final Map[] EMPTY_MAP_ARRAY = {};
/** Serialization version */
private static final long serialVersionUID = -6096931280583808322L;