io.github.davidebocca.util.unit.test.rules.conf.FieldExclusionConf Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of unit-test Show documentation
Show all versions of unit-test Show documentation
Simple library to help developments of util tests
package io.github.davidebocca.util.unit.test.rules.conf;
import java.util.ArrayList;
import java.util.List;
public class FieldExclusionConf {
private Class> clazz;
private List fieldsToExclude;
public FieldExclusionConf() {
super();
// TODO Auto-generated constructor stub
}
/**
*
* Use this constructor to apply the exclusions to a certain class
*
* @param clazz
* @param fieldsToExclude
*/
public FieldExclusionConf(Class> clazz, List fieldsToExclude) {
super();
this.clazz = clazz;
this.fieldsToExclude = fieldsToExclude;
}
/**
*
* Use this constructor to exclude the fields from all the classes tested
*
* @param fieldsToExclude
*
*/
public FieldExclusionConf(List fieldsToExclude) {
super();
this.fieldsToExclude = fieldsToExclude;
}
public List getFieldsToExclude() {
if (fieldsToExclude == null) {
fieldsToExclude = new ArrayList<>();
}
return fieldsToExclude;
}
public void setFieldsToExclude(List fieldsToExclude) {
this.fieldsToExclude = fieldsToExclude;
}
public Class> getClazz() {
return clazz;
}
}