railo.runtime.db
Class DataSourceSupport

java.lang.Object
  extended by railo.runtime.db.DataSourceSupport
All Implemented Interfaces:
Cloneable, DataSource, DataSourcePro
Direct Known Subclasses:
ApplicationDataSource, DataSourceImpl

public abstract class DataSourceSupport
extends Object
implements DataSourcePro, Cloneable


Field Summary
 
Fields inherited from interface railo.runtime.db.DataSource
ALLOW_ALL, ALLOW_ALTER, ALLOW_CREATE, ALLOW_DELETE, ALLOW_DROP, ALLOW_GRANT, ALLOW_INSERT, ALLOW_REVOKE, ALLOW_SELECT, ALLOW_UPDATE
 
Constructor Summary
DataSourceSupport(String name, Class clazz, String username, String password, boolean blob, boolean clob, int connectionLimit, int connectionTimeout, long metaCacheTimeout, TimeZone timezone, int allow, boolean storage, boolean readOnly)
           
 
Method Summary
 Object clone()
           
 boolean equals(Object obj)
           
 Class getClazz()
           
 int getConnectionLimit()
           
 int getConnectionTimeout()
           
 long getMetaCacheTimeout()
           
 String getName()
           
 String getPassword()
           
 Map<String,ProcMetaCollection> getProcedureColumnCache()
           
 TimeZone getTimeZone()
           
 String getUsername()
           
 boolean hasAllow(int allow)
           
 boolean hasSQLRestriction()
           
 String id()
           
 boolean isBlob()
           
 boolean isClob()
           
 boolean isReadOnly()
           
 boolean isStorage()
           
 void setClazz(Class clazz)
           
static Class toClass(String className)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface railo.runtime.db.DataSourcePro
getConnectionString, getConnectionStringTranslated
 
Methods inherited from interface railo.runtime.db.DataSource
cloneReadOnly, getCustomNames, getCustoms, getCustomValue, getDatabase, getDsnOriginal, getDsnTranslated, getHost, getPort, validate
 

Constructor Detail

DataSourceSupport

public DataSourceSupport(String name,
                         Class clazz,
                         String username,
                         String password,
                         boolean blob,
                         boolean clob,
                         int connectionLimit,
                         int connectionTimeout,
                         long metaCacheTimeout,
                         TimeZone timezone,
                         int allow,
                         boolean storage,
                         boolean readOnly)
Method Detail

clone

public Object clone()
Specified by:
clone in interface DataSource
Overrides:
clone in class Object
Returns:
cloned Object

getProcedureColumnCache

public Map<String,ProcMetaCollection> getProcedureColumnCache()

isBlob

public final boolean isBlob()
Specified by:
isBlob in interface DataSource
Returns:
Returns the blob.

isClob

public final boolean isClob()
Specified by:
isClob in interface DataSource
Returns:
Returns the clob.

getConnectionLimit

public final int getConnectionLimit()
Specified by:
getConnectionLimit in interface DataSource
Returns:
Returns the connectionLimit.

getConnectionTimeout

public final int getConnectionTimeout()
Specified by:
getConnectionTimeout in interface DataSource
Returns:
Returns the connectionTimeout.

getMetaCacheTimeout

public final long getMetaCacheTimeout()
Specified by:
getMetaCacheTimeout in interface DataSource

getTimeZone

public final TimeZone getTimeZone()
Specified by:
getTimeZone in interface DataSource

getClazz

public final Class getClazz()
Specified by:
getClazz in interface DataSource
Returns:
Returns the clazz.

setClazz

public final void setClazz(Class clazz)
Specified by:
setClazz in interface DataSource
Parameters:
clazz - The clazz to set.

getName

public final String getName()
Specified by:
getName in interface DataSource
Returns:
Returns the name.

isStorage

public final boolean isStorage()
Specified by:
isStorage in interface DataSource

hasAllow

public final boolean hasAllow(int allow)
Specified by:
hasAllow in interface DataSource
Returns:
returns if given allow exists

hasSQLRestriction

public final boolean hasSQLRestriction()
Specified by:
hasSQLRestriction in interface DataSource
Returns:
returns if database has a SQL restriction

isReadOnly

public final boolean isReadOnly()
Specified by:
isReadOnly in interface DataSource
Returns:
Returns the readOnly.

getPassword

public String getPassword()
Specified by:
getPassword in interface DataSource
Returns:
Returns the password.

getUsername

public String getUsername()
Specified by:
getUsername in interface DataSource
Returns:
Returns the username.

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

id

public String id()
Specified by:
id in interface DataSourcePro
Returns:
unique id of the DataSource

toString

public String toString()
Overrides:
toString in class Object

toClass

public static Class toClass(String className)
                     throws ClassException
Throws:
ClassException


Copyright © 2012 Railo