Interface ArrayColumns

All Known Subinterfaces:
JdbcArrayColumns
All Known Implementing Classes:
ArrayColumns.Unsupported, JdbcArrayColumns.DefaultSupport, JdbcArrayColumns.Unsupported, ObjectArrayColumns

public interface ArrayColumns
Interface declaring methods that express how a dialect supports array-typed columns.
Since:
1.1
Author:
Mark Paluch
  • Method Details

    • isSupported

      boolean isSupported()
      Returns true if the dialect supports array-typed columns.
      Returns:
      true if the dialect supports array-typed columns.
    • getArrayType

      Class<?> getArrayType(Class<?> userType)
      Translate the user type of an array into the dialect-specific type. This method considers only the component type.
      Parameters:
      userType - component type of the array.
      Returns:
      the dialect-supported array type.
      Throws:
      UnsupportedOperationException - if array typed columns are not supported.
      IllegalArgumentException - if the userType is not a supported array type.
    • unwrapComponentType

      static Class<?> unwrapComponentType(Class<?> clazz)
      Unwrap the nested Class.getComponentType() from a given Class.
      Parameters:
      clazz - the type to inspect.
      Returns:
      the unwrapped component type.
      Since:
      3.0