Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT

## org.hibernate.annotations
Annotation Type ColumnTransformer

    @Target(value={FIELD,METHOD})
    @Retention(value=RUNTIME)
    public @interface ColumnTransformer

Custom SQL expression used to read the value from and write a value to a column. Use for direct object loading/saving as well as queries. The write expression must contain exactly one '?' placeholder for the value. For example: `read="decrypt(credit_card_num)" write="encrypt(?)"`

Author:
  Emmanuel Bernard

Optional Element Summary
`String` | `forColumn` (Logical) column name for which the expression is used This can be left out if the property is bound to a single column
`String` | `read` Custom SQL expression used to read from the column
`String` | `write` Custom SQL expression used to write to the column.

### forColumn

    public abstract String forColumn

  (Logical) column name for which the expression is used This can be left out if the property is bound to a single column

  Default:
    ""

### read

    public abstract String read

  Custom SQL expression used to read from the column

  Default:
    ""

### write

    public abstract String write

  Custom SQL expression used to write to the column. The write expression must contain exactly one '?' placeholder for the value.

  Default:
    ""

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: REQUIRED | OPTIONAL | DETAIL: ELEMENT

Copyright © 2001-2010 Red Hat, Inc. All Rights Reserved.