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

org.mentabean.sql.conditions.SimpleComparison Maven / Gradle / Ivy

There is a newer version: 2.2.4
Show newest version
package org.mentabean.sql.conditions;

import org.mentabean.sql.Condition;
import org.mentabean.sql.param.Param;
import org.mentabean.sql.param.ParamValue;

public abstract class SimpleComparison implements Condition {

	private Param param;
	
	public abstract String comparisonSignal();
	
	public SimpleComparison(Param param) {
		this.param = param;
	}
	
	public SimpleComparison(Object value) {
		this.param = new ParamValue(value);
	}
	
	@Override
	public Param[] getParams() {
		return new Param[] {param};
	}

	@Override
	public String build() {
		return comparisonSignal()+" "+param.paramInQuery();
	}

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy