@Override public void test(List<T> list) throws ParameterException {
  Set<T> values=new HashSet<>();
  for (  T pv : list) {
    if (!values.add(pv)) {
      Object[] parametervaluesarr=list.toArray();
      throw new WrongParameterValueException("Global Parameter Constraint Error:\n" + "Parameter values must have different values. Current values: " + Arrays.deepToString(parametervaluesarr) + ".\n");
    }
  }
}

@ Override public void test ( List < T > list ) throws ParameterException { Set < T > values = new HashSet < > ( ) ; for ( T pv : list ) { if ( ! values . add ( pv ) ) { Object [ ] parametervaluesarr = list . toArray ( ) ; throw new WrongParameterValueException ( "Global Parameter Constraint Error:\n" + "Parameter values must have different values. Current values: " + Arrays . deepToString ( parametervaluesarr ) + ".\n" ) ; } } }
checks if the elements of the list of parameter values do have different values . if not , a parameter exception is thrown .
