Class ParameterBufferHelper


  • public class ParameterBufferHelper
    extends java.lang.Object
    This class maps the extended JDBC properties to parameter buffer types (for transaction and database parameter buffers). It uses java.lang.reflection to determine correct type of the parameter passed to the Driver.connect(String, Properties) method.
    Version:
    1.0
    Author:
    Roman Rokytskyy, Mark Rotteveel
    • Constructor Detail

      • ParameterBufferHelper

        public ParameterBufferHelper()
    • Method Detail

      • getDpbKey

        public static java.lang.Integer getDpbKey​(java.lang.String name)
        Get integer value of the DPB key corresponding to the specified name.
        Parameters:
        name - name of the key.
        Returns:
        instance of Integer corresponding to the specified name or null if value is not known.
      • getDpbMap

        public static java.util.Map<java.lang.String,​java.lang.Integer> getDpbMap()
        Get mapping between DPB names and their keys.
        Returns:
        instance of Map, where key is the name of DPB parameter, value is its DPB key.
      • parseDpbString

        @Deprecated
        public static java.lang.Object parseDpbString​(java.lang.String name,
                                                      java.lang.Object value)
        Deprecated.
        In general, parseDpbString(String, String) should be used; this method is not planned for removal
        Parse object to DPB value.
        Parameters:
        name - Name of DPB item
        value - Value to parse
        Returns:
        Object type appropriate for this DPB type
      • parseDpbString

        public static java.lang.Object parseDpbString​(java.lang.String name,
                                                      java.lang.String value)
        Parse string to DPB value.
        Parameters:
        name - Name of DPB item
        value - Value to parse
        Returns:
        Object type appropriate for this DPB type
      • getTpbParam

        public static java.lang.Integer getTpbParam​(java.lang.String name)
        Get value of TPB parameter for the specified name. This method tries to match string representation of the TPB parameter with its value.
        Parameters:
        name - string representation of TPB parameter, can have "isc_tpb_" prefix.
        Returns:
        value corresponding to the specified parameter name or null if nothing was found.