<commit_before>package com.github.dakusui.jcunit8.runners.junit4.annotations;

import com.github.dakusui.jcunit8.factorspace.Parameter;
import com.github.dakusui.jcunit8.factorspace.Parameter.Simple;
import org.junit.runners.model.FrameworkMethod;
import org.junit.validator.AnnotationValidator;
import org.junit.validator.ValidateWith;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.util.LinkedList;
import java.util.List;

@Retention(RetentionPolicy.RUNTIME)
@ValidateWith(ParameterSource.Validator.class)
public @interface ParameterSource {
  Class<? extends Parameter> by() default Simple.class;

  class Validator extends AnnotationValidator {
    public List<Exception> validateAnnotatedMethod(FrameworkMethod method) {
      return new LinkedList<Exception>() {{
        if (!method.isPublic())
          add(new Exception(
              String.format("'%s' must be public but not.", method.getName())<commit_msg>Remove unused attribute in @ParameterSource.<commit_after>package com.github.dakusui.jcunit8.runners.junit4.annotations;

import org.junit.runners.model.FrameworkMethod;
import org.junit.validator.AnnotationValidator;
import org.junit.validator.ValidateWith;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.util.LinkedList;
import java.util.List;

@Retention(RetentionPolicy.RUNTIME)
@ValidateWith(ParameterSource.Validator.class)
public @interface ParameterSource {
  class Validator extends AnnotationValidator {
    public List<Exception> validateAnnotatedMethod(FrameworkMethod method) {
      return new LinkedList<Exception>() {{
        if (!method.isPublic())
          add(new Exception(
              String.format("'%s' must be public but not.", method.getName())
{'fraction_non_alphanumeric': 0.10262130507529281, 'fraction_numerical': 0.0033463469046291134, 'mean_word_length': 5.339222614840989, 'pattern_counts': {'":': 0, '<': 8, '<?xml version=': 0, '>': 8, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1468625', 'n_tokens_mistral': 498, 'n_tokens_neox': 498, 'n_words': 99}