io.github.bekoenig.assertj.schemacrawler.api.AbstractIndexColumnAssert Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of assertj-schemacrawler Show documentation
Show all versions of assertj-schemacrawler Show documentation
An assertj extension for schema-crawler.
package io.github.bekoenig.assertj.schemacrawler.api;
import schemacrawler.schema.Index;
import schemacrawler.schema.IndexColumn;
import schemacrawler.schema.IndexColumnSortSequence;
import java.util.function.Consumer;
import java.util.function.Predicate;
public class AbstractIndexColumnAssert>
extends AbstractKeyColumnAssert {
protected AbstractIndexColumnAssert(IndexColumn actual, Class> selfType) {
super(actual, selfType);
}
public SELF satisfiesIndex(Consumer requirement) {
extracting(IndexColumn::getIndex).satisfies(requirement);
return myself;
}
public SELF matchesIndexOrdinalPosition(Predicate predicate) {
extracting(IndexColumn::getIndexOrdinalPosition).matches(predicate);
return myself;
}
public SELF satisfiesSortSequence(Consumer requirement) {
extracting(IndexColumn::getSortSequence).satisfies(requirement);
return myself;
}
}