db.sql.api.cmd.basic.UnionsCmdLists Maven / Gradle / Ivy
package db.sql.api.cmd.basic;
import db.sql.api.Cmd;
import db.sql.api.SqlBuilderContext;
import db.sql.api.tookit.CmdUtils;
import java.util.List;
public class UnionsCmdLists implements Cmd {
private final List cmdList;
public UnionsCmdLists(List cmdList) {
this.cmdList = cmdList;
}
@Override
public StringBuilder sql(Cmd module, Cmd parent, SqlBuilderContext context, StringBuilder sqlBuilder) {
return CmdUtils.join(module, this, context, sqlBuilder, cmdList);
}
@Override
public boolean contain(Cmd cmd) {
return CmdUtils.contain(cmd, this.cmdList);
}
}