- All Implemented Interfaces:
Serializable
,Comparable<DpbType>
,Constable
Identifies the database (or service attach) parameter buffer type of a connection property.
In general, there is a 1-on-1 correspondence with ConnectionPropertyType
, but in some cases mapping might be
different (current expectation: boolean connection properties that map to either a single item or a 0 / 1 value).
- Since:
- 5
- Author:
- Mark Rotteveel
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionParameter value as a byte.Parameter value is an integer.Parameter is not sent at all (primarily to have a null-safe value for connection properties that should not be sent to the server).Parameter value is not sent (just presence or absence of the parameter item), corresponding value must be aBoolean
.Parameter value is a string. -
Method Summary
Modifier and TypeMethodDescriptionabstract void
addValue
(ParameterBuffer pb, int pbItem, Object value, ConnectionPropertyType type) Populate the parameter bufferpb
withpbItem
andvalue
.static DpbType
Returns the enum constant of this class with the specified name.static DpbType[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
STRING
Parameter value is a string. -
INT
Parameter value is an integer. -
BYTE
Parameter value as a byte. -
SINGLE
Parameter value is not sent (just presence or absence of the parameter item), corresponding value must be aBoolean
. -
NONE
Parameter is not sent at all (primarily to have a null-safe value for connection properties that should not be sent to the server).
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
addValue
public abstract void addValue(ParameterBuffer pb, int pbItem, Object value, ConnectionPropertyType type) Populate the parameter bufferpb
withpbItem
andvalue
.- Parameters:
pb
- Parameter bufferpbItem
- Parameter buffer itemvalue
- Valuetype
- Connection property type
-