public abstract class

AbstractCharArrayType

extends MutableType
java.lang.Object
   ↳ org.hibernate.type.AbstractType
     ↳ org.hibernate.type.NullableType
       ↳ org.hibernate.type.MutableType
         ↳ org.hibernate.type.AbstractCharArrayType

This class is deprecated.
Use the AbstractStandardBasicType approach instead

Class Overview

Logic to bind stream of char into a VARCHAR

Summary

Public Constructors
AbstractCharArrayType()
Public Methods
Object fromStringValue(String xml)
Consume the given string representation back into this types java form.
Object get(ResultSet rs, String name)
Get a column value from a result set, without worrying about the possibility of null values.
abstract Class getReturnedClass()
String objectToSQLString(Object value, Dialect dialect)
void set(PreparedStatement st, Object value, int index)
Set a parameter value without worrying about the possibility of null values.
int sqlType()
A convenience form of sqlTypes(org.hibernate.engine.Mapping), returning just a single type value since these are explicitly dealing with single column mappings.
Object stringToObject(String xml)
String toString(Object value)
Protected Methods
Object deepCopyNotNull(Object value)
abstract Object toExternalFormat(char[] chars)
Convert the char[] into the expected object type
abstract char[] toInternalFormat(Object chars)
Convert the object into the internal char[] representation
[Expand]
Inherited Methods
From class org.hibernate.type.MutableType
From class org.hibernate.type.NullableType
From class org.hibernate.type.AbstractType
From class java.lang.Object
From interface org.hibernate.type.StringRepresentableType
From interface org.hibernate.type.Type
From interface org.hibernate.type.XmlRepresentableType

Public Constructors

public AbstractCharArrayType ()

Public Methods

public Object fromStringValue (String xml)

Consume the given string representation back into this types java form.

Parameters
xml The string representation to be consumed.
Returns
  • The java type representation

public Object get (ResultSet rs, String name)

Get a column value from a result set, without worrying about the possibility of null values. Called from nullSafeGet(ResultSet, String) after nullness checks have been performed.

Parameters
rs The result set from which to extract the value.
name The name of the value to extract.
Returns
  • The extracted value.
Throws
SQLException

public abstract Class getReturnedClass ()

public String objectToSQLString (Object value, Dialect dialect)

Throws
Exception

public void set (PreparedStatement st, Object value, int index)

Set a parameter value without worrying about the possibility of null values. Called from nullSafeSet(PreparedStatement, Object, int) after nullness checks have been performed.

Parameters
st The statement into which to bind the parameter value.
value The parameter value to bind.
index The position or index at which to bind the param value.
Throws
SQLException

public int sqlType ()

A convenience form of sqlTypes(org.hibernate.engine.Mapping), returning just a single type value since these are explicitly dealing with single column mappings.

Returns
  • The java.sql.Types mapping value.

public Object stringToObject (String xml)

Throws
Exception

public String toString (Object value)

Protected Methods

protected Object deepCopyNotNull (Object value)

protected abstract Object toExternalFormat (char[] chars)

Convert the char[] into the expected object type

protected abstract char[] toInternalFormat (Object chars)

Convert the object into the internal char[] representation