Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.eclipse.jetty.server.session
Class JDBCSessionIdManager.DatabaseAdaptor

    java.lang.Object
      org.eclipse.jetty.server.session.JDBCSessionIdManager.DatabaseAdaptor

Enclosing class:
  JDBCSessionIdManager

    public class JDBCSessionIdManager.DatabaseAdaptor

extends java.lang.Object

DatabaseAdaptor Handles differences between databases. Postgres uses the getBytes and setBinaryStream methods to access a "bytea" datatype, which can be up to 1Gb of binary data. MySQL is happy to use the "blob" type and getBlob() methods instead. TODO if the differences become more major it would be worthwhile refactoring this class.

Constructor Summary
`JDBCSessionIdManager.DatabaseAdaptor(java.sql.DatabaseMetaData dbMeta)`

Method Summary
`java.lang.String` | `convertIdentifier(java.lang.String identifier)` Convert a camel case identifier into either upper or lower depending on the way the db stores identifiers.
`java.io.InputStream` | `getBlobInputStream(java.sql.ResultSet result, java.lang.String columnName)`
`java.lang.String` | `getBlobType()`
`java.lang.String` | `getDBName()`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### JDBCSessionIdManager.DatabaseAdaptor

    public JDBCSessionIdManager.DatabaseAdaptor(java.sql.DatabaseMetaData dbMeta)
                                         throws java.sql.SQLException

Throws:
  `java.sql.SQLException`

Method Detail

### convertIdentifier

    public java.lang.String convertIdentifier(java.lang.String identifier)

  Convert a camel case identifier into either upper or lower depending on the way the db stores identifiers.

  Parameters:
    `identifier` -
  Returns:
    the converted identifier

### getDBName

    public java.lang.String getDBName()

### getBlobType

    public java.lang.String getBlobType()

### getBlobInputStream

    public java.io.InputStream getBlobInputStream(java.sql.ResultSet result,
                                                  java.lang.String columnName)
                                           throws java.sql.SQLException

  Throws:
    `java.sql.SQLException`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 1995-2010 Mort Bay Consulting. All Rights Reserved.