Example #1
0
  @Override
  public void configure(AnnotatedType annotatedType) {
    super.configure(annotatedType);

    for (int i = 0; i < parameters.length; ++i)
      parameterGenerators.get(i).configure(parameters[i].getAnnotatedType());
  }
Example #2
0
  @Override
  public void configure(AnnotatedType annotatedType) {
    super.configure(annotatedType);

    for (int i = 0; i < fields.size(); ++i)
      fieldGenerators.get(i).configure(fields.get(i).getAnnotatedType());
  }
  @Override
  public Object generate(SourceOfRandomness random, GenerationStatus status) {
    Object array = Array.newInstance(componentType, status.size());
    for (int i = 0; i < Array.getLength(array); ++i)
      Array.set(array, i, component.generate(random, status));

    return array;
  }
Example #4
0
  @Override
  public void provideRepository(GeneratorRepository provided) {
    super.provideRepository(provided);

    parameterGenerators.clear();
    for (Parameter each : parameters) {
      parameterGenerators.add(generatorFor(parameterContext(each)));
    }
  }
Example #5
0
  @Override
  public void provideRepository(GeneratorRepository provided) {
    super.provideRepository(provided);

    fieldGenerators.clear();
    for (Field each : fields) {
      fieldGenerators.add(generatorFor(parameterContext(each)));
    }
  }
 @Override
 public void configure(Map<Class<? extends Annotation>, Annotation> configurationsByType) {
   component.configure(configurationsByType);
 }