All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.github.ashwithpoojary98.clausses.conditions.InCondition Maven / Gradle / Ivy

The newest version!
package io.github.ashwithpoojary98.clausses.conditions;

import io.github.ashwithpoojary98.clausses.AbstractClause;
import lombok.Getter;
import lombok.Setter;

import java.util.List;

@Getter
@Setter
public class InCondition extends AbstractCondition {

    private String column;

    private List values;

    public InCondition() {
    }

    public InCondition(String column, boolean isOr, boolean isNot, List values) {
        this.column = column;
        this.isOr = isOr;
        this.isNot = isNot;
        this.values = values;
    }

    @Override
    public AbstractClause copy() {
        InCondition inCondition = new InCondition<>();
        inCondition.setEngine(this.getEngine());
        inCondition.setComponent(this.getComponent());
        inCondition.setOr(this.isOr);
        inCondition.setNot(this.isNot);
        inCondition.setColumn(this.column);
        inCondition.setValues(this.getValues());
        return inCondition;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy