
com.whiteclarkegroup.liquibaselinter.config.rules.specific.IsolateDDLChanges Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of liquibase-linter Show documentation
Show all versions of liquibase-linter Show documentation
Liquibase extension to add configurable script linting
package com.whiteclarkegroup.liquibaselinter.config.rules.specific;
import com.whiteclarkegroup.liquibaselinter.ChangeLogLinter;
import com.whiteclarkegroup.liquibaselinter.config.rules.Rule;
import com.whiteclarkegroup.liquibaselinter.config.rules.RuleConfig;
import liquibase.change.Change;
import java.util.List;
import java.util.stream.Collectors;
public class IsolateDDLChanges extends Rule> {
public IsolateDDLChanges(RuleConfig ruleConfig) {
super(ruleConfig);
}
@Override
public boolean invalid(List changes, Change change) {
return changes.stream().filter(cng -> ChangeLogLinter.DDL_CHANGE_TYPES.contains(cng.getClass())).collect(Collectors.toList()).size() > 1;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy