
org.bridje.orm.ComparableColumn Maven / Gradle / Ivy
/*
* Copyright 2016 Bridje Framework.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.bridje.orm;
/**
* Represents a database column associated with a field of an Entity, or a
* function column. Objects from this class will be generated by the ORM api so
* the user can use then for building the querys for the Entities of his data
* model. Ex: MyEntity_.someColumn.eq("A Name") = Condition for
* MyEntity.someColumn field.
*
* @param The type of the column.
*/
public interface ComparableColumn extends Column
{
/**
* Returns a new function column representing the max aggregated function for this column.
*
* @return A new function column representing the max aggregated function for this column.
*/
Column max();
/**
* Returns a new function column representing the min aggregated function for this column.
*
* @return A new function column representing the min aggregated function for this column.
*/
Column min();
/**
* Creates a new greather than ">" condition with this column as a left
* operand and the provided value as the left operand.
*
* @param value The right operator for the condition.
* @return The new created condition.
*/
Condition gt(T value);
/**
* Creates a new greather than or equals to ">=" condition with this
* column as a left operand and the provided value as the left operand.
*
* @param value The right operaand for the condition.
* @return The new created condition.
*/
Condition ge(T value);
/**
* Creates a new leaser than "<" condition with this column as a left
* operand and the provided value as the left operand.
*
* @param value The right operaand for the condition.
* @return The new created condition.
*/
Condition lt(T value);
/**
* Creates a new leaser than or equals to "<=" condition with this column
* as a left operand and the provided value as the left operand.
*
* @param value The right operaand for the condition.
* @return The new created condition.
*/
Condition le(T value);
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy