Java Code Examples for org.hibernate.type.StandardBasicTypes#BOOLEAN

The following examples show how to use org.hibernate.type.StandardBasicTypes#BOOLEAN . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: LiteralNode.java    From lams with GNU General Public License v2.0 5 votes vote down vote up
public Type getDataType() {
	if ( getExpectedType() != null ) {
		return getExpectedType();
	}

	switch ( getType() ) {
		case NUM_INT:
			return StandardBasicTypes.INTEGER;
		case NUM_FLOAT:
			return StandardBasicTypes.FLOAT;
		case NUM_LONG:
			return StandardBasicTypes.LONG;
		case NUM_DOUBLE:
			return StandardBasicTypes.DOUBLE;
		case NUM_BIG_INTEGER:
			return StandardBasicTypes.BIG_INTEGER;
		case NUM_BIG_DECIMAL:
			return StandardBasicTypes.BIG_DECIMAL;
		case QUOTED_STRING:
			return StandardBasicTypes.STRING;
		case TRUE:
		case FALSE:
			return StandardBasicTypes.BOOLEAN;
		default:
			return null;
	}
}
 
Example 2
Source File: BetweenOperatorNode.java    From lams with GNU General Public License v2.0 4 votes vote down vote up
@Override
public Type getDataType() {
	// logic operators by definition resolve to boolean.
	return StandardBasicTypes.BOOLEAN;
}
 
Example 3
Source File: BinaryLogicOperatorNode.java    From lams with GNU General Public License v2.0 4 votes vote down vote up
@Override
public Type getDataType() {
	// logic operators by definition resolve to booleans
	return StandardBasicTypes.BOOLEAN;
}
 
Example 4
Source File: BooleanLiteralNode.java    From lams with GNU General Public License v2.0 4 votes vote down vote up
public Type getDataType() {
	return getExpectedType() == null ? StandardBasicTypes.BOOLEAN : getExpectedType();
}
 
Example 5
Source File: UnaryLogicOperatorNode.java    From lams with GNU General Public License v2.0 4 votes vote down vote up
public Type getDataType() {
	// logic operators by definition resolve to booleans
	return StandardBasicTypes.BOOLEAN;
}