com.github.zeger_tak.enversvalidationplugin.utils.IgnoreUtils Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of envers-validation-maven-plugin Show documentation
Show all versions of envers-validation-maven-plugin Show documentation
This is a Maven plugin that allows for easy validation of database auditing with Hibernate
and is intended to be used by projects that do not always rely on Envers to create the audit history.
package com.github.zeger_tak.enversvalidationplugin.utils;
import java.lang.reflect.Method;
import java.util.List;
import javax.annotation.Nonnull;
import com.github.zeger_tak.enversvalidationplugin.execution.ValidatorWrapper;
public final class IgnoreUtils
{
private IgnoreUtils()
{
}
public static boolean validationShouldBeIgnored(@Nonnull List ignorables, @Nonnull Class> validatorClass)
{
return ignorables.contains(validatorClass.getSimpleName());
}
public static boolean validationShouldBeIgnored(@Nonnull List ignorables, @Nonnull ValidatorWrapper validatorWrapper, @Nonnull Method validatorMethod)
{
return ignorables.contains(validatorWrapper.getUniqueIdentifier(validatorMethod));
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy