| Modifier and Type | Field and Description |
|---|---|
| private static final byte | |
| private final @Nullable byte[][] | |
| private final byte[] | |
| private static final byte | |
| private static final byte | |
| private static final Object | NULL_OBJECT
Marker object representing NULL; this distinguishes "parameter never set" from "parameter set to null". |
| private static final byte | |
| private final int[] | |
| private final @Nullable Object[] | |
| private int | |
| private static final byte | |
| private final @Nullable TypeTransferModeRegistry |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public void | appendAll(ParameterList
of parameters to append with. list)Implements org. Use this operation to append more parameters to the current list. |
| private void | |
| public void | checkAllParametersSet()
Implements org. Ensure that all parameters in this list have been assigned values. |
| public void | clear()
Implements org. Unbind all parameter values bound in this list. |
| public void | convertFunctionOutParameters()
Implements org. Convert any function output parameters to the correct type (void) and set an ignorable value for it. |
| public ParameterList | copy()
Implements org. Perform a shallow copy of this ParameterList, returning a new instance (still suitable for passing to the owning Query). |
| private byte | |
| public @Nullable byte[][] | getEncoding()
Implements org. Return the encoding for each parameter. |
| public byte[] | getFlags()
Implements org. Return the flags for each parameter. |
| public @NonNegative int | getInParameterCount()
Implements org. Get the number of IN parameters in this list. |
| public @NonNegative int | getOutParameterCount()
Implements org. Get the number of OUT parameters in this list. |
| public @NonNegative int | getParameterCount()
Implements org. Get the number of parameters in this list. |
| public int[] | getParamTypes()
Implements org. Return the parameter type information. |
| public @Nullable SimpleParameterList[] | getSubparams()
Implements org. Return a list of the SimpleParameterList objects that make up this parameter list. |
| pack-priv int | |
| public int[] | getTypeOIDs()
Implements org. Return the oids of the parameters in this list. |
| pack-priv int | |
| public @Nullable Object[] | getValues()
Implements org. Returns the bound parameter values. |
| pack-priv boolean | |
| pack-priv boolean | |
| pack-priv boolean | |
| private static String | quoteAndCast(String text, @Nullable String type, boolean standardConformingStrings)
Escapes a given text value as a literal, wraps it in single quotes, casts it to the to the given data type, and finally wraps the whole thing in parentheses. |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| pack-priv void | |
| public void | |
| public void | |
| private static void | |
| private static void | |
| public String | |
| public String | Returns: String representation of the list valuesOverrides java. Useful implementation of toString. |
| pack-priv void |
| BINARY | back to summary |
|---|---|
| private static final byte BINARY | |
| encoded | back to summary |
|---|---|
| private final @Nullable byte[][] encoded | |
| flags | back to summary |
|---|---|
| private final byte[] flags | |
| IN | back to summary |
|---|---|
| private static final byte IN | |
| INOUT | back to summary |
|---|---|
| private static final byte INOUT | |
| NULL_OBJECT | back to summary |
|---|---|
| private static final Object NULL_OBJECT Marker object representing NULL; this distinguishes "parameter never set" from "parameter set to null". | |
| OUT | back to summary |
|---|---|
| private static final byte OUT | |
| paramTypes | back to summary |
|---|---|
| private final int[] paramTypes | |
| paramValues | back to summary |
|---|---|
| private final @Nullable Object[] paramValues | |
| pos | back to summary |
|---|---|
| private int pos | |
| TEXT | back to summary |
|---|---|
| private static final byte TEXT | |
| transferModeRegistry | back to summary |
|---|---|
| private final @Nullable TypeTransferModeRegistry transferModeRegistry | |
| SimpleParameterList | back to summary |
|---|---|
| pack-priv SimpleParameterList(int paramCount, @Nullable TypeTransferModeRegistry transferModeRegistry) | |
| appendAll | back to summary |
|---|---|
| public void appendAll(ParameterList list) throws SQLException Implements org. Doc from org. Use this operation to append more parameters to the current list.
| |
| bind | back to summary |
|---|---|
| private void bind(int index, Object value, int oid, byte binary) throws SQLException | |
| checkAllParametersSet | back to summary |
|---|---|
| public void checkAllParametersSet() throws SQLException Implements org. Doc from org. Ensure that all parameters in this list have been assigned values. Return silently if all is well, otherwise throw an appropriate exception.
| |
| clear | back to summary |
|---|---|
| public void clear() Implements org. Doc from org. Unbind all parameter values bound in this list.
| |
| convertFunctionOutParameters | back to summary |
|---|---|
| public void convertFunctionOutParameters() Implements org. Doc from org. Convert any function output parameters to the correct type (void) and set an ignorable value for it.
| |
| copy | back to summary |
|---|---|
| public ParameterList copy() Implements org. Doc from org. Perform a shallow copy of this ParameterList, returning a new instance (still suitable for passing to the owning Query). If this ParameterList is immutable, copy() may return the same immutable object.
| |
| direction | back to summary |
|---|---|
| private byte direction(@Positive int index) | |
| getEncoding | back to summary |
|---|---|
| public @Nullable byte[][] getEncoding() Implements org. Doc from org. Return the encoding for each parameter. | |
| getFlags | back to summary |
|---|---|
| public byte[] getFlags() Implements org. Doc from org. Return the flags for each parameter.
| |
| getInParameterCount | back to summary |
|---|---|
| public @NonNegative int getInParameterCount() Implements org. Doc from org. Get the number of IN parameters in this list.
| |
| getOutParameterCount | back to summary |
|---|---|
| public @NonNegative int getOutParameterCount() Implements org. Doc from org. Get the number of OUT parameters in this list.
| |
| getParameterCount | back to summary |
|---|---|
| public @NonNegative int getParameterCount() Implements org. Doc from org. Get the number of parameters in this list. This value never changes for a particular instance, and might be zero.
| |
| getParamTypes | back to summary |
|---|---|
| public int[] getParamTypes() Implements org. Doc from org. Return the parameter type information.
| |
| getSubparams | back to summary |
|---|---|
| public @Nullable SimpleParameterList[] getSubparams() Implements org. Doc from org. Return a list of the SimpleParameterList objects that make up this parameter list. If this object is already a SimpleParameterList, returns null (avoids an extra array construction in the common case).
| |
| getTypeOID | back to summary |
|---|---|
| pack-priv int getTypeOID(@Positive int index) | |
| getTypeOIDs | back to summary |
|---|---|
| public int[] getTypeOIDs() Implements org. Doc from org. Return the oids of the parameters in this list. May be null for a ParameterList that does not support typing of parameters.
| |
| getV3Length | back to summary |
|---|---|
| pack-priv int getV3Length(@Positive int index) | |
| getValues | back to summary |
|---|---|
| public @Nullable Object[] getValues() Implements org. Doc from org. Returns the bound parameter values. | |
| hasUnresolvedTypes | back to summary |
|---|---|
| pack-priv boolean hasUnresolvedTypes() | |
| isBinary | back to summary |
|---|---|
| pack-priv boolean isBinary(@Positive int index) | |
| isNull | back to summary |
|---|---|
| pack-priv boolean isNull(@Positive int index) | |
| quoteAndCast | back to summary |
|---|---|
| private static String quoteAndCast(String text, @Nullable String type, boolean standardConformingStrings) Escapes a given text value as a literal, wraps it in single quotes, casts it to the to the given data type, and finally wraps the whole thing in parentheses. For example, "123" and "int4" becomes "('123'::int)" The additional parentheses is added to ensure that the surrounding text of where the parameter value is entered does modify the interpretation of the value. For example if our input SQL is: Using a parameter value of '{}' and type of json we'd get:
test=# SELECT ('{}'::json)b;
b
----
{}
But without the parentheses the result changes:
test=# SELECT '{}'::jsonb;
jsonb
-------
{}
| |
| registerOutParameter | back to summary |
|---|---|
public void registerOutParameter(int index, int sqlType) throws SQLException
| |
| setBinaryParameter | back to summary |
|---|---|
public void setBinaryParameter(@Positive int index, byte[] value, int oid) throws SQLException
| |
| setBytea | back to summary |
|---|---|
public void setBytea(@Positive int index, byte[] data, int offset, @NonNegative int length) throws SQLException
| |
| setBytea | back to summary |
|---|---|
public void setBytea(@Positive int index, InputStream stream, @NonNegative int length) throws SQLException
| |
| setBytea | back to summary |
|---|---|
public void setBytea(@Positive int index, InputStream stream) throws SQLException
| |
| setBytea | back to summary |
|---|---|
public void setBytea(@Positive int index, ByteStreamWriter writer) throws SQLException
| |
| setIntParameter | back to summary |
|---|---|
public void setIntParameter(@Positive int index, int value) throws SQLException
| |
| setLiteralParameter | back to summary |
|---|---|
public void setLiteralParameter(@Positive int index, String value, int oid) throws SQLException
| |
| setNull | back to summary |
|---|---|
public void setNull(@Positive int index, int oid) throws SQLException
| |
| setResolvedType | back to summary |
|---|---|
| pack-priv void setResolvedType(@Positive int index, int oid) | |
| setStringParameter | back to summary |
|---|---|
public void setStringParameter(@Positive int index, String value, int oid) throws SQLException
| |
| setText | back to summary |
|---|---|
public void setText(@Positive int index, InputStream stream) throws SQLException
| |
| streamBytea | back to summary |
|---|---|
| private static void streamBytea(PGStream pgStream, StreamWrapper wrapper) throws IOException | |
| streamBytea | back to summary |
|---|---|
| private static void streamBytea(PGStream pgStream, ByteStreamWriter writer) throws IOException | |
| toString | back to summary |
|---|---|
public String toString(@Positive int index, boolean standardConformingStrings)
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Useful implementation of toString. | |
| writeV3Value | back to summary |
|---|---|
| pack-priv void writeV3Value(@Positive int index, PGStream pgStream) throws IOException | |