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

com.jpattern.orm.query.from.InnerJoinElement Maven / Gradle / Ivy

There is a newer version: 3.5.1
Show newest version
package com.jpattern.orm.query.from;

import com.jpattern.orm.classtool.IOrmClassToolMap;

/**
 * 
 * @author Francesco Cina
 *
 * 27/giu/2011
 */
public class InnerJoinElement extends AFromElement {

	/**
	 * 
	 */
	
	private final String onLeftProperty;
	private final String onRigthProperty;
	private boolean onClause = true;

	public InnerJoinElement(IOrmClassToolMap ormClassToolMap, Class joinClass) {
		this(ormClassToolMap, joinClass, "", "");
		onClause = false;
	}
	
	public InnerJoinElement(IOrmClassToolMap ormClassToolMap, Class joinClass, String onLeftProperty, String onRigthProperty) {
		super(ormClassToolMap, joinClass);
		this.onLeftProperty = onLeftProperty;
		this.onRigthProperty = onRigthProperty;
	}

	@Override
	protected String getJoinName() {
		return "INNER JOIN ";
	}

	@Override
	protected boolean hasOnClause() {
		return onClause ;
	}

	@Override
	protected String onLeftProperty() {
		return onLeftProperty;
	}

	@Override
	protected String onRightProperty() {
		return onRigthProperty;
	}
	
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy