Class SqlCmdParams


  • public class SqlCmdParams
    extends java.lang.Object
    Holds the information about the type and value of the parameters passed to the command.
    • Constructor Summary

      Constructors 
      Constructor Description
      SqlCmdParams()
      Default Constructor
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      CmdParamsType getCmdParamsType()
      Gets the SqlDbType of the passed parameter.
      SqlCmpOptions getCompareInfo()
      Gets the CompareInfo object that defines how string comparisons should be performed for this parameter.
      boolean getIsNullable()
      Gets a value that indicates whether the parameter accepts null values.
      int getLocaleId()
      Gets the locale identifier that determines conventions and language for a particular region.
      int getoffset()
      Gets the offset to the Value property.
      byte getPrecision()
      Gets the maximum number of digits used to represent the Value property.
      byte getScale()
      Gets the number of decimal places to which Value is resolved.
      int getSize()
      Gets the maximum size, in bytes, of the data within the column.
      java.lang.String getSourceColumn()
      Gets the name of the source column mapped to the DataSet and used for loading or returning the Value.
      boolean getSourceColumnNullMapping()
      Gets a value which indicates whether the source column is nullable.
      SqlDataRowVersion getSourceVersion()
      Sets the DataRowVersion to use when you load Value.
      SqlParamDirection getSqlParameterDirection()
      Gets a value that indicates whether the parameter is input-only, output-only, bidirectional, or a stored procedure return value parameter.
      java.lang.Object getSqlValue()
      Gets the value of the parameter as a SQL type.
      java.lang.String getTypeName()
      Gets the type name for a table-valued parameter.
      java.lang.String getUdtTypeName()
      Gets a string that represents a user-defined type as a parameter.
      java.lang.Object getValue()
      Gets the value of the passed parameter.
      void setCmdParamsType​(CmdParamsType type)
      Sets the SqlDbType of the passed parameter.
      void setCompareInfo​(SqlCmpOptions compareInfo)
      Sets the CompareInfo object that defines how string comparisons should be performed for this parameter.
      void setIsNullable​(boolean isNullable)
      Sets a value that indicates whether the parameter accepts null values.
      void setLocaleId​(int localeId)
      Sets the locale identifier that determines conventions and language for a particular region.
      void setoffset​(int offset)
      Sets the offset to the Value property.
      void setprecision​(byte precision)
      Sets the maximum number of digits used to represent the Value property.
      void setScale​(byte scale)
      Sets the number of decimal places to which Value is resolved.
      void setSize​(int size)
      Sets the maximum size, in bytes, of the data within the column.
      void setSourceColumn​(java.lang.String sourceColumn)
      Sets the name of the source column mapped to the DataSet and used for loading or returning the Value.
      void setSourceColumnNullMapping​(boolean sourceColumnNullMapping)
      Sets a value which indicates whether the source column is nullable.
      void setSourceVersion​(SqlDataRowVersion sourceVersion)
      Sets the DataRowVersion to use when you load Value.
      void setSqlParameterDirection​(SqlParamDirection direction)
      Sets a value that indicates whether the parameter is input-only, output-only, bidirectional, or a stored procedure return value parameter.
      void setSqlValue​(java.lang.Object sqlValue)
      Sets the value of the parameter as a SQL type.
      void setTypeName​(java.lang.String typeName)
      Sets the type name for a table-valued parameter.
      void setUdtTypeName​(java.lang.String UdtTypeName)
      Sets a string that represents a user-defined type as a parameter.
      void setValue​(java.lang.Object value)
      Sets the value of the passed parameter.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • SqlCmdParams

        public SqlCmdParams()
        Default Constructor
    • Method Detail

      • getCmdParamsType

        public CmdParamsType getCmdParamsType()
        Gets the SqlDbType of the passed parameter.
        Returns:
        The SqlDbType of the parameter.
      • setCmdParamsType

        public void setCmdParamsType​(CmdParamsType type)
        Sets the SqlDbType of the passed parameter.
        Parameters:
        type - The SqlDbType of the parameter.
      • getSqlParameterDirection

        public SqlParamDirection getSqlParameterDirection()
        Gets a value that indicates whether the parameter is input-only, output-only, bidirectional, or a stored procedure return value parameter.
        Returns:
        The sql param direction of parameter.
      • setSqlParameterDirection

        public void setSqlParameterDirection​(SqlParamDirection direction)
        Sets a value that indicates whether the parameter is input-only, output-only, bidirectional, or a stored procedure return value parameter.
        Parameters:
        direction - The sql param direction of parameter.
      • getValue

        public java.lang.Object getValue()
        Gets the value of the passed parameter.
        Returns:
        The parameter value.
      • setValue

        public void setValue​(java.lang.Object value)
        Sets the value of the passed parameter.
        Parameters:
        value - The parameter value.
      • getSize

        public int getSize()
        Gets the maximum size, in bytes, of the data within the column.
        Returns:
        The datasize within the column.
      • setSize

        public void setSize​(int size)
        Sets the maximum size, in bytes, of the data within the column.
        Parameters:
        size - The datasize within the column.
      • getIsNullable

        public boolean getIsNullable()
        Gets a value that indicates whether the parameter accepts null values.
        Returns:
        True of the parameter accepts null value otherwise false.
      • setIsNullable

        public void setIsNullable​(boolean isNullable)
        Sets a value that indicates whether the parameter accepts null values.
        Parameters:
        isNullable - The boolean that specifies whether parameter accepts null values or not.
      • getLocaleId

        public int getLocaleId()
        Gets the locale identifier that determines conventions and language for a particular region.
        Returns:
        The locale id.
      • setLocaleId

        public void setLocaleId​(int localeId)
        Sets the locale identifier that determines conventions and language for a particular region.
        Parameters:
        localeId - The locale id.
      • getoffset

        public int getoffset()
        Gets the offset to the Value property.
        Returns:
        The offset of the value.
      • setoffset

        public void setoffset​(int offset)
        Sets the offset to the Value property.
        Parameters:
        offset - The offset of the value.
      • getPrecision

        public byte getPrecision()
        Gets the maximum number of digits used to represent the Value property.
        Returns:
        The precision of the value.
      • setprecision

        public void setprecision​(byte precision)
        Sets the maximum number of digits used to represent the Value property.
        Parameters:
        precision - The precision of the value.
      • getScale

        public byte getScale()
        Gets the number of decimal places to which Value is resolved.
        Returns:
        The scale of the value.
      • setScale

        public void setScale​(byte scale)
        Sets the number of decimal places to which Value is resolved.
        Parameters:
        scale - The scale of the value.
      • getSourceColumn

        public java.lang.String getSourceColumn()
        Gets the name of the source column mapped to the DataSet and used for loading or returning the Value.
        Returns:
        The name of the source column.
      • setSourceColumn

        public void setSourceColumn​(java.lang.String sourceColumn)
        Sets the name of the source column mapped to the DataSet and used for loading or returning the Value.
        Parameters:
        sourceColumn - The name of the source column.
      • getSourceColumnNullMapping

        public boolean getSourceColumnNullMapping()
        Gets a value which indicates whether the source column is nullable. This allows SqlCommandBuilder to correctly generate Update statements for nullable columns.
        Returns:
        True if source column accepts null values otherwise false.
      • setSourceColumnNullMapping

        public void setSourceColumnNullMapping​(boolean sourceColumnNullMapping)
        Sets a value which indicates whether the source column is nullable. This allows SqlCommandBuilder to correctly generate Update statements for nullable columns.
        Parameters:
        sourceColumnNullMapping - Specifies whether source column accepts null values or not.
      • getSqlValue

        public java.lang.Object getSqlValue()
        Gets the value of the parameter as a SQL type.
        Returns:
        The value of the parameter as SQL type.
      • setSqlValue

        public void setSqlValue​(java.lang.Object sqlValue)
        Sets the value of the parameter as a SQL type.
        Parameters:
        sqlValue - The value of the parameter as SQL type.
      • getTypeName

        public java.lang.String getTypeName()
        Gets the type name for a table-valued parameter.
        Returns:
        The typename of the table-valued parameter.
      • setTypeName

        public void setTypeName​(java.lang.String typeName)
        Sets the type name for a table-valued parameter.
        Parameters:
        typeName - The typename of the table-valued parameter.
      • getUdtTypeName

        public java.lang.String getUdtTypeName()
        Gets a string that represents a user-defined type as a parameter.
        Returns:
        The user-defined type as parameter.
      • setUdtTypeName

        public void setUdtTypeName​(java.lang.String UdtTypeName)
        Sets a string that represents a user-defined type as a parameter.
        Parameters:
        UdtTypeName - The user-defined type as parameter.
      • getSourceVersion

        public SqlDataRowVersion getSourceVersion()
        Sets the DataRowVersion to use when you load Value.
        Returns:
        The DataRowVersion of the value.
      • setSourceVersion

        public void setSourceVersion​(SqlDataRowVersion sourceVersion)
        Sets the DataRowVersion to use when you load Value.
        Parameters:
        sourceVersion - The DataRowVersion of the value.
      • getCompareInfo

        public SqlCmpOptions getCompareInfo()
        Gets the CompareInfo object that defines how string comparisons should be performed for this parameter.
        Returns:
        The object that defines string comparisons for the parameter.
      • setCompareInfo

        public void setCompareInfo​(SqlCmpOptions compareInfo)
        Sets the CompareInfo object that defines how string comparisons should be performed for this parameter.
        Parameters:
        compareInfo - The object that defines string comparisons for the parameter.