public static boolean isBatchExtension(Object extension) {
return isType(extension, BatchExtension.class);
}
public static boolean supportsEnvironment(Object extension, EnvironmentInformation environment) {
SupportedEnvironment env = AnnotationUtils.getAnnotation(extension, SupportedEnvironment.class);
if (env == null) {
return true;
}
for (String supported : env.value()) {
if (StringUtils.equalsIgnoreCase(environment.getKey(), supported)) {
return true;
}
}
return false;