Class ArraysGenerator<T,C>
java.lang.Object
de.cuioss.test.valueobjects.generator.dynamic.impl.ArraysGenerator<T,C>
- Type Parameters:
T
- identifying the concrete Array-typeC
- identifying the componentType of the array
- All Implemented Interfaces:
de.cuioss.test.generator.TypedGenerator<T>
public class ArraysGenerator<T,C>
extends Object
implements de.cuioss.test.generator.TypedGenerator<T>
Generator for different types of arrays.
- Author:
- Oliver Wolff
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic final <T> Optional<de.cuioss.test.generator.TypedGenerator<T>>
getGeneratorForType
(Class<T> type) Factory method for creating an instance ofArraysGenerator
.next()
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface de.cuioss.test.generator.TypedGenerator
getType
-
Constructor Details
-
ArraysGenerator
public ArraysGenerator()
-
-
Method Details
-
next
- Specified by:
next
in interfacede.cuioss.test.generator.TypedGenerator<T>
-
getGeneratorForType
public static final <T> Optional<de.cuioss.test.generator.TypedGenerator<T>> getGeneratorForType(Class<T> type) Factory method for creating an instance ofArraysGenerator
.- Parameters:
type
- to be, must not be an array type:Class.isArray()
- Returns:
- an
Optional
on the correspondingArraysGenerator
if the requirements are met,Optional.empty()
otherwise
-