ConnectionProperty
public enum JdbcConnectionProperty extends java.lang.Enum<JdbcConnectionProperty> implements ConnectionProperty
ConnectionProperty
commonly supported. Implementations are not
required to support all of these properties.Modifier and Type | Class | Description |
---|---|---|
static class |
JdbcConnectionProperty.Caching |
|
static class |
JdbcConnectionProperty.Holdability |
|
static class |
JdbcConnectionProperty.TransactionIsolation |
Enum Constant | Description |
---|---|
CACHING |
|
CONNECT_TIMEOUT |
|
HOLDABILITY |
|
NETWORK_TIMEOUT |
|
PASSWORD |
|
READ_ONLY |
|
SHARDING_GROUP_KEY |
|
SHARDING_KEY |
|
TRANSACTION_ISOLATION |
|
URL |
|
USER |
Modifier and Type | Method | Description |
---|---|---|
java.lang.Object |
defaultValue() |
Return the value for this property to use if no other value is set.
|
boolean |
isSensitive() |
Returns true if this
ConnectionProperty is contains sensitive information
such as a password or encryption key. |
java.lang.Class |
range() |
Return the type of the value of this
ConnectionProperty . |
boolean |
validate(java.lang.Object value) |
Determine whether a value is valid for this
ConnectionProperty . |
static JdbcConnectionProperty |
valueOf(java.lang.String name) |
Returns the enum constant of this type with the specified name.
|
static JdbcConnectionProperty[] |
values() |
Returns an array containing the constants of this enum type, in
the order they are declared.
|
configureOperation, name
public static final JdbcConnectionProperty CACHING
public static final JdbcConnectionProperty HOLDABILITY
public static final JdbcConnectionProperty NETWORK_TIMEOUT
public static final JdbcConnectionProperty PASSWORD
public static final JdbcConnectionProperty READ_ONLY
public static final JdbcConnectionProperty SHARDING_KEY
public static final JdbcConnectionProperty SHARDING_GROUP_KEY
public static final JdbcConnectionProperty CONNECT_TIMEOUT
public static final JdbcConnectionProperty TRANSACTION_ISOLATION
public static final JdbcConnectionProperty URL
public static final JdbcConnectionProperty USER
public static JdbcConnectionProperty[] values()
for (JdbcConnectionProperty c : JdbcConnectionProperty.values()) System.out.println(c);
public static JdbcConnectionProperty valueOf(java.lang.String name)
name
- the name of the enum constant to be returned.java.lang.IllegalArgumentException
- if this enum type has no constant with the specified namejava.lang.NullPointerException
- if the argument is nullpublic java.lang.Class range()
ConnectionProperty
ConnectionProperty
. Any value
set for this property must be assignable to this type.range
in interface ConnectionProperty
ConnectionProperty
public boolean validate(java.lang.Object value)
ConnectionProperty
ConnectionProperty
. Returns
true
if value
is valid and false
otherwise.validate
in interface ConnectionProperty
value
- a value for this ConnectionProperty
true
iff value
is valid for this ConnectionProperty
public java.lang.Object defaultValue()
ConnectionProperty
DataSource
by calling
DataSource.Builder.registerConnectionProperty(java.sql2.ConnectionProperty)
.defaultValue
in interface ConnectionProperty
null
if there is no default valuepublic boolean isSensitive()
ConnectionProperty
ConnectionProperty
is contains sensitive information
such as a password or encryption key.isSensitive
in interface ConnectionProperty
Report a bug or suggest an enhancement
For further API reference and developer documentation see the Java SE Documentation, which contains more detailed, developer-targeted descriptions with conceptual overviews, definitions of terms, workarounds, and working code examples.
Java is a trademark or registered trademark of Oracle and/or its affiliates in the US and other countries.
Copyright © 1993, 2017, Oracle and/or its affiliates, 500 Oracle Parkway, Redwood Shores, CA 94065 USA.
All rights reserved. Use is subject to license terms and the documentation redistribution policy.
DRAFT JDBC 4.4 EA