Class SiNoType

java.lang.Object
org.hibernate.type.AbstractStandardBasicType<T>
org.hibernate.type.AbstractSingleColumnStandardBasicType<Boolean>
org.openxava.types.SiNoType
All Implemented Interfaces:
Serializable, org.hibernate.type.BasicType, org.hibernate.type.DiscriminatorType<Boolean>, org.hibernate.type.IdentifierType<Boolean>, org.hibernate.type.LiteralType<Boolean>, org.hibernate.type.PrimitiveType<Boolean>, org.hibernate.type.ProcedureParameterExtractionAware<Boolean>, org.hibernate.type.ProcedureParameterNamedBinder, org.hibernate.type.SingleColumnType<Boolean>, org.hibernate.type.StringRepresentableType<Boolean>, org.hibernate.type.Type

public class SiNoType extends org.hibernate.type.AbstractSingleColumnStandardBasicType<Boolean> implements org.hibernate.type.PrimitiveType<Boolean>, org.hibernate.type.DiscriminatorType<Boolean>
Stores a boolean value as 'S' or 'N' in database.

Author:
Javier Paniza
See Also:
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final org.hibernate.type.YesNoType
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
     
     
     
    objectToSQLString(Boolean value, org.hibernate.dialect.Dialect dialect)
     
     

    Methods inherited from class org.hibernate.type.AbstractSingleColumnStandardBasicType

    nullSafeSet, sqlType

    Methods inherited from class org.hibernate.type.AbstractStandardBasicType

    assemble, beforeAssemble, canDoExtraction, canDoSetting, compare, deepCopy, deepCopy, defaultSizes, dictatedSizes, disassemble, extract, extract, fromString, fromStringValue, get, getColumnSpan, getDefaultSize, getDictatedSize, getHashCode, getHashCode, getJavaTypeDescriptor, getMutabilityPlan, getRegistrationKeys, getReplacement, getReturnedClass, getSemiResolvedType, getSqlTypeDescriptor, hydrate, isAnyType, isAssociationType, isCollectionType, isComponentType, isDirty, isDirty, isDirty, isEntityType, isEqual, isEqual, isModified, isMutable, isSame, isXMLElement, nullSafeGet, nullSafeGet, nullSafeGet, nullSafeGet, nullSafeSet, nullSafeSet, nullSafeSet, nullSafeSet, registerUnderJavaType, remapSqlTypeDescriptor, replace, replace, resolve, semiResolve, set, setJavaTypeDescriptor, setSqlTypeDescriptor, sqlTypes, toColumnNullness, toLoggableString, toString

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.hibernate.type.PrimitiveType

    toString

    Methods inherited from interface org.hibernate.type.SingleColumnType

    fromStringValue, get, nullSafeGet, set, toString

    Methods inherited from interface org.hibernate.type.Type

    assemble, beforeAssemble, compare, deepCopy, defaultSizes, dictatedSizes, disassemble, getColumnSpan, getHashCode, getHashCode, getReturnedClass, getSemiResolvedType, hydrate, isAnyType, isAssociationType, isCollectionType, isComponentType, isDirty, isDirty, isEntityType, isEqual, isEqual, isModified, isMutable, isSame, nullSafeGet, nullSafeGet, nullSafeSet, nullSafeSet, replace, replace, resolve, resolve, semiResolve, sqlTypes, toColumnNullness, toLoggableString
  • Field Details

    • INSTANCE

      public static final org.hibernate.type.YesNoType INSTANCE
  • Constructor Details

    • SiNoType

      public SiNoType()
  • Method Details

    • getName

      public String getName()
      Specified by:
      getName in interface org.hibernate.type.Type
    • getPrimitiveClass

      public Class getPrimitiveClass()
      Specified by:
      getPrimitiveClass in interface org.hibernate.type.PrimitiveType<Boolean>
    • stringToObject

      public Boolean stringToObject(String xml) throws Exception
      Specified by:
      stringToObject in interface org.hibernate.type.IdentifierType<Boolean>
      Throws:
      Exception
    • getDefaultValue

      public Serializable getDefaultValue()
      Specified by:
      getDefaultValue in interface org.hibernate.type.PrimitiveType<Boolean>
    • objectToSQLString

      public String objectToSQLString(Boolean value, org.hibernate.dialect.Dialect dialect) throws Exception
      Specified by:
      objectToSQLString in interface org.hibernate.type.LiteralType<Boolean>
      Throws:
      Exception