351 /**
352 * The <code>Reader</code> object that will be
353 * returned by the method <code>getCharacterStream</code>,
354 * which is specified in the <code>ResultSet</code> interface.
355 * @serial
356 */
357 protected java.io.Reader charStream;
358
359 /**
360 * The query that will be sent to the DBMS for execution when the
361 * method <code>execute</code> is called.
362 * @serial
363 */
364 private String command;
365
366 /**
367 * The JDBC URL the reader, writer, or both supply to the method
368 * <code>DriverManager.getConnection</code> when the
369 * <code>DriverManager</code> is used to get a connection.
370 * <P>
371 * The JDBC URL identifies the driver to be used to make the conndection.
372 * This URL can be found in the documentation supplied by the driver
373 * vendor.
374 * @serial
375 */
376 private String URL;
377
378 /**
379 * The logical name of the data source that the reader/writer should use
380 * in order to retrieve a <code>DataSource</code> object from a Java
381 * Directory and Naming Interface (JNDI) naming service.
382 * @serial
383 */
384 private String dataSource;
385
386 /**
387 * The user name the reader, writer, or both supply to the method
388 * <code>DriverManager.getConnection</code> when the
389 * <code>DriverManager</code> is used to get a connection.
390 * @serial
391 */
545 protected void initParams() {
546 params = new Hashtable<Integer, Object>();
547 }
548
549 //--------------------------------------------------------------------
550 // Events
551 //--------------------------------------------------------------------
552
553 /**
554 * The listener will be notified whenever an event occurs on this <code>RowSet</code>
555 * object.
556 * <P>
557 * A listener might, for example, be a table or graph that needs to
558 * be updated in order to accurately reflect the current state of
559 * the <code>RowSet</code> object.
560 * <p>
561 * <b>Note</b>: if the <code>RowSetListener</code> object is
562 * <code>null</code>, this method silently discards the <code>null</code>
563 * value and does not add a null reference to the set of listeners.
564 * <p>
565 * <b>Note</b>: if the listener is already set, and the new <code>RowSetListerner</code>
566 * instance is added to the set of listeners already registered to receive
567 * event notifications from this <code>RowSet</code>.
568 *
569 * @param listener an object that has implemented the
570 * <code>javax.sql.RowSetListener</code> interface and wants to be notified
571 * of any events that occur on this <code>RowSet</code> object; May be
572 * null.
573 * @see #removeRowSetListener
574 */
575 public void addRowSetListener(RowSetListener listener) {
576 listeners.add(listener);
577 }
578
579 /**
580 * Removes the designated object from this <code>RowSet</code> object's list of listeners.
581 * If the given argument is not a registered listener, this method
582 * does nothing.
583 *
584 * <b>Note</b>: if the <code>RowSetListener</code> object is
585 * <code>null</code>, this method silently discards the <code>null</code>
750 * data source.
751 *
752 * @return a <code>String</code> object that contains the JDBC URL
753 * used to establish the connection for this <code>RowSet</code>
754 * object; may be <code>null</code> (default value) if not set
755 * @throws SQLException if an error occurs retrieving the URL value
756 * @see #setUrl
757 */
758 public String getUrl() throws SQLException {
759 return URL;
760 }
761
762 /**
763 * Sets the Url property for this <code>RowSet</code> object
764 * to the given <code>String</code> object and sets the dataSource name
765 * property to <code>null</code>. The Url property is a
766 * JDBC URL that is used when
767 * the connection is created using a JDBC technology-enabled driver
768 * ("JDBC driver") and the <code>DriverManager</code>.
769 * The correct JDBC URL for the specific driver to be used can be found
770 * in the driver documentation. Although there are guidelines for for how
771 * a JDBC URL is formed,
772 * a driver vendor can specify any <code>String</code> object except
773 * one with a length of <code>0</code> (an empty string).
774 * <P>
775 * Setting the Url property is optional if connections are established using
776 * a <code>DataSource</code> object instead of the <code>DriverManager</code>.
777 * The driver will use either the URL property or the
778 * dataSourceName property to create a connection, whichever was
779 * specified most recently. If an application uses a JDBC URL, it
780 * must load a JDBC driver that accepts the JDBC URL before it uses the
781 * <code>RowSet</code> object to connect to a database. The <code>RowSet</code>
782 * object will use the URL internally to create a database connection in order
783 * to read or write data.
784 *
785 * @param url a <code>String</code> object that contains the JDBC URL
786 * that will be used to establish the connection to a database for this
787 * <code>RowSet</code> object; may be <code>null</code> but must not
788 * be an empty string
789 * @throws SQLException if an error occurs setting the Url property or the
790 * parameter supplied is a string with a length of <code>0</code> (an
1076 * <code>Connection.TRANSACTION_REPEATABLE_READ</code>, or
1077 * <code>Connection.TRANSACTION_SERIALIZABLE</code>
1078 * @throws SQLException if the given parameter is not one of the Connection
1079 * constants
1080 * @see javax.sql.rowset.spi.SyncFactory
1081 * @see javax.sql.rowset.spi.SyncProvider
1082 * @see #getTransactionIsolation
1083 */
1084 public void setTransactionIsolation(int level) throws SQLException {
1085 if ((level != Connection.TRANSACTION_NONE) &&
1086 (level != Connection.TRANSACTION_READ_COMMITTED) &&
1087 (level != Connection.TRANSACTION_READ_UNCOMMITTED) &&
1088 (level != Connection.TRANSACTION_REPEATABLE_READ) &&
1089 (level != Connection.TRANSACTION_SERIALIZABLE))
1090 {
1091 throw new SQLException("Invalid transaction isolation set. Must " +
1092 "be either " +
1093 "Connection.TRANSACTION_NONE or " +
1094 "Connection.TRANSACTION_READ_UNCOMMITTED or " +
1095 "Connection.TRANSACTION_READ_COMMITTED or " +
1096 "Connection.RRANSACTION_REPEATABLE_READ or " +
1097 "Connection.TRANSACTION_SERIALIZABLE");
1098 }
1099 this.isolation = level;
1100 }
1101
1102 /**
1103 * Retrieves the type map associated with the <code>Connection</code>
1104 * object for this <code>RowSet</code> object.
1105 * <P>
1106 * Drivers that support the JDBC 3.0 API will create
1107 * <code>Connection</code> objects with an associated type map.
1108 * This type map, which is initially empty, can contain one or more
1109 * fully-qualified SQL names and <code>Class</code> objects indicating
1110 * the class to which the named SQL value will be mapped. The type mapping
1111 * specified in the connection's type map is used for custom type mapping
1112 * when no other type map supersedes it.
1113 * <p>
1114 * If a type map is explicitly supplied to a method that can perform
1115 * custom mapping, that type map supersedes the connection's type map.
1116 *
3193 } //end getParams
3194
3195
3196 /**
3197 * Sets the designated parameter to SQL <code>NULL</code>.
3198 *
3199 * <P><B>Note:</B> You must specify the parameter's SQL type.
3200 *
3201 * @param parameterName the name of the parameter
3202 * @param sqlType the SQL type code defined in <code>java.sql.Types</code>
3203 * @exception SQLException if a database access error occurs or
3204 * this method is called on a closed <code>CallableStatement</code>
3205 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3206 * this method
3207 * @since 1.4
3208 */
3209 public void setNull(String parameterName, int sqlType) throws SQLException {
3210 throw new SQLFeatureNotSupportedException("Feature not supported");
3211 }
3212
3213
3214 /**
3215 * Sets the designated parameter to SQL <code>NULL</code>.
3216 * This version of the method <code>setNull</code> should
3217 * be used for user-defined types and REF type parameters. Examples
3218 * of user-defined types include: STRUCT, DISTINCT, JAVA_OBJECT, and
3219 * named array types.
3220 *
3221 * <P><B>Note:</B> To be portable, applications must give the
3222 * SQL type code and the fully-qualified SQL type name when specifying
3223 * a NULL user-defined or REF parameter. In the case of a user-defined type
3224 * the name is the type name of the parameter itself. For a REF
3225 * parameter, the name is the type name of the referenced type. If
3226 * a JDBC driver does not need the type code or type name information,
3227 * it may ignore it.
3228 *
3229 * Although it is intended for user-defined and Ref parameters,
3230 * this method may be used to set a null parameter of any JDBC type.
3231 * If the parameter does not have a user-defined or REF type, the given
3232 * typeName is ignored.
3233 *
3234 *
3235 * @param parameterName the name of the parameter
3236 * @param sqlType a value from <code>java.sql.Types</code>
3237 * @param typeName the fully-qualified name of an SQL user-defined type;
3238 * ignored if the parameter is not a user-defined type or
3239 * SQL <code>REF</code> value
3240 * @exception SQLException if a database access error occurs or
3241 * this method is called on a closed <code>CallableStatement</code>
3242 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3243 * this method
3244 * @since 1.4
3245 */
3246 public void setNull (String parameterName, int sqlType, String typeName)
3247 throws SQLException{
3248 throw new SQLFeatureNotSupportedException("Feature not supported");
3249 }
3250
3251
3252
3253 /**
3254 * Sets the designated parameter to the given Java <code>boolean</code> value.
3255 * The driver converts this
3256 * to an SQL <code>BIT</code> or <code>BOOLEAN</code> value when it sends it to the database.
3257 *
3258 * @param parameterName the name of the parameter
3259 * @param x the parameter value
3260 * @exception SQLException if a database access error occurs or
3261 * this method is called on a closed <code>CallableStatement</code>
3262 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3263 * this method
3264 * @see #getParams
3265 * @since 1.4
3266 */
3267 public void setBoolean(String parameterName, boolean x) throws SQLException{
3268 throw new SQLFeatureNotSupportedException("Feature not supported");
3269 }
3270
3271
3272
3273 /**
3274 * Sets the designated parameter to the given Java <code>byte</code> value.
3275 * The driver converts this
3276 * to an SQL <code>TINYINT</code> value when it sends it to the database.
3277 *
3278 * @param parameterName the name of the parameter
3279 * @param x the parameter value
3280 * @exception SQLException if a database access error occurs or
3281 * this method is called on a closed <code>CallableStatement</code>
3282 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3283 * this method
3284 * @see #getParams
3285 * @since 1.4
3286 */
3287 public void setByte(String parameterName, byte x) throws SQLException{
3288 throw new SQLFeatureNotSupportedException("Feature not supported");
3289 }
3290
3291
3292
3293 /**
3294 * Sets the designated parameter to the given Java <code>short</code> value.
3295 * The driver converts this
3296 * to an SQL <code>SMALLINT</code> value when it sends it to the database.
3297 *
3298 * @param parameterName the name of the parameter
3299 * @param x the parameter value
3300 * @exception SQLException if a database access error occurs or
3301 * this method is called on a closed <code>CallableStatement</code>
3302 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3303 * this method
3304 * @see #getParams
3305 * @since 1.4
3306 */
3307 public void setShort(String parameterName, short x) throws SQLException{
3308 throw new SQLFeatureNotSupportedException("Feature not supported");
3309 }
3310
3311
3312 /**
3313 * Sets the designated parameter to the given Java <code>int</code> value.
3314 * The driver converts this
3315 * to an SQL <code>INTEGER</code> value when it sends it to the database.
3316 *
3317 * @param parameterName the name of the parameter
3318 * @param x the parameter value
3319 * @exception SQLException if a database access error occurs or
3320 * this method is called on a closed <code>CallableStatement</code>
3321 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3322 * this method
3323 * @see #getParams
3324 * @since 1.4
3325 */
3326 public void setInt(String parameterName, int x) throws SQLException{
3327 throw new SQLFeatureNotSupportedException("Feature not supported");
3328 }
3329
3330
3331 /**
3332 * Sets the designated parameter to the given Java <code>long</code> value.
3333 * The driver converts this
3334 * to an SQL <code>BIGINT</code> value when it sends it to the database.
3335 *
3336 * @param parameterName the name of the parameter
3337 * @param x the parameter value
3338 * @exception SQLException if a database access error occurs or
3339 * this method is called on a closed <code>CallableStatement</code>
3340 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3341 * this method
3342 * @see #getParams
3343 * @since 1.4
3344 */
3345 public void setLong(String parameterName, long x) throws SQLException{
3346 throw new SQLFeatureNotSupportedException("Feature not supported");
3347 }
3348
3349
3350 /**
3351 * Sets the designated parameter to the given Java <code>float</code> value.
3352 * The driver converts this
3353 * to an SQL <code>FLOAT</code> value when it sends it to the database.
3354 *
3355 * @param parameterName the name of the parameter
3356 * @param x the parameter value
3357 * @exception SQLException if a database access error occurs or
3358 * this method is called on a closed <code>CallableStatement</code>
3359 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3360 * this method
3361 * @see #getParams
3362 * @since 1.4
3363 */
3364 public void setFloat(String parameterName, float x) throws SQLException{
3365 throw new SQLFeatureNotSupportedException("Feature not supported");
3366 }
3367
3368
3369 /**
3370 * Sets the designated parameter to the given Java <code>double</code> value.
3371 * The driver converts this
3372 * to an SQL <code>DOUBLE</code> value when it sends it to the database.
3373 *
3374 * @param parameterName the name of the parameter
3375 * @param x the parameter value
3376 * @exception SQLException if a database access error occurs or
3377 * this method is called on a closed <code>CallableStatement</code>
3378 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3379 * this method
3380 * @see #getParams
3381 * @since 1.4
3382 */
3383 public void setDouble(String parameterName, double x) throws SQLException{
3384 throw new SQLFeatureNotSupportedException("Feature not supported");
3385 }
3386
3387
3388
3389 /**
3390 * Sets the designated parameter to the given
3391 * <code>java.math.BigDecimal</code> value.
3392 * The driver converts this to an SQL <code>NUMERIC</code> value when
3393 * it sends it to the database.
3394 *
3395 * @param parameterName the name of the parameter
3396 * @param x the parameter value
3397 * @exception SQLException if a database access error occurs or
3398 * this method is called on a closed <code>CallableStatement</code>
3399 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3400 * this method
3401 * @see #getParams
3402 * @since 1.4
3403 */
3404 public void setBigDecimal(String parameterName, BigDecimal x) throws SQLException{
3405 throw new SQLFeatureNotSupportedException("Feature not supported");
3406 }
3407
3408
3409
3410 /**
3411 * Sets the designated parameter to the given Java <code>String</code> value.
3412 * The driver converts this
3413 * to an SQL <code>VARCHAR</code> or <code>LONGVARCHAR</code> value
3414 * (depending on the argument's
3415 * size relative to the driver's limits on <code>VARCHAR</code> values)
3416 * when it sends it to the database.
3417 *
3418 * @param parameterName the name of the parameter
3419 * @param x the parameter value
3420 * @exception SQLException if a database access error occurs or
3421 * this method is called on a closed <code>CallableStatement</code>
3422 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3423 * this method
3424 * @see #getParams
3425 * @since 1.4
3426 */
3427 public void setString(String parameterName, String x) throws SQLException{
3428 throw new SQLFeatureNotSupportedException("Feature not supported");
3429 }
3430
3431
3432
3433 /**
3434 * Sets the designated parameter to the given Java array of bytes.
3435 * The driver converts this to an SQL <code>VARBINARY</code> or
3436 * <code>LONGVARBINARY</code> (depending on the argument's size relative
3437 * to the driver's limits on <code>VARBINARY</code> values) when it sends
3438 * it to the database.
3439 *
3440 * @param parameterName the name of the parameter
3441 * @param x the parameter value
3442 * @exception SQLException if a database access error occurs or
3443 * this method is called on a closed <code>CallableStatement</code>
3444 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3445 * this method
3446 * @see #getParams
3447 * @since 1.4
3448 */
3449 public void setBytes(String parameterName, byte x[]) throws SQLException{
3450 throw new SQLFeatureNotSupportedException("Feature not supported");
3451 }
3452
3453
3454
3455 /**
3456 * Sets the designated parameter to the given <code>java.sql.Timestamp</code> value.
3457 * The driver
3458 * converts this to an SQL <code>TIMESTAMP</code> value when it sends it to the
3459 * database.
3460 *
3461 * @param parameterName the name of the parameter
3462 * @param x the parameter value
3463 * @exception SQLException if a database access error occurs or
3464 * this method is called on a closed <code>CallableStatement</code>
3465 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3466 * this method
3467 * @see #getParams
3468 * @since 1.4
3469 */
3470 public void setTimestamp(String parameterName, java.sql.Timestamp x)
3471 throws SQLException{
3472 throw new SQLFeatureNotSupportedException("Feature not supported");
3473 }
3474
3475
3476
3477 /**
3478 * Sets the designated parameter to the given input stream, which will have
3479 * the specified number of bytes.
3480 * When a very large ASCII value is input to a <code>LONGVARCHAR</code>
3481 * parameter, it may be more practical to send it via a
3482 * <code>java.io.InputStream</code>. Data will be read from the stream
3483 * as needed until end-of-file is reached. The JDBC driver will
3484 * do any necessary conversion from ASCII to the database char format.
3485 *
3486 * <P><B>Note:</B> This stream object can either be a standard
3487 * Java stream object or your own subclass that implements the
3488 * standard interface.
3489 *
3490 * @param parameterName the name of the parameter
3491 * @param x the Java input stream that contains the ASCII parameter value
3492 * @param length the number of bytes in the stream
3493 * @exception SQLException if a database access error occurs or
3494 * this method is called on a closed <code>CallableStatement</code>
3495 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3496 * this method
3497 * @since 1.4
3498 */
3499 public void setAsciiStream(String parameterName, java.io.InputStream x, int length)
3500 throws SQLException{
3501 throw new SQLFeatureNotSupportedException("Feature not supported");
3502 }
3503
3504
3505 /**
3506 * Sets the designated parameter to the given input stream, which will have
3507 * the specified number of bytes.
3508 * When a very large binary value is input to a <code>LONGVARBINARY</code>
3509 * parameter, it may be more practical to send it via a
3510 * <code>java.io.InputStream</code> object. The data will be read from the stream
3511 * as needed until end-of-file is reached.
3512 *
3513 * <P><B>Note:</B> This stream object can either be a standard
3514 * Java stream object or your own subclass that implements the
3515 * standard interface.
3516 *
3517 * @param parameterName the name of the parameter
3518 * @param x the java input stream which contains the binary parameter value
3519 * @param length the number of bytes in the stream
3520 * @exception SQLException if a database access error occurs or
3521 * this method is called on a closed <code>CallableStatement</code>
3522 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3523 * this method
3524 * @since 1.4
3525 */
3526 public void setBinaryStream(String parameterName, java.io.InputStream x,
3527 int length) throws SQLException{
3528 throw new SQLFeatureNotSupportedException("Feature not supported");
3529 }
3530
3531
3532 /**
3533 * Sets the designated parameter to the given <code>Reader</code>
3534 * object, which is the given number of characters long.
3535 * When a very large UNICODE value is input to a <code>LONGVARCHAR</code>
3536 * parameter, it may be more practical to send it via a
3537 * <code>java.io.Reader</code> object. The data will be read from the stream
3538 * as needed until end-of-file is reached. The JDBC driver will
3539 * do any necessary conversion from UNICODE to the database char format.
3540 *
3541 * <P><B>Note:</B> This stream object can either be a standard
3542 * Java stream object or your own subclass that implements the
3543 * standard interface.
3544 *
3545 * @param parameterName the name of the parameter
3546 * @param reader the <code>java.io.Reader</code> object that
3547 * contains the UNICODE data used as the designated parameter
3548 * @param length the number of characters in the stream
3549 * @exception SQLException if a database access error occurs or
3550 * this method is called on a closed <code>CallableStatement</code>
3551 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3552 * this method
3553 * @since 1.4
3554 */
3555 public void setCharacterStream(String parameterName,
3556 java.io.Reader reader,
3557 int length) throws SQLException{
3558 throw new SQLFeatureNotSupportedException("Feature not supported");
3559 }
3560
3561
3562 /**
3563 * Sets the designated parameter to the given input stream.
3564 * When a very large ASCII value is input to a <code>LONGVARCHAR</code>
3565 * parameter, it may be more practical to send it via a
3566 * <code>java.io.InputStream</code>. Data will be read from the stream
3567 * as needed until end-of-file is reached. The JDBC driver will
3568 * do any necessary conversion from ASCII to the database char format.
3569 *
3570 * <P><B>Note:</B> This stream object can either be a standard
3571 * Java stream object or your own subclass that implements the
3572 * standard interface.
3573 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3574 * it might be more efficient to use a version of
3575 * <code>setAsciiStream</code> which takes a length parameter.
3576 *
3577 * @param parameterName the name of the parameter
3578 * @param x the Java input stream that contains the ASCII parameter value
3579 * @exception SQLException if a database access error occurs or
3580 * this method is called on a closed <code>CallableStatement</code>
3581 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3582 * @since 1.6
3583 */
3584 public void setAsciiStream(String parameterName, java.io.InputStream x)
3585 throws SQLException{
3586 throw new SQLFeatureNotSupportedException("Feature not supported");
3587 }
3588
3589
3590 /**
3591 * Sets the designated parameter to the given input stream.
3592 * When a very large binary value is input to a <code>LONGVARBINARY</code>
3593 * parameter, it may be more practical to send it via a
3594 * <code>java.io.InputStream</code> object. The data will be read from the
3595 * stream as needed until end-of-file is reached.
3596 *
3597 * <P><B>Note:</B> This stream object can either be a standard
3598 * Java stream object or your own subclass that implements the
3599 * standard interface.
3600 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3601 * it might be more efficient to use a version of
3602 * <code>setBinaryStream</code> which takes a length parameter.
3603 *
3604 * @param parameterName the name of the parameter
3605 * @param x the java input stream which contains the binary parameter value
3606 * @exception SQLException if a database access error occurs or
3607 * this method is called on a closed <code>CallableStatement</code>
3608 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3609 * @since 1.6
3610 */
3611 public void setBinaryStream(String parameterName, java.io.InputStream x)
3612 throws SQLException{
3613 throw new SQLFeatureNotSupportedException("Feature not supported");
3614 }
3615
3616
3617
3618 /**
3619 * Sets the designated parameter to the given <code>Reader</code>
3620 * object.
3621 * When a very large UNICODE value is input to a <code>LONGVARCHAR</code>
3622 * parameter, it may be more practical to send it via a
3623 * <code>java.io.Reader</code> object. The data will be read from the stream
3624 * as needed until end-of-file is reached. The JDBC driver will
3625 * do any necessary conversion from UNICODE to the database char format.
3626 *
3627 * <P><B>Note:</B> This stream object can either be a standard
3628 * Java stream object or your own subclass that implements the
3629 * standard interface.
3630 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3631 * it might be more efficient to use a version of
3632 * <code>setCharacterStream</code> which takes a length parameter.
3633 *
3634 * @param parameterName the name of the parameter
3635 * @param reader the <code>java.io.Reader</code> object that contains the
3636 * Unicode data
3637 * @exception SQLException if a database access error occurs or
3638 * this method is called on a closed <code>CallableStatement</code>
3639 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3640 * @since 1.6
3641 */
3642 public void setCharacterStream(String parameterName,
3643 java.io.Reader reader) throws SQLException{
3644 throw new SQLFeatureNotSupportedException("Feature not supported");
3645 }
3646
3647
3648 /**
3649 * Sets the designated parameter in this <code>RowSet</code> object's command
3650 * to a <code>Reader</code> object. The
3651 * <code>Reader</code> reads the data till end-of-file is reached. The
3652 * driver does the necessary conversion from Java character format to
3653 * the national character set in the database.
3654 *
3655 * <P><B>Note:</B> This stream object can either be a standard
3656 * Java stream object or your own subclass that implements the
3657 * standard interface.
3658 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3659 * it might be more efficient to use a version of
3660 * <code>setNCharacterStream</code> which takes a length parameter.
3661 *
3662 * @param parameterIndex of the first parameter is 1, the second is 2, ...
3663 * @param value the parameter value
3664 * @throws SQLException if the driver does not support national
3665 * character sets; if the driver can detect that a data conversion
3666 * error could occur ; if a database access error occurs; or
3667 * this method is called on a closed <code>PreparedStatement</code>
3668 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3669 * @since 1.6
3670 */
3671 public void setNCharacterStream(int parameterIndex, Reader value) throws SQLException{
3672 throw new SQLFeatureNotSupportedException("Feature not supported");
3673 }
3674
3675
3676
3677 /**
3678 * Sets the value of the designated parameter with the given object. The second
3679 * argument must be an object type; for integral values, the
3680 * <code>java.lang</code> equivalent objects should be used.
3681 *
3682 * <p>The given Java object will be converted to the given targetSqlType
3683 * before being sent to the database.
3684 *
3685 * If the object has a custom mapping (is of a class implementing the
3686 * interface <code>SQLData</code>),
3687 * the JDBC driver should call the method <code>SQLData.writeSQL</code> to write it
3688 * to the SQL data stream.
3689 * If, on the other hand, the object is of a class implementing
3690 * <code>Ref</code>, <code>Blob</code>, <code>Clob</code>, <code>NClob</code>,
3691 * <code>Struct</code>, <code>java.net.URL</code>,
3692 * or <code>Array</code>, the driver should pass it to the database as a
3693 * value of the corresponding SQL type.
3694 * <P>
3695 * Note that this method may be used to pass datatabase-
3696 * specific abstract data types.
3697 *
3698 * @param parameterName the name of the parameter
3699 * @param x the object containing the input parameter value
3700 * @param targetSqlType the SQL type (as defined in java.sql.Types) to be
3701 * sent to the database. The scale argument may further qualify this type.
3702 * @param scale for java.sql.Types.DECIMAL or java.sql.Types.NUMERIC types,
3703 * this is the number of digits after the decimal point. For all other
3704 * types, this value will be ignored.
3705 * @exception SQLException if a database access error occurs or
3706 * this method is called on a closed <code>CallableStatement</code>
3707 * @exception SQLFeatureNotSupportedException if <code>targetSqlType</code> is
3708 * a <code>ARRAY</code>, <code>BLOB</code>, <code>CLOB</code>,
3709 * <code>DATALINK</code>, <code>JAVA_OBJECT</code>, <code>NCHAR</code>,
3710 * <code>NCLOB</code>, <code>NVARCHAR</code>, <code>LONGNVARCHAR</code>,
3711 * <code>REF</code>, <code>ROWID</code>, <code>SQLXML</code>
3712 * or <code>STRUCT</code> data type and the JDBC driver does not support
3713 * this data type
3714 * @see Types
3715 * @see #getParams
3716 * @since 1.4
3717 */
3718 public void setObject(String parameterName, Object x, int targetSqlType, int scale)
3719 throws SQLException{
3720 throw new SQLFeatureNotSupportedException("Feature not supported");
3721 }
3722
3723
3724
3725 /**
3726 * Sets the value of the designated parameter with the given object.
3727 * This method is like the method <code>setObject</code>
3728 * above, except that it assumes a scale of zero.
3729 *
3730 * @param parameterName the name of the parameter
3731 * @param x the object containing the input parameter value
3732 * @param targetSqlType the SQL type (as defined in java.sql.Types) to be
3733 * sent to the database
3734 * @exception SQLException if a database access error occurs or
3735 * this method is called on a closed <code>CallableStatement</code>
3736 * @exception SQLFeatureNotSupportedException if <code>targetSqlType</code> is
3737 * a <code>ARRAY</code>, <code>BLOB</code>, <code>CLOB</code>,
3738 * <code>DATALINK</code>, <code>JAVA_OBJECT</code>, <code>NCHAR</code>,
3739 * <code>NCLOB</code>, <code>NVARCHAR</code>, <code>LONGNVARCHAR</code>,
3740 * <code>REF</code>, <code>ROWID</code>, <code>SQLXML</code>
3741 * or <code>STRUCT</code> data type and the JDBC driver does not support
3742 * this data type
3743 * @see #getParams
3744 * @since 1.4
3745 */
3746 public void setObject(String parameterName, Object x, int targetSqlType)
3747 throws SQLException{
3748 throw new SQLFeatureNotSupportedException("Feature not supported");
3749 }
3750
3751
3752 /**
3753 * Sets the value of the designated parameter with the given object.
3754 * The second parameter must be of type <code>Object</code>; therefore, the
3755 * <code>java.lang</code> equivalent objects should be used for built-in types.
3756 *
3757 * <p>The JDBC specification specifies a standard mapping from
3758 * Java <code>Object</code> types to SQL types. The given argument
3759 * will be converted to the corresponding SQL type before being
3760 * sent to the database.
3761 *
3762 * <p>Note that this method may be used to pass datatabase-
3763 * specific abstract data types, by using a driver-specific Java
3764 * type.
3765 *
3766 * If the object is of a class implementing the interface <code>SQLData</code>,
3767 * the JDBC driver should call the method <code>SQLData.writeSQL</code>
3768 * to write it to the SQL data stream.
3769 * If, on the other hand, the object is of a class implementing
3770 * <code>Ref</code>, <code>Blob</code>, <code>Clob</code>, <code>NClob</code>,
3771 * <code>Struct</code>, <code>java.net.URL</code>,
3772 * or <code>Array</code>, the driver should pass it to the database as a
3773 * value of the corresponding SQL type.
3774 * <P>
3775 * This method throws an exception if there is an ambiguity, for example, if the
3776 * object is of a class implementing more than one of the interfaces named above.
3777 *
3778 * @param parameterName the name of the parameter
3779 * @param x the object containing the input parameter value
3780 * @exception SQLException if a database access error occurs,
3781 * this method is called on a closed <code>CallableStatement</code> or if the given
3782 * <code>Object</code> parameter is ambiguous
3783 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3784 * this method
3785 * @see #getParams
3786 * @since 1.4
3787 */
3788 public void setObject(String parameterName, Object x) throws SQLException{
3789 throw new SQLFeatureNotSupportedException("Feature not supported");
3790 }
3791
3792
3793
3794 /**
3795 * Sets the designated parameter to a <code>InputStream</code> object. The inputstream must contain the number
3796 * of characters specified by length otherwise a <code>SQLException</code> will be
3797 * generated when the <code>PreparedStatement</code> is executed.
3798 * This method differs from the <code>setBinaryStream (int, InputStream, int)</code>
3799 * method because it informs the driver that the parameter value should be
3800 * sent to the server as a <code>BLOB</code>. When the <code>setBinaryStream</code> method is used,
3801 * the driver may have to do extra work to determine whether the parameter
3802 * data should be sent to the server as a <code>LONGVARBINARY</code> or a <code>BLOB</code>
3803 * @param parameterIndex index of the first parameter is 1,
3804 * the second is 2, ...
3805 * @param inputStream An object that contains the data to set the parameter
3806 * value to.
3807 * @param length the number of bytes in the parameter data.
3808 * @throws SQLException if a database access error occurs,
3809 * this method is called on a closed <code>PreparedStatement</code>,
3810 * if parameterIndex does not correspond
3811 * to a parameter marker in the SQL statement, if the length specified
3812 * is less than zero or if the number of bytes in the inputstream does not match
3813 * the specified length.
3814 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3815 *
3816 * @since 1.6
3817 */
3818 public void setBlob(int parameterIndex, InputStream inputStream, long length)
3819 throws SQLException{
3820 throw new SQLFeatureNotSupportedException("Feature not supported");
3821 }
3822
3823
3824 /**
3825 * Sets the designated parameter to a <code>InputStream</code> object.
3826 * This method differs from the <code>setBinaryStream (int, InputStream)</code>
3827 * method because it informs the driver that the parameter value should be
3828 * sent to the server as a <code>BLOB</code>. When the <code>setBinaryStream</code> method is used,
3829 * the driver may have to do extra work to determine whether the parameter
3830 * data should be sent to the server as a <code>LONGVARBINARY</code> or a <code>BLOB</code>
3831 *
3832 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3833 * it might be more efficient to use a version of
3834 * <code>setBlob</code> which takes a length parameter.
3835 *
3836 * @param parameterIndex index of the first parameter is 1,
3837 * the second is 2, ...
3838 * @param inputStream An object that contains the data to set the parameter
3839 * value to.
3840 * @throws SQLException if a database access error occurs,
3841 * this method is called on a closed <code>PreparedStatement</code> or
3842 * if parameterIndex does not correspond
3843 * to a parameter marker in the SQL statement,
3844 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3845 *
3846 * @since 1.6
3847 */
3848 public void setBlob(int parameterIndex, InputStream inputStream)
3849 throws SQLException{
3850 throw new SQLFeatureNotSupportedException("Feature not supported");
3851 }
3852
3853
3854 /**
3855 * Sets the designated parameter to a <code>InputStream</code> object. The <code>inputstream</code> must contain the number
3856 * of characters specified by length, otherwise a <code>SQLException</code> will be
3857 * generated when the <code>CallableStatement</code> is executed.
3858 * This method differs from the <code>setBinaryStream (int, InputStream, int)</code>
3859 * method because it informs the driver that the parameter value should be
3860 * sent to the server as a <code>BLOB</code>. When the <code>setBinaryStream</code> method is used,
3861 * the driver may have to do extra work to determine whether the parameter
3862 * data should be sent to the server as a <code>LONGVARBINARY</code> or a <code>BLOB</code>
3863 *
3864 * @param parameterName the name of the parameter to be set
3865 * the second is 2, ...
3866 *
3867 * @param inputStream An object that contains the data to set the parameter
3868 * value to.
3869 * @param length the number of bytes in the parameter data.
3870 * @throws SQLException if parameterIndex does not correspond
3871 * to a parameter marker in the SQL statement, or if the length specified
3872 * is less than zero; if the number of bytes in the inputstream does not match
3873 * the specified length; if a database access error occurs or
3874 * this method is called on a closed <code>CallableStatement</code>
3875 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3876 * this method
3877 *
3878 * @since 1.6
3879 */
3880 public void setBlob(String parameterName, InputStream inputStream, long length)
3881 throws SQLException{
3882 throw new SQLFeatureNotSupportedException("Feature not supported");
3883 }
3884
3885
3886 /**
3887 * Sets the designated parameter to the given <code>java.sql.Blob</code> object.
3888 * The driver converts this to an SQL <code>BLOB</code> value when it
3889 * sends it to the database.
3890 *
3891 * @param parameterName the name of the parameter
3892 * @param x a <code>Blob</code> object that maps an SQL <code>BLOB</code> value
3893 * @exception SQLException if a database access error occurs or
3894 * this method is called on a closed <code>CallableStatement</code>
3895 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3896 * this method
3897 * @since 1.6
3898 */
3899 public void setBlob (String parameterName, Blob x) throws SQLException{
3900 throw new SQLFeatureNotSupportedException("Feature not supported");
3901 }
3902
3903
3904 /**
3905 * Sets the designated parameter to a <code>InputStream</code> object.
3906 * This method differs from the <code>setBinaryStream (int, InputStream)</code>
3907 * method because it informs the driver that the parameter value should be
3908 * sent to the server as a <code>BLOB</code>. When the <code>setBinaryStream</code> method is used,
3909 * the driver may have to do extra work to determine whether the parameter
3910 * data should be send to the server as a <code>LONGVARBINARY</code> or a <code>BLOB</code>
3911 *
3912 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3913 * it might be more efficient to use a version of
3914 * <code>setBlob</code> which takes a length parameter.
3915 *
3916 * @param parameterName the name of the parameter
3917 * @param inputStream An object that contains the data to set the parameter
3918 * value to.
3919 * @throws SQLException if a database access error occurs or
3920 * this method is called on a closed <code>CallableStatement</code>
3921 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3922 *
3923 * @since 1.6
3924 */
3925 public void setBlob(String parameterName, InputStream inputStream)
3926 throws SQLException{
3927 throw new SQLFeatureNotSupportedException("Feature not supported");
3928 }
3929
3930
3931 /**
3932 * Sets the designated parameter to a <code>Reader</code> object. The reader must contain the number
3933 * of characters specified by length otherwise a <code>SQLException</code> will be
3934 * generated when the <code>PreparedStatement</code> is executed.
3935 *This method differs from the <code>setCharacterStream (int, Reader, int)</code> method
3936 * because it informs the driver that the parameter value should be sent to
3937 * the server as a <code>CLOB</code>. When the <code>setCharacterStream</code> method is used, the
3938 * driver may have to do extra work to determine whether the parameter
3939 * data should be sent to the server as a <code>LONGVARCHAR</code> or a <code>CLOB</code>
3940 * @param parameterIndex index of the first parameter is 1, the second is 2, ...
3941 * @param reader An object that contains the data to set the parameter value to.
3942 * @param length the number of characters in the parameter data.
3943 * @throws SQLException if a database access error occurs, this method is called on
3944 * a closed <code>PreparedStatement</code>, if parameterIndex does not correspond to a parameter
3945 * marker in the SQL statement, or if the length specified is less than zero.
3946 *
3947 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3948 * @since 1.6
3949 */
3950 public void setClob(int parameterIndex, Reader reader, long length)
3951 throws SQLException{
3952 throw new SQLFeatureNotSupportedException("Feature not supported");
3953 }
3954
3955
3956 /**
3957 * Sets the designated parameter to a <code>Reader</code> object.
3958 * This method differs from the <code>setCharacterStream (int, Reader)</code> method
3959 * because it informs the driver that the parameter value should be sent to
3960 * the server as a <code>CLOB</code>. When the <code>setCharacterStream</code> method is used, the
3961 * driver may have to do extra work to determine whether the parameter
3962 * data should be sent to the server as a <code>LONGVARCHAR</code> or a <code>CLOB</code>
3963 *
3964 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3965 * it might be more efficient to use a version of
3966 * <code>setClob</code> which takes a length parameter.
3967 *
3968 * @param parameterIndex index of the first parameter is 1, the second is 2, ...
3969 * @param reader An object that contains the data to set the parameter value to.
3970 * @throws SQLException if a database access error occurs, this method is called on
3971 * a closed <code>PreparedStatement</code>or if parameterIndex does not correspond to a parameter
3972 * marker in the SQL statement
3973 *
3974 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3975 * @since 1.6
3976 */
3977 public void setClob(int parameterIndex, Reader reader)
3978 throws SQLException{
3979 throw new SQLFeatureNotSupportedException("Feature not supported");
3980 }
3981
3982
3983 /**
3984 * Sets the designated parameter to a <code>Reader</code> object. The <code>reader</code> must contain the number
3985 * of characters specified by length otherwise a <code>SQLException</code> will be
3986 * generated when the <code>CallableStatement</code> is executed.
3987 * This method differs from the <code>setCharacterStream (int, Reader, int)</code> method
3988 * because it informs the driver that the parameter value should be sent to
3989 * the server as a <code>CLOB</code>. When the <code>setCharacterStream</code> method is used, the
3990 * driver may have to do extra work to determine whether the parameter
3991 * data should be send to the server as a <code>LONGVARCHAR</code> or a <code>CLOB</code>
3992 * @param parameterName the name of the parameter to be set
3993 * @param reader An object that contains the data to set the parameter value to.
3994 * @param length the number of characters in the parameter data.
3995 * @throws SQLException if parameterIndex does not correspond to a parameter
3996 * marker in the SQL statement; if the length specified is less than zero;
3997 * a database access error occurs or
3998 * this method is called on a closed <code>CallableStatement</code>
3999 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4000 * this method
4001 *
4002 * @since 1.6
4003 */
4004 public void setClob(String parameterName, Reader reader, long length)
4005 throws SQLException{
4006 throw new SQLFeatureNotSupportedException("Feature not supported");
4007 }
4008
4009
4010 /**
4011 * Sets the designated parameter to the given <code>java.sql.Clob</code> object.
4012 * The driver converts this to an SQL <code>CLOB</code> value when it
4013 * sends it to the database.
4014 *
4015 * @param parameterName the name of the parameter
4016 * @param x a <code>Clob</code> object that maps an SQL <code>CLOB</code> value
4017 * @exception SQLException if a database access error occurs or
4018 * this method is called on a closed <code>CallableStatement</code>
4019 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4020 * this method
4021 * @since 1.6
4022 */
4023 public void setClob (String parameterName, Clob x) throws SQLException{
4024 throw new SQLFeatureNotSupportedException("Feature not supported");
4025 }
4026
4027
4028 /**
4029 * Sets the designated parameter to a <code>Reader</code> object.
4030 * This method differs from the <code>setCharacterStream (int, Reader)</code> method
4031 * because it informs the driver that the parameter value should be sent to
4032 * the server as a <code>CLOB</code>. When the <code>setCharacterStream</code> method is used, the
4033 * driver may have to do extra work to determine whether the parameter
4034 * data should be send to the server as a <code>LONGVARCHAR</code> or a <code>CLOB</code>
4035 *
4036 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
4037 * it might be more efficient to use a version of
4038 * <code>setClob</code> which takes a length parameter.
4039 *
4040 * @param parameterName the name of the parameter
4041 * @param reader An object that contains the data to set the parameter value to.
4042 * @throws SQLException if a database access error occurs or this method is called on
4043 * a closed <code>CallableStatement</code>
4044 *
4045 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
4046 * @since 1.6
4047 */
4048 public void setClob(String parameterName, Reader reader)
4049 throws SQLException{
4050 throw new SQLFeatureNotSupportedException("Feature not supported");
4051 }
4052
4053
4054 /**
4055 * Sets the designated parameter to the given <code>java.sql.Date</code> value
4056 * using the default time zone of the virtual machine that is running
4057 * the application.
4058 * The driver converts this
4059 * to an SQL <code>DATE</code> value when it sends it to the database.
4060 *
4061 * @param parameterName the name of the parameter
4062 * @param x the parameter value
4063 * @exception SQLException if a database access error occurs or
4064 * this method is called on a closed <code>CallableStatement</code>
4065 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4066 * this method
4067 * @see #getParams
4068 * @since 1.4
4069 */
4070 public void setDate(String parameterName, java.sql.Date x)
4071 throws SQLException{
4072 throw new SQLFeatureNotSupportedException("Feature not supported");
4073 }
4074
4075
4076 /**
4077 * Sets the designated parameter to the given <code>java.sql.Date</code> value,
4078 * using the given <code>Calendar</code> object. The driver uses
4079 * the <code>Calendar</code> object to construct an SQL <code>DATE</code> value,
4080 * which the driver then sends to the database. With a
4081 * a <code>Calendar</code> object, the driver can calculate the date
4082 * taking into account a custom timezone. If no
4083 * <code>Calendar</code> object is specified, the driver uses the default
4084 * timezone, which is that of the virtual machine running the application.
4085 *
4086 * @param parameterName the name of the parameter
4087 * @param x the parameter value
4088 * @param cal the <code>Calendar</code> object the driver will use
4089 * to construct the date
4090 * @exception SQLException if a database access error occurs or
4091 * this method is called on a closed <code>CallableStatement</code>
4092 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4093 * this method
4094 * @see #getParams
4095 * @since 1.4
4096 */
4097 public void setDate(String parameterName, java.sql.Date x, Calendar cal)
4098 throws SQLException{
4099 throw new SQLFeatureNotSupportedException("Feature not supported");
4100 }
4101
4102
4103 /**
4104 * Sets the designated parameter to the given <code>java.sql.Time</code> value.
4105 * The driver converts this
4106 * to an SQL <code>TIME</code> value when it sends it to the database.
4107 *
4108 * @param parameterName the name of the parameter
4109 * @param x the parameter value
4110 * @exception SQLException if a database access error occurs or
4111 * this method is called on a closed <code>CallableStatement</code>
4112 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4113 * this method
4114 * @see #getParams
4115 * @since 1.4
4116 */
4117 public void setTime(String parameterName, java.sql.Time x)
4118 throws SQLException{
4119 throw new SQLFeatureNotSupportedException("Feature not supported");
4120 }
4121
4122
4123 /**
4124 * Sets the designated parameter to the given <code>java.sql.Time</code> value,
4125 * using the given <code>Calendar</code> object. The driver uses
4126 * the <code>Calendar</code> object to construct an SQL <code>TIME</code> value,
4127 * which the driver then sends to the database. With a
4128 * a <code>Calendar</code> object, the driver can calculate the time
4129 * taking into account a custom timezone. If no
4130 * <code>Calendar</code> object is specified, the driver uses the default
4131 * timezone, which is that of the virtual machine running the application.
4132 *
4133 * @param parameterName the name of the parameter
4134 * @param x the parameter value
4135 * @param cal the <code>Calendar</code> object the driver will use
4136 * to construct the time
4137 * @exception SQLException if a database access error occurs or
4138 * this method is called on a closed <code>CallableStatement</code>
4139 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4140 * this method
4141 * @see #getParams
4142 * @since 1.4
4143 */
4144 public void setTime(String parameterName, java.sql.Time x, Calendar cal)
4145 throws SQLException{
4146 throw new SQLFeatureNotSupportedException("Feature not supported");
4147 }
4148
4149
4150 /**
4151 * Sets the designated parameter to the given <code>java.sql.Timestamp</code> value,
4152 * using the given <code>Calendar</code> object. The driver uses
4153 * the <code>Calendar</code> object to construct an SQL <code>TIMESTAMP</code> value,
4154 * which the driver then sends to the database. With a
4155 * a <code>Calendar</code> object, the driver can calculate the timestamp
4156 * taking into account a custom timezone. If no
4157 * <code>Calendar</code> object is specified, the driver uses the default
4158 * timezone, which is that of the virtual machine running the application.
4159 *
4160 * @param parameterName the name of the parameter
4161 * @param x the parameter value
4162 * @param cal the <code>Calendar</code> object the driver will use
4163 * to construct the timestamp
4164 * @exception SQLException if a database access error occurs or
4165 * this method is called on a closed <code>CallableStatement</code>
4166 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4167 * this method
4168 * @see #getParams
4169 * @since 1.4
4170 */
4171 public void setTimestamp(String parameterName, java.sql.Timestamp x, Calendar cal)
4172 throws SQLException{
4173 throw new SQLFeatureNotSupportedException("Feature not supported");
4174 }
4175
4176
4177 /**
4178 * Sets the designated parameter to the given <code>java.sql.SQLXML</code> object. The driver converts this to an
4179 * SQL <code>XML</code> value when it sends it to the database.
4180 * @param parameterIndex index of the first parameter is 1, the second is 2, ...
4181 * @param xmlObject a <code>SQLXML</code> object that maps an SQL <code>XML</code> value
4182 * @throws SQLException if a database access error occurs, this method
4183 * is called on a closed result set,
4184 * the <code>java.xml.transform.Result</code>,
4185 * <code>Writer</code> or <code>OutputStream</code> has not been closed
4186 * for the <code>SQLXML</code> object or
4187 * if there is an error processing the XML value. The <code>getCause</code> method
4188 * of the exception may provide a more detailed exception, for example, if the
4189 * stream does not contain valid XML.
4190 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4191 * support this method
4192 * @since 1.6
4193 */
4194 public void setSQLXML(int parameterIndex, SQLXML xmlObject) throws SQLException{
4195 throw new SQLFeatureNotSupportedException("Feature not supported");
4196 }
4197
4198
4199 /**
4200 * Sets the designated parameter to the given <code>java.sql.SQLXML</code> object. The driver converts this to an
4201 * <code>SQL XML</code> value when it sends it to the database.
4202 * @param parameterName the name of the parameter
4203 * @param xmlObject a <code>SQLXML</code> object that maps an <code>SQL XML</code> value
4204 * @throws SQLException if a database access error occurs, this method
4205 * is called on a closed result set,
4206 * the <code>java.xml.transform.Result</code>,
4207 * <code>Writer</code> or <code>OutputStream</code> has not been closed
4208 * for the <code>SQLXML</code> object or
4209 * if there is an error processing the XML value. The <code>getCause</code> method
4210 * of the exception may provide a more detailed exception, for example, if the
4211 * stream does not contain valid XML.
4212 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4213 * support this method
4214 * @since 1.6
4215 */
4216 public void setSQLXML(String parameterName, SQLXML xmlObject) throws SQLException{
4217 throw new SQLFeatureNotSupportedException("Feature not supported");
4218 }
4219
4220
4221 /**
4222 * Sets the designated parameter to the given <code>java.sql.RowId</code> object. The
4223 * driver converts this to a SQL <code>ROWID</code> value when it sends it
4224 * to the database
4225 *
4226 * @param parameterIndex the first parameter is 1, the second is 2, ...
4227 * @param x the parameter value
4228 * @throws SQLException if a database access error occurs
4229 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4230 * support this method
4231 *
4232 * @since 1.6
4233 */
4234 public void setRowId(int parameterIndex, RowId x) throws SQLException{
4235 throw new SQLFeatureNotSupportedException("Feature not supported");
4236 }
4237
4238
4239 /**
4240 * Sets the designated parameter to the given <code>java.sql.RowId</code> object. The
4241 * driver converts this to a SQL <code>ROWID</code> when it sends it to the
4242 * database.
4243 *
4244 * @param parameterName the name of the parameter
4245 * @param x the parameter value
4246 * @throws SQLException if a database access error occurs
4247 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4248 * support this method
4249 * @since 1.6
4250 */
4251 public void setRowId(String parameterName, RowId x) throws SQLException{
4252 throw new SQLFeatureNotSupportedException("Feature not supported");
4253 }
4254
4255 /**
4256 * Sets the designated parameter to the given <code>String</code> object.
4257 * The driver converts this to a SQL <code>NCHAR</code> or
4258 * <code>NVARCHAR</code> or <code>LONGNVARCHAR</code> value
4259 * (depending on the argument's
4260 * size relative to the driver's limits on <code>NVARCHAR</code> values)
4261 * when it sends it to the database.
4262 *
4263 * @param parameterIndex of the first parameter is 1, the second is 2, ...
4264 * @param value the parameter value
4265 * @throws SQLException if the driver does not support national
4266 * character sets; if the driver can detect that a data conversion
4267 * error could occur ; or if a database access error occurs
4268 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4269 * support this method
4270 * @since 1.6
4271 */
4272 public void setNString(int parameterIndex, String value) throws SQLException{
4273 throw new SQLFeatureNotSupportedException("Feature not supported");
4274 }
4275
4276
4277 /**
4278 * Sets the designated parameter to the given <code>String</code> object.
4279 * The driver converts this to a SQL <code>NCHAR</code> or
4280 * <code>NVARCHAR</code> or <code>LONGNVARCHAR</code>
4281 * @param parameterName the name of the column to be set
4282 * @param value the parameter value
4283 * @throws SQLException if the driver does not support national
4284 * character sets; if the driver can detect that a data conversion
4285 * error could occur; or if a database access error occurs
4286 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4287 * support this method
4288 * @since 1.6
4289 */
4290 public void setNString(String parameterName, String value)
4291 throws SQLException{
4292 throw new SQLFeatureNotSupportedException("Feature not supported");
4293 }
4294
4295
4296 /**
4297 * Sets the designated parameter to a <code>Reader</code> object. The
4298 * <code>Reader</code> reads the data till end-of-file is reached. The
4299 * driver does the necessary conversion from Java character format to
4300 * the national character set in the database.
4301 * @param parameterIndex of the first parameter is 1, the second is 2, ...
4302 * @param value the parameter value
4303 * @param length the number of characters in the parameter data.
4304 * @throws SQLException if the driver does not support national
4305 * character sets; if the driver can detect that a data conversion
4306 * error could occur ; or if a database access error occurs
4307 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4308 * support this method
4309 * @since 1.6
4310 */
4311 public void setNCharacterStream(int parameterIndex, Reader value, long length) throws SQLException{
4312 throw new SQLFeatureNotSupportedException("Feature not supported");
4313 }
4314
4315
4316 /**
4317 * Sets the designated parameter to a <code>Reader</code> object. The
4318 * <code>Reader</code> reads the data till end-of-file is reached. The
4319 * driver does the necessary conversion from Java character format to
4320 * the national character set in the database.
4321 * @param parameterName the name of the column to be set
4322 * @param value the parameter value
4323 * @param length the number of characters in the parameter data.
4324 * @throws SQLException if the driver does not support national
4325 * character sets; if the driver can detect that a data conversion
4326 * error could occur; or if a database access error occurs
4327 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4328 * support this method
4329 * @since 1.6
4330 */
4331 public void setNCharacterStream(String parameterName, Reader value, long length)
4332 throws SQLException{
4333 throw new SQLFeatureNotSupportedException("Feature not supported");
4334 }
4335
4336
4337 /**
4338 * Sets the designated parameter to a <code>Reader</code> object. The
4339 * <code>Reader</code> reads the data till end-of-file is reached. The
4340 * driver does the necessary conversion from Java character format to
4341 * the national character set in the database.
4342
4343 * <P><B>Note:</B> This stream object can either be a standard
4344 * Java stream object or your own subclass that implements the
4345 * standard interface.
4346 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
4347 * it might be more efficient to use a version of
4348 * <code>setNCharacterStream</code> which takes a length parameter.
4349 *
4350 * @param parameterName the name of the parameter
4351 * @param value the parameter value
4352 * @throws SQLException if the driver does not support national
4353 * character sets; if the driver can detect that a data conversion
4354 * error could occur ; if a database access error occurs; or
4355 * this method is called on a closed <code>CallableStatement</code>
4356 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
4357 * @since 1.6
4358 */
4359 public void setNCharacterStream(String parameterName, Reader value) throws SQLException{
4360 throw new SQLFeatureNotSupportedException("Feature not supported");
4361 }
4362
4363
4364 /**
4365 * Sets the designated parameter to a <code>java.sql.NClob</code> object. The object
4366 * implements the <code>java.sql.NClob</code> interface. This <code>NClob</code>
4367 * object maps to a SQL <code>NCLOB</code>.
4368 * @param parameterName the name of the column to be set
4369 * @param value the parameter value
4370 * @throws SQLException if the driver does not support national
4371 * character sets; if the driver can detect that a data conversion
4372 * error could occur; or if a database access error occurs
4373 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4374 * support this method
4375 * @since 1.6
4376 */
4377 public void setNClob(String parameterName, NClob value) throws SQLException{
4378 throw new SQLFeatureNotSupportedException("Feature not supported");
4379 }
4380
4381
4382 /**
4383 * Sets the designated parameter to a <code>Reader</code> object. The <code>reader</code> must contain
4384 * the number
4385 * of characters specified by length otherwise a <code>SQLException</code> will be
4386 * generated when the <code>CallableStatement</code> is executed.
4387 * This method differs from the <code>setCharacterStream (int, Reader, int)</code> method
4388 * because it informs the driver that the parameter value should be sent to
4389 * the server as a <code>NCLOB</code>. When the <code>setCharacterStream</code> method is used, the
4390 * driver may have to do extra work to determine whether the parameter
4391 * data should be send to the server as a <code>LONGNVARCHAR</code> or a <code>NCLOB</code>
4392 *
4393 * @param parameterName the name of the parameter to be set
4394 * @param reader An object that contains the data to set the parameter value to.
4395 * @param length the number of characters in the parameter data.
4396 * @throws SQLException if parameterIndex does not correspond to a parameter
4397 * marker in the SQL statement; if the length specified is less than zero;
4398 * if the driver does not support national
4399 * character sets; if the driver can detect that a data conversion
4400 * error could occur; if a database access error occurs or
4401 * this method is called on a closed <code>CallableStatement</code>
4402 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4403 * this method
4404 * @since 1.6
4405 */
4406 public void setNClob(String parameterName, Reader reader, long length)
4407 throws SQLException{
4408 throw new SQLFeatureNotSupportedException("Feature not supported");
4409 }
4410
4411
4412 /**
4413 * Sets the designated parameter to a <code>Reader</code> object.
4414 * This method differs from the <code>setCharacterStream (int, Reader)</code> method
4415 * because it informs the driver that the parameter value should be sent to
4416 * the server as a <code>NCLOB</code>. When the <code>setCharacterStream</code> method is used, the
4417 * driver may have to do extra work to determine whether the parameter
4418 * data should be send to the server as a <code>LONGNVARCHAR</code> or a <code>NCLOB</code>
4419 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
4420 * it might be more efficient to use a version of
4421 * <code>setNClob</code> which takes a length parameter.
4422 *
4423 * @param parameterName the name of the parameter
4424 * @param reader An object that contains the data to set the parameter value to.
4425 * @throws SQLException if the driver does not support national character sets;
4426 * if the driver can detect that a data conversion
4427 * error could occur; if a database access error occurs or
4428 * this method is called on a closed <code>CallableStatement</code>
4429 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
4430 *
4431 * @since 1.6
4432 */
4433 public void setNClob(String parameterName, Reader reader)
4434 throws SQLException{
4435 throw new SQLFeatureNotSupportedException("Feature not supported");
4436 }
4437
4438
4439 /**
4440 * Sets the designated parameter to a <code>Reader</code> object. The reader must contain the number
4441 * of characters specified by length otherwise a <code>SQLException</code> will be
4442 * generated when the <code>PreparedStatement</code> is executed.
4443 * This method differs from the <code>setCharacterStream (int, Reader, int)</code> method
4444 * because it informs the driver that the parameter value should be sent to
4445 * the server as a <code>NCLOB</code>. When the <code>setCharacterStream</code> method is used, the
4446 * driver may have to do extra work to determine whether the parameter
4447 * data should be sent to the server as a <code>LONGNVARCHAR</code> or a <code>NCLOB</code>
4448 * @param parameterIndex index of the first parameter is 1, the second is 2, ...
4449 * @param reader An object that contains the data to set the parameter value to.
4450 * @param length the number of characters in the parameter data.
4451 * @throws SQLException if parameterIndex does not correspond to a parameter
4452 * marker in the SQL statement; if the length specified is less than zero;
4453 * if the driver does not support national character sets;
4454 * if the driver can detect that a data conversion
4455 * error could occur; if a database access error occurs or
4456 * this method is called on a closed <code>PreparedStatement</code>
4457 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4458 * support this method
4459 *
4460 * @since 1.6
4461 */
4462 public void setNClob(int parameterIndex, Reader reader, long length)
4463 throws SQLException{
4464 throw new SQLFeatureNotSupportedException("Feature not supported");
4465 }
4466
4467
4468 /**
4469 * Sets the designated parameter to a <code>java.sql.NClob</code> object. The driver converts this oa
4470 * SQL <code>NCLOB</code> value when it sends it to the database.
4471 * @param parameterIndex of the first parameter is 1, the second is 2, ...
4472 * @param value the parameter value
4473 * @throws SQLException if the driver does not support national
4474 * character sets; if the driver can detect that a data conversion
4475 * error could occur ; or if a database access error occurs
4476 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4477 * support this method
4478 * @since 1.6
4479 */
4480 public void setNClob(int parameterIndex, NClob value) throws SQLException{
4481 throw new SQLFeatureNotSupportedException("Feature not supported");
4482 }
4483
4484
4485 /**
4486 * Sets the designated parameter to a <code>Reader</code> object.
4487 * This method differs from the <code>setCharacterStream (int, Reader)</code> method
4488 * because it informs the driver that the parameter value should be sent to
4489 * the server as a <code>NCLOB</code>. When the <code>setCharacterStream</code> method is used, the
4490 * driver may have to do extra work to determine whether the parameter
4491 * data should be sent to the server as a <code>LONGNVARCHAR</code> or a <code>NCLOB</code>
4492 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
4493 * it might be more efficient to use a version of
4494 * <code>setNClob</code> which takes a length parameter.
4495 *
4496 * @param parameterIndex index of the first parameter is 1, the second is 2, ...
4497 * @param reader An object that contains the data to set the parameter value to.
4498 * @throws SQLException if parameterIndex does not correspond to a parameter
4499 * marker in the SQL statement;
4500 * if the driver does not support national character sets;
4501 * if the driver can detect that a data conversion
4502 * error could occur; if a database access error occurs or
4503 * this method is called on a closed <code>PreparedStatement</code>
4504 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
4505 *
4506 * @since 1.6
4507 */
4508 public void setNClob(int parameterIndex, Reader reader)
4509 throws SQLException{
4510 throw new SQLFeatureNotSupportedException("Feature not supported");
4511 }
4512
4513
4514 /**
4515 * Sets the designated parameter to the given <code>java.net.URL</code> value.
4516 * The driver converts this to an SQL <code>DATALINK</code> value
4517 * when it sends it to the database.
4518 *
4519 * @param parameterIndex the first parameter is 1, the second is 2, ...
4520 * @param x the <code>java.net.URL</code> object to be set
4521 * @exception SQLException if a database access error occurs or
4522 * this method is called on a closed <code>PreparedStatement</code>
4523 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
4524 * @since 1.4
4525 */
4526 public void setURL(int parameterIndex, java.net.URL x) throws SQLException{
4527 throw new SQLFeatureNotSupportedException("Feature not supported");
4528 }
4529
4530
4531
4532 static final long serialVersionUID = 4886719666485113312L;
4533
4534 } //end class
|
351 /**
352 * The <code>Reader</code> object that will be
353 * returned by the method <code>getCharacterStream</code>,
354 * which is specified in the <code>ResultSet</code> interface.
355 * @serial
356 */
357 protected java.io.Reader charStream;
358
359 /**
360 * The query that will be sent to the DBMS for execution when the
361 * method <code>execute</code> is called.
362 * @serial
363 */
364 private String command;
365
366 /**
367 * The JDBC URL the reader, writer, or both supply to the method
368 * <code>DriverManager.getConnection</code> when the
369 * <code>DriverManager</code> is used to get a connection.
370 * <P>
371 * The JDBC URL identifies the driver to be used to make the connection.
372 * This URL can be found in the documentation supplied by the driver
373 * vendor.
374 * @serial
375 */
376 private String URL;
377
378 /**
379 * The logical name of the data source that the reader/writer should use
380 * in order to retrieve a <code>DataSource</code> object from a Java
381 * Directory and Naming Interface (JNDI) naming service.
382 * @serial
383 */
384 private String dataSource;
385
386 /**
387 * The user name the reader, writer, or both supply to the method
388 * <code>DriverManager.getConnection</code> when the
389 * <code>DriverManager</code> is used to get a connection.
390 * @serial
391 */
545 protected void initParams() {
546 params = new Hashtable<Integer, Object>();
547 }
548
549 //--------------------------------------------------------------------
550 // Events
551 //--------------------------------------------------------------------
552
553 /**
554 * The listener will be notified whenever an event occurs on this <code>RowSet</code>
555 * object.
556 * <P>
557 * A listener might, for example, be a table or graph that needs to
558 * be updated in order to accurately reflect the current state of
559 * the <code>RowSet</code> object.
560 * <p>
561 * <b>Note</b>: if the <code>RowSetListener</code> object is
562 * <code>null</code>, this method silently discards the <code>null</code>
563 * value and does not add a null reference to the set of listeners.
564 * <p>
565 * <b>Note</b>: if the listener is already set, and the new <code>RowSetListener</code>
566 * instance is added to the set of listeners already registered to receive
567 * event notifications from this <code>RowSet</code>.
568 *
569 * @param listener an object that has implemented the
570 * <code>javax.sql.RowSetListener</code> interface and wants to be notified
571 * of any events that occur on this <code>RowSet</code> object; May be
572 * null.
573 * @see #removeRowSetListener
574 */
575 public void addRowSetListener(RowSetListener listener) {
576 listeners.add(listener);
577 }
578
579 /**
580 * Removes the designated object from this <code>RowSet</code> object's list of listeners.
581 * If the given argument is not a registered listener, this method
582 * does nothing.
583 *
584 * <b>Note</b>: if the <code>RowSetListener</code> object is
585 * <code>null</code>, this method silently discards the <code>null</code>
750 * data source.
751 *
752 * @return a <code>String</code> object that contains the JDBC URL
753 * used to establish the connection for this <code>RowSet</code>
754 * object; may be <code>null</code> (default value) if not set
755 * @throws SQLException if an error occurs retrieving the URL value
756 * @see #setUrl
757 */
758 public String getUrl() throws SQLException {
759 return URL;
760 }
761
762 /**
763 * Sets the Url property for this <code>RowSet</code> object
764 * to the given <code>String</code> object and sets the dataSource name
765 * property to <code>null</code>. The Url property is a
766 * JDBC URL that is used when
767 * the connection is created using a JDBC technology-enabled driver
768 * ("JDBC driver") and the <code>DriverManager</code>.
769 * The correct JDBC URL for the specific driver to be used can be found
770 * in the driver documentation. Although there are guidelines for how
771 * a JDBC URL is formed,
772 * a driver vendor can specify any <code>String</code> object except
773 * one with a length of <code>0</code> (an empty string).
774 * <P>
775 * Setting the Url property is optional if connections are established using
776 * a <code>DataSource</code> object instead of the <code>DriverManager</code>.
777 * The driver will use either the URL property or the
778 * dataSourceName property to create a connection, whichever was
779 * specified most recently. If an application uses a JDBC URL, it
780 * must load a JDBC driver that accepts the JDBC URL before it uses the
781 * <code>RowSet</code> object to connect to a database. The <code>RowSet</code>
782 * object will use the URL internally to create a database connection in order
783 * to read or write data.
784 *
785 * @param url a <code>String</code> object that contains the JDBC URL
786 * that will be used to establish the connection to a database for this
787 * <code>RowSet</code> object; may be <code>null</code> but must not
788 * be an empty string
789 * @throws SQLException if an error occurs setting the Url property or the
790 * parameter supplied is a string with a length of <code>0</code> (an
1076 * <code>Connection.TRANSACTION_REPEATABLE_READ</code>, or
1077 * <code>Connection.TRANSACTION_SERIALIZABLE</code>
1078 * @throws SQLException if the given parameter is not one of the Connection
1079 * constants
1080 * @see javax.sql.rowset.spi.SyncFactory
1081 * @see javax.sql.rowset.spi.SyncProvider
1082 * @see #getTransactionIsolation
1083 */
1084 public void setTransactionIsolation(int level) throws SQLException {
1085 if ((level != Connection.TRANSACTION_NONE) &&
1086 (level != Connection.TRANSACTION_READ_COMMITTED) &&
1087 (level != Connection.TRANSACTION_READ_UNCOMMITTED) &&
1088 (level != Connection.TRANSACTION_REPEATABLE_READ) &&
1089 (level != Connection.TRANSACTION_SERIALIZABLE))
1090 {
1091 throw new SQLException("Invalid transaction isolation set. Must " +
1092 "be either " +
1093 "Connection.TRANSACTION_NONE or " +
1094 "Connection.TRANSACTION_READ_UNCOMMITTED or " +
1095 "Connection.TRANSACTION_READ_COMMITTED or " +
1096 "Connection.TRANSACTION_REPEATABLE_READ or " +
1097 "Connection.TRANSACTION_SERIALIZABLE");
1098 }
1099 this.isolation = level;
1100 }
1101
1102 /**
1103 * Retrieves the type map associated with the <code>Connection</code>
1104 * object for this <code>RowSet</code> object.
1105 * <P>
1106 * Drivers that support the JDBC 3.0 API will create
1107 * <code>Connection</code> objects with an associated type map.
1108 * This type map, which is initially empty, can contain one or more
1109 * fully-qualified SQL names and <code>Class</code> objects indicating
1110 * the class to which the named SQL value will be mapped. The type mapping
1111 * specified in the connection's type map is used for custom type mapping
1112 * when no other type map supersedes it.
1113 * <p>
1114 * If a type map is explicitly supplied to a method that can perform
1115 * custom mapping, that type map supersedes the connection's type map.
1116 *
3193 } //end getParams
3194
3195
3196 /**
3197 * Sets the designated parameter to SQL <code>NULL</code>.
3198 *
3199 * <P><B>Note:</B> You must specify the parameter's SQL type.
3200 *
3201 * @param parameterName the name of the parameter
3202 * @param sqlType the SQL type code defined in <code>java.sql.Types</code>
3203 * @exception SQLException if a database access error occurs or
3204 * this method is called on a closed <code>CallableStatement</code>
3205 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3206 * this method
3207 * @since 1.4
3208 */
3209 public void setNull(String parameterName, int sqlType) throws SQLException {
3210 throw new SQLFeatureNotSupportedException("Feature not supported");
3211 }
3212
3213 /**
3214 * Sets the designated parameter to SQL <code>NULL</code>.
3215 * This version of the method <code>setNull</code> should
3216 * be used for user-defined types and REF type parameters. Examples
3217 * of user-defined types include: STRUCT, DISTINCT, JAVA_OBJECT, and
3218 * named array types.
3219 *
3220 * <P><B>Note:</B> To be portable, applications must give the
3221 * SQL type code and the fully-qualified SQL type name when specifying
3222 * a NULL user-defined or REF parameter. In the case of a user-defined type
3223 * the name is the type name of the parameter itself. For a REF
3224 * parameter, the name is the type name of the referenced type. If
3225 * a JDBC driver does not need the type code or type name information,
3226 * it may ignore it.
3227 *
3228 * Although it is intended for user-defined and Ref parameters,
3229 * this method may be used to set a null parameter of any JDBC type.
3230 * If the parameter does not have a user-defined or REF type, the given
3231 * typeName is ignored.
3232 *
3233 *
3234 * @param parameterName the name of the parameter
3235 * @param sqlType a value from <code>java.sql.Types</code>
3236 * @param typeName the fully-qualified name of an SQL user-defined type;
3237 * ignored if the parameter is not a user-defined type or
3238 * SQL <code>REF</code> value
3239 * @exception SQLException if a database access error occurs or
3240 * this method is called on a closed <code>CallableStatement</code>
3241 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3242 * this method
3243 * @since 1.4
3244 */
3245 public void setNull (String parameterName, int sqlType, String typeName)
3246 throws SQLException{
3247 throw new SQLFeatureNotSupportedException("Feature not supported");
3248 }
3249
3250 /**
3251 * Sets the designated parameter to the given Java <code>boolean</code> value.
3252 * The driver converts this
3253 * to an SQL <code>BIT</code> or <code>BOOLEAN</code> value when it sends it to the database.
3254 *
3255 * @param parameterName the name of the parameter
3256 * @param x the parameter value
3257 * @exception SQLException if a database access error occurs or
3258 * this method is called on a closed <code>CallableStatement</code>
3259 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3260 * this method
3261 * @see #getParams
3262 * @since 1.4
3263 */
3264 public void setBoolean(String parameterName, boolean x) throws SQLException{
3265 throw new SQLFeatureNotSupportedException("Feature not supported");
3266 }
3267
3268 /**
3269 * Sets the designated parameter to the given Java <code>byte</code> value.
3270 * The driver converts this
3271 * to an SQL <code>TINYINT</code> value when it sends it to the database.
3272 *
3273 * @param parameterName the name of the parameter
3274 * @param x the parameter value
3275 * @exception SQLException if a database access error occurs or
3276 * this method is called on a closed <code>CallableStatement</code>
3277 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3278 * this method
3279 * @see #getParams
3280 * @since 1.4
3281 */
3282 public void setByte(String parameterName, byte x) throws SQLException{
3283 throw new SQLFeatureNotSupportedException("Feature not supported");
3284 }
3285
3286 /**
3287 * Sets the designated parameter to the given Java <code>short</code> value.
3288 * The driver converts this
3289 * to an SQL <code>SMALLINT</code> value when it sends it to the database.
3290 *
3291 * @param parameterName the name of the parameter
3292 * @param x the parameter value
3293 * @exception SQLException if a database access error occurs or
3294 * this method is called on a closed <code>CallableStatement</code>
3295 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3296 * this method
3297 * @see #getParams
3298 * @since 1.4
3299 */
3300 public void setShort(String parameterName, short x) throws SQLException{
3301 throw new SQLFeatureNotSupportedException("Feature not supported");
3302 }
3303
3304 /**
3305 * Sets the designated parameter to the given Java <code>int</code> value.
3306 * The driver converts this
3307 * to an SQL <code>INTEGER</code> value when it sends it to the database.
3308 *
3309 * @param parameterName the name of the parameter
3310 * @param x the parameter value
3311 * @exception SQLException if a database access error occurs or
3312 * this method is called on a closed <code>CallableStatement</code>
3313 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3314 * this method
3315 * @see #getParams
3316 * @since 1.4
3317 */
3318 public void setInt(String parameterName, int x) throws SQLException{
3319 throw new SQLFeatureNotSupportedException("Feature not supported");
3320 }
3321
3322
3323 /**
3324 * Sets the designated parameter to the given Java <code>long</code> value.
3325 * The driver converts this
3326 * to an SQL <code>BIGINT</code> value when it sends it to the database.
3327 *
3328 * @param parameterName the name of the parameter
3329 * @param x the parameter value
3330 * @exception SQLException if a database access error occurs or
3331 * this method is called on a closed <code>CallableStatement</code>
3332 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3333 * this method
3334 * @see #getParams
3335 * @since 1.4
3336 */
3337 public void setLong(String parameterName, long x) throws SQLException{
3338 throw new SQLFeatureNotSupportedException("Feature not supported");
3339 }
3340
3341 /**
3342 * Sets the designated parameter to the given Java <code>float</code> value.
3343 * The driver converts this
3344 * to an SQL <code>FLOAT</code> value when it sends it to the database.
3345 *
3346 * @param parameterName the name of the parameter
3347 * @param x the parameter value
3348 * @exception SQLException if a database access error occurs or
3349 * this method is called on a closed <code>CallableStatement</code>
3350 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3351 * this method
3352 * @see #getParams
3353 * @since 1.4
3354 */
3355 public void setFloat(String parameterName, float x) throws SQLException{
3356 throw new SQLFeatureNotSupportedException("Feature not supported");
3357 }
3358
3359 /**
3360 * Sets the designated parameter to the given Java <code>double</code> value.
3361 * The driver converts this
3362 * to an SQL <code>DOUBLE</code> value when it sends it to the database.
3363 *
3364 * @param parameterName the name of the parameter
3365 * @param x the parameter value
3366 * @exception SQLException if a database access error occurs or
3367 * this method is called on a closed <code>CallableStatement</code>
3368 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3369 * this method
3370 * @see #getParams
3371 * @since 1.4
3372 */
3373 public void setDouble(String parameterName, double x) throws SQLException{
3374 throw new SQLFeatureNotSupportedException("Feature not supported");
3375 }
3376
3377 /**
3378 * Sets the designated parameter to the given
3379 * <code>java.math.BigDecimal</code> value.
3380 * The driver converts this to an SQL <code>NUMERIC</code> value when
3381 * it sends it to the database.
3382 *
3383 * @param parameterName the name of the parameter
3384 * @param x the parameter value
3385 * @exception SQLException if a database access error occurs or
3386 * this method is called on a closed <code>CallableStatement</code>
3387 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3388 * this method
3389 * @see #getParams
3390 * @since 1.4
3391 */
3392 public void setBigDecimal(String parameterName, BigDecimal x) throws SQLException{
3393 throw new SQLFeatureNotSupportedException("Feature not supported");
3394 }
3395
3396 /**
3397 * Sets the designated parameter to the given Java <code>String</code> value.
3398 * The driver converts this
3399 * to an SQL <code>VARCHAR</code> or <code>LONGVARCHAR</code> value
3400 * (depending on the argument's
3401 * size relative to the driver's limits on <code>VARCHAR</code> values)
3402 * when it sends it to the database.
3403 *
3404 * @param parameterName the name of the parameter
3405 * @param x the parameter value
3406 * @exception SQLException if a database access error occurs or
3407 * this method is called on a closed <code>CallableStatement</code>
3408 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3409 * this method
3410 * @see #getParams
3411 * @since 1.4
3412 */
3413 public void setString(String parameterName, String x) throws SQLException{
3414 throw new SQLFeatureNotSupportedException("Feature not supported");
3415 }
3416
3417 /**
3418 * Sets the designated parameter to the given Java array of bytes.
3419 * The driver converts this to an SQL <code>VARBINARY</code> or
3420 * <code>LONGVARBINARY</code> (depending on the argument's size relative
3421 * to the driver's limits on <code>VARBINARY</code> values) when it sends
3422 * it to the database.
3423 *
3424 * @param parameterName the name of the parameter
3425 * @param x the parameter value
3426 * @exception SQLException if a database access error occurs or
3427 * this method is called on a closed <code>CallableStatement</code>
3428 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3429 * this method
3430 * @see #getParams
3431 * @since 1.4
3432 */
3433 public void setBytes(String parameterName, byte x[]) throws SQLException{
3434 throw new SQLFeatureNotSupportedException("Feature not supported");
3435 }
3436
3437 /**
3438 * Sets the designated parameter to the given <code>java.sql.Timestamp</code> value.
3439 * The driver
3440 * converts this to an SQL <code>TIMESTAMP</code> value when it sends it to the
3441 * database.
3442 *
3443 * @param parameterName the name of the parameter
3444 * @param x the parameter value
3445 * @exception SQLException if a database access error occurs or
3446 * this method is called on a closed <code>CallableStatement</code>
3447 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3448 * this method
3449 * @see #getParams
3450 * @since 1.4
3451 */
3452 public void setTimestamp(String parameterName, java.sql.Timestamp x)
3453 throws SQLException{
3454 throw new SQLFeatureNotSupportedException("Feature not supported");
3455 }
3456
3457 /**
3458 * Sets the designated parameter to the given input stream, which will have
3459 * the specified number of bytes.
3460 * When a very large ASCII value is input to a <code>LONGVARCHAR</code>
3461 * parameter, it may be more practical to send it via a
3462 * <code>java.io.InputStream</code>. Data will be read from the stream
3463 * as needed until end-of-file is reached. The JDBC driver will
3464 * do any necessary conversion from ASCII to the database char format.
3465 *
3466 * <P><B>Note:</B> This stream object can either be a standard
3467 * Java stream object or your own subclass that implements the
3468 * standard interface.
3469 *
3470 * @param parameterName the name of the parameter
3471 * @param x the Java input stream that contains the ASCII parameter value
3472 * @param length the number of bytes in the stream
3473 * @exception SQLException if a database access error occurs or
3474 * this method is called on a closed <code>CallableStatement</code>
3475 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3476 * this method
3477 * @since 1.4
3478 */
3479 public void setAsciiStream(String parameterName, java.io.InputStream x, int length)
3480 throws SQLException{
3481 throw new SQLFeatureNotSupportedException("Feature not supported");
3482 }
3483
3484 /**
3485 * Sets the designated parameter to the given input stream, which will have
3486 * the specified number of bytes.
3487 * When a very large binary value is input to a <code>LONGVARBINARY</code>
3488 * parameter, it may be more practical to send it via a
3489 * <code>java.io.InputStream</code> object. The data will be read from the stream
3490 * as needed until end-of-file is reached.
3491 *
3492 * <P><B>Note:</B> This stream object can either be a standard
3493 * Java stream object or your own subclass that implements the
3494 * standard interface.
3495 *
3496 * @param parameterName the name of the parameter
3497 * @param x the java input stream which contains the binary parameter value
3498 * @param length the number of bytes in the stream
3499 * @exception SQLException if a database access error occurs or
3500 * this method is called on a closed <code>CallableStatement</code>
3501 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3502 * this method
3503 * @since 1.4
3504 */
3505 public void setBinaryStream(String parameterName, java.io.InputStream x,
3506 int length) throws SQLException{
3507 throw new SQLFeatureNotSupportedException("Feature not supported");
3508 }
3509
3510 /**
3511 * Sets the designated parameter to the given <code>Reader</code>
3512 * object, which is the given number of characters long.
3513 * When a very large UNICODE value is input to a <code>LONGVARCHAR</code>
3514 * parameter, it may be more practical to send it via a
3515 * <code>java.io.Reader</code> object. The data will be read from the stream
3516 * as needed until end-of-file is reached. The JDBC driver will
3517 * do any necessary conversion from UNICODE to the database char format.
3518 *
3519 * <P><B>Note:</B> This stream object can either be a standard
3520 * Java stream object or your own subclass that implements the
3521 * standard interface.
3522 *
3523 * @param parameterName the name of the parameter
3524 * @param reader the <code>java.io.Reader</code> object that
3525 * contains the UNICODE data used as the designated parameter
3526 * @param length the number of characters in the stream
3527 * @exception SQLException if a database access error occurs or
3528 * this method is called on a closed <code>CallableStatement</code>
3529 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3530 * this method
3531 * @since 1.4
3532 */
3533 public void setCharacterStream(String parameterName,
3534 java.io.Reader reader,
3535 int length) throws SQLException{
3536 throw new SQLFeatureNotSupportedException("Feature not supported");
3537 }
3538
3539 /**
3540 * Sets the designated parameter to the given input stream.
3541 * When a very large ASCII value is input to a <code>LONGVARCHAR</code>
3542 * parameter, it may be more practical to send it via a
3543 * <code>java.io.InputStream</code>. Data will be read from the stream
3544 * as needed until end-of-file is reached. The JDBC driver will
3545 * do any necessary conversion from ASCII to the database char format.
3546 *
3547 * <P><B>Note:</B> This stream object can either be a standard
3548 * Java stream object or your own subclass that implements the
3549 * standard interface.
3550 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3551 * it might be more efficient to use a version of
3552 * <code>setAsciiStream</code> which takes a length parameter.
3553 *
3554 * @param parameterName the name of the parameter
3555 * @param x the Java input stream that contains the ASCII parameter value
3556 * @exception SQLException if a database access error occurs or
3557 * this method is called on a closed <code>CallableStatement</code>
3558 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3559 * @since 1.6
3560 */
3561 public void setAsciiStream(String parameterName, java.io.InputStream x)
3562 throws SQLException{
3563 throw new SQLFeatureNotSupportedException("Feature not supported");
3564 }
3565
3566 /**
3567 * Sets the designated parameter to the given input stream.
3568 * When a very large binary value is input to a <code>LONGVARBINARY</code>
3569 * parameter, it may be more practical to send it via a
3570 * <code>java.io.InputStream</code> object. The data will be read from the
3571 * stream as needed until end-of-file is reached.
3572 *
3573 * <P><B>Note:</B> This stream object can either be a standard
3574 * Java stream object or your own subclass that implements the
3575 * standard interface.
3576 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3577 * it might be more efficient to use a version of
3578 * <code>setBinaryStream</code> which takes a length parameter.
3579 *
3580 * @param parameterName the name of the parameter
3581 * @param x the java input stream which contains the binary parameter value
3582 * @exception SQLException if a database access error occurs or
3583 * this method is called on a closed <code>CallableStatement</code>
3584 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3585 * @since 1.6
3586 */
3587 public void setBinaryStream(String parameterName, java.io.InputStream x)
3588 throws SQLException{
3589 throw new SQLFeatureNotSupportedException("Feature not supported");
3590 }
3591
3592 /**
3593 * Sets the designated parameter to the given <code>Reader</code>
3594 * object.
3595 * When a very large UNICODE value is input to a <code>LONGVARCHAR</code>
3596 * parameter, it may be more practical to send it via a
3597 * <code>java.io.Reader</code> object. The data will be read from the stream
3598 * as needed until end-of-file is reached. The JDBC driver will
3599 * do any necessary conversion from UNICODE to the database char format.
3600 *
3601 * <P><B>Note:</B> This stream object can either be a standard
3602 * Java stream object or your own subclass that implements the
3603 * standard interface.
3604 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3605 * it might be more efficient to use a version of
3606 * <code>setCharacterStream</code> which takes a length parameter.
3607 *
3608 * @param parameterName the name of the parameter
3609 * @param reader the <code>java.io.Reader</code> object that contains the
3610 * Unicode data
3611 * @exception SQLException if a database access error occurs or
3612 * this method is called on a closed <code>CallableStatement</code>
3613 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3614 * @since 1.6
3615 */
3616 public void setCharacterStream(String parameterName,
3617 java.io.Reader reader) throws SQLException{
3618 throw new SQLFeatureNotSupportedException("Feature not supported");
3619 }
3620
3621 /**
3622 * Sets the designated parameter in this <code>RowSet</code> object's command
3623 * to a <code>Reader</code> object. The
3624 * <code>Reader</code> reads the data till end-of-file is reached. The
3625 * driver does the necessary conversion from Java character format to
3626 * the national character set in the database.
3627 *
3628 * <P><B>Note:</B> This stream object can either be a standard
3629 * Java stream object or your own subclass that implements the
3630 * standard interface.
3631 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3632 * it might be more efficient to use a version of
3633 * <code>setNCharacterStream</code> which takes a length parameter.
3634 *
3635 * @param parameterIndex of the first parameter is 1, the second is 2, ...
3636 * @param value the parameter value
3637 * @throws SQLException if the driver does not support national
3638 * character sets; if the driver can detect that a data conversion
3639 * error could occur ; if a database access error occurs; or
3640 * this method is called on a closed <code>PreparedStatement</code>
3641 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3642 * @since 1.6
3643 */
3644 public void setNCharacterStream(int parameterIndex, Reader value) throws SQLException{
3645 throw new SQLFeatureNotSupportedException("Feature not supported");
3646 }
3647
3648 /**
3649 * Sets the value of the designated parameter with the given object. The second
3650 * argument must be an object type; for integral values, the
3651 * <code>java.lang</code> equivalent objects should be used.
3652 *
3653 * <p>The given Java object will be converted to the given targetSqlType
3654 * before being sent to the database.
3655 *
3656 * If the object has a custom mapping (is of a class implementing the
3657 * interface <code>SQLData</code>),
3658 * the JDBC driver should call the method <code>SQLData.writeSQL</code> to write it
3659 * to the SQL data stream.
3660 * If, on the other hand, the object is of a class implementing
3661 * <code>Ref</code>, <code>Blob</code>, <code>Clob</code>, <code>NClob</code>,
3662 * <code>Struct</code>, <code>java.net.URL</code>,
3663 * or <code>Array</code>, the driver should pass it to the database as a
3664 * value of the corresponding SQL type.
3665 * <P>
3666 * Note that this method may be used to pass database-
3667 * specific abstract data types.
3668 *
3669 * @param parameterName the name of the parameter
3670 * @param x the object containing the input parameter value
3671 * @param targetSqlType the SQL type (as defined in java.sql.Types) to be
3672 * sent to the database. The scale argument may further qualify this type.
3673 * @param scale for java.sql.Types.DECIMAL or java.sql.Types.NUMERIC types,
3674 * this is the number of digits after the decimal point. For all other
3675 * types, this value will be ignored.
3676 * @exception SQLException if a database access error occurs or
3677 * this method is called on a closed <code>CallableStatement</code>
3678 * @exception SQLFeatureNotSupportedException if <code>targetSqlType</code> is
3679 * a <code>ARRAY</code>, <code>BLOB</code>, <code>CLOB</code>,
3680 * <code>DATALINK</code>, <code>JAVA_OBJECT</code>, <code>NCHAR</code>,
3681 * <code>NCLOB</code>, <code>NVARCHAR</code>, <code>LONGNVARCHAR</code>,
3682 * <code>REF</code>, <code>ROWID</code>, <code>SQLXML</code>
3683 * or <code>STRUCT</code> data type and the JDBC driver does not support
3684 * this data type
3685 * @see Types
3686 * @see #getParams
3687 * @since 1.4
3688 */
3689 public void setObject(String parameterName, Object x, int targetSqlType, int scale)
3690 throws SQLException{
3691 throw new SQLFeatureNotSupportedException("Feature not supported");
3692 }
3693
3694 /**
3695 * Sets the value of the designated parameter with the given object.
3696 * This method is like the method <code>setObject</code>
3697 * above, except that it assumes a scale of zero.
3698 *
3699 * @param parameterName the name of the parameter
3700 * @param x the object containing the input parameter value
3701 * @param targetSqlType the SQL type (as defined in java.sql.Types) to be
3702 * sent to the database
3703 * @exception SQLException if a database access error occurs or
3704 * this method is called on a closed <code>CallableStatement</code>
3705 * @exception SQLFeatureNotSupportedException if <code>targetSqlType</code> is
3706 * a <code>ARRAY</code>, <code>BLOB</code>, <code>CLOB</code>,
3707 * <code>DATALINK</code>, <code>JAVA_OBJECT</code>, <code>NCHAR</code>,
3708 * <code>NCLOB</code>, <code>NVARCHAR</code>, <code>LONGNVARCHAR</code>,
3709 * <code>REF</code>, <code>ROWID</code>, <code>SQLXML</code>
3710 * or <code>STRUCT</code> data type and the JDBC driver does not support
3711 * this data type
3712 * @see #getParams
3713 * @since 1.4
3714 */
3715 public void setObject(String parameterName, Object x, int targetSqlType)
3716 throws SQLException{
3717 throw new SQLFeatureNotSupportedException("Feature not supported");
3718 }
3719
3720 /**
3721 * Sets the value of the designated parameter with the given object.
3722 * The second parameter must be of type <code>Object</code>; therefore, the
3723 * <code>java.lang</code> equivalent objects should be used for built-in types.
3724 *
3725 * <p>The JDBC specification specifies a standard mapping from
3726 * Java <code>Object</code> types to SQL types. The given argument
3727 * will be converted to the corresponding SQL type before being
3728 * sent to the database.
3729 *
3730 * <p>Note that this method may be used to pass database-
3731 * specific abstract data types, by using a driver-specific Java
3732 * type.
3733 *
3734 * If the object is of a class implementing the interface <code>SQLData</code>,
3735 * the JDBC driver should call the method <code>SQLData.writeSQL</code>
3736 * to write it to the SQL data stream.
3737 * If, on the other hand, the object is of a class implementing
3738 * <code>Ref</code>, <code>Blob</code>, <code>Clob</code>, <code>NClob</code>,
3739 * <code>Struct</code>, <code>java.net.URL</code>,
3740 * or <code>Array</code>, the driver should pass it to the database as a
3741 * value of the corresponding SQL type.
3742 * <P>
3743 * This method throws an exception if there is an ambiguity, for example, if the
3744 * object is of a class implementing more than one of the interfaces named above.
3745 *
3746 * @param parameterName the name of the parameter
3747 * @param x the object containing the input parameter value
3748 * @exception SQLException if a database access error occurs,
3749 * this method is called on a closed <code>CallableStatement</code> or if the given
3750 * <code>Object</code> parameter is ambiguous
3751 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3752 * this method
3753 * @see #getParams
3754 * @since 1.4
3755 */
3756 public void setObject(String parameterName, Object x) throws SQLException{
3757 throw new SQLFeatureNotSupportedException("Feature not supported");
3758 }
3759
3760 /**
3761 * Sets the designated parameter to a <code>InputStream</code> object.
3762 * The <code>InputStream</code> must contain the number
3763 * of characters specified by length otherwise a <code>SQLException</code> will be
3764 * generated when the <code>PreparedStatement</code> is executed.
3765 * This method differs from the <code>setBinaryStream (int, InputStream, int)</code>
3766 * method because it informs the driver that the parameter value should be
3767 * sent to the server as a <code>BLOB</code>. When the <code>setBinaryStream</code> method is used,
3768 * the driver may have to do extra work to determine whether the parameter
3769 * data should be sent to the server as a <code>LONGVARBINARY</code> or a <code>BLOB</code>
3770 * @param parameterIndex index of the first parameter is 1,
3771 * the second is 2, ...
3772 * @param inputStream An object that contains the data to set the parameter
3773 * value to.
3774 * @param length the number of bytes in the parameter data.
3775 * @throws SQLException if a database access error occurs,
3776 * this method is called on a closed <code>PreparedStatement</code>,
3777 * if parameterIndex does not correspond
3778 * to a parameter marker in the SQL statement, if the length specified
3779 * is less than zero or if the number of bytes in the
3780 * <code>InputStream</code> does not match the specified length.
3781 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3782 *
3783 * @since 1.6
3784 */
3785 public void setBlob(int parameterIndex, InputStream inputStream, long length)
3786 throws SQLException{
3787 throw new SQLFeatureNotSupportedException("Feature not supported");
3788 }
3789
3790 /**
3791 * Sets the designated parameter to a <code>InputStream</code> object.
3792 * This method differs from the <code>setBinaryStream (int, InputStream)</code>
3793 * method because it informs the driver that the parameter value should be
3794 * sent to the server as a <code>BLOB</code>. When the <code>setBinaryStream</code> method is used,
3795 * the driver may have to do extra work to determine whether the parameter
3796 * data should be sent to the server as a <code>LONGVARBINARY</code> or a <code>BLOB</code>
3797 *
3798 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3799 * it might be more efficient to use a version of
3800 * <code>setBlob</code> which takes a length parameter.
3801 *
3802 * @param parameterIndex index of the first parameter is 1,
3803 * the second is 2, ...
3804 * @param inputStream An object that contains the data to set the parameter
3805 * value to.
3806 * @throws SQLException if a database access error occurs,
3807 * this method is called on a closed <code>PreparedStatement</code> or
3808 * if parameterIndex does not correspond
3809 * to a parameter marker in the SQL statement,
3810 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3811 *
3812 * @since 1.6
3813 */
3814 public void setBlob(int parameterIndex, InputStream inputStream)
3815 throws SQLException{
3816 throw new SQLFeatureNotSupportedException("Feature not supported");
3817 }
3818
3819 /**
3820 * Sets the designated parameter to a <code>InputStream</code> object.
3821 * The <code>Inputstream</code> must contain the number
3822 * of characters specified by length, otherwise a <code>SQLException</code> will be
3823 * generated when the <code>CallableStatement</code> is executed.
3824 * This method differs from the <code>setBinaryStream (int, InputStream, int)</code>
3825 * method because it informs the driver that the parameter value should be
3826 * sent to the server as a <code>BLOB</code>. When the <code>setBinaryStream</code> method is used,
3827 * the driver may have to do extra work to determine whether the parameter
3828 * data should be sent to the server as a <code>LONGVARBINARY</code> or a <code>BLOB</code>
3829 *
3830 * @param parameterName the name of the parameter to be set
3831 * the second is 2, ...
3832 *
3833 * @param inputStream An object that contains the data to set the parameter
3834 * value to.
3835 * @param length the number of bytes in the parameter data.
3836 * @throws SQLException if parameterIndex does not correspond
3837 * to a parameter marker in the SQL statement, or if the length specified
3838 * is less than zero; if the number of bytes in the <code>InputStream</code> does not match
3839 * the specified length; if a database access error occurs or
3840 * this method is called on a closed <code>CallableStatement</code>
3841 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3842 * this method
3843 *
3844 * @since 1.6
3845 */
3846 public void setBlob(String parameterName, InputStream inputStream, long length)
3847 throws SQLException{
3848 throw new SQLFeatureNotSupportedException("Feature not supported");
3849 }
3850
3851 /**
3852 * Sets the designated parameter to the given <code>java.sql.Blob</code> object.
3853 * The driver converts this to an SQL <code>BLOB</code> value when it
3854 * sends it to the database.
3855 *
3856 * @param parameterName the name of the parameter
3857 * @param x a <code>Blob</code> object that maps an SQL <code>BLOB</code> value
3858 * @exception SQLException if a database access error occurs or
3859 * this method is called on a closed <code>CallableStatement</code>
3860 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3861 * this method
3862 * @since 1.6
3863 */
3864 public void setBlob (String parameterName, Blob x) throws SQLException{
3865 throw new SQLFeatureNotSupportedException("Feature not supported");
3866 }
3867
3868 /**
3869 * Sets the designated parameter to a <code>InputStream</code> object.
3870 * This method differs from the <code>setBinaryStream (int, InputStream)</code>
3871 * method because it informs the driver that the parameter value should be
3872 * sent to the server as a <code>BLOB</code>. When the <code>setBinaryStream</code> method is used,
3873 * the driver may have to do extra work to determine whether the parameter
3874 * data should be send to the server as a <code>LONGVARBINARY</code> or a <code>BLOB</code>
3875 *
3876 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3877 * it might be more efficient to use a version of
3878 * <code>setBlob</code> which takes a length parameter.
3879 *
3880 * @param parameterName the name of the parameter
3881 * @param inputStream An object that contains the data to set the parameter
3882 * value to.
3883 * @throws SQLException if a database access error occurs or
3884 * this method is called on a closed <code>CallableStatement</code>
3885 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3886 *
3887 * @since 1.6
3888 */
3889 public void setBlob(String parameterName, InputStream inputStream)
3890 throws SQLException{
3891 throw new SQLFeatureNotSupportedException("Feature not supported");
3892 }
3893
3894 /**
3895 * Sets the designated parameter to a <code>Reader</code> object.
3896 * The reader must contain the number
3897 * of characters specified by length otherwise a <code>SQLException</code> will be
3898 * generated when the <code>PreparedStatement</code> is executed.
3899 * This method differs from the <code>setCharacterStream (int, Reader, int)</code> method
3900 * because it informs the driver that the parameter value should be sent to
3901 * the server as a <code>CLOB</code>. When the <code>setCharacterStream</code> method is used, the
3902 * driver may have to do extra work to determine whether the parameter
3903 * data should be sent to the server as a <code>LONGVARCHAR</code> or a <code>CLOB</code>
3904 * @param parameterIndex index of the first parameter is 1, the second is 2, ...
3905 * @param reader An object that contains the data to set the parameter value to.
3906 * @param length the number of characters in the parameter data.
3907 * @throws SQLException if a database access error occurs, this method is called on
3908 * a closed <code>PreparedStatement</code>, if parameterIndex does not correspond to a parameter
3909 * marker in the SQL statement, or if the length specified is less than zero.
3910 *
3911 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3912 * @since 1.6
3913 */
3914 public void setClob(int parameterIndex, Reader reader, long length)
3915 throws SQLException{
3916 throw new SQLFeatureNotSupportedException("Feature not supported");
3917 }
3918
3919 /**
3920 * Sets the designated parameter to a <code>Reader</code> object.
3921 * This method differs from the <code>setCharacterStream (int, Reader)</code> method
3922 * because it informs the driver that the parameter value should be sent to
3923 * the server as a <code>CLOB</code>. When the <code>setCharacterStream</code> method is used, the
3924 * driver may have to do extra work to determine whether the parameter
3925 * data should be sent to the server as a <code>LONGVARCHAR</code> or a <code>CLOB</code>
3926 *
3927 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3928 * it might be more efficient to use a version of
3929 * <code>setClob</code> which takes a length parameter.
3930 *
3931 * @param parameterIndex index of the first parameter is 1, the second is 2, ...
3932 * @param reader An object that contains the data to set the parameter value to.
3933 * @throws SQLException if a database access error occurs, this method is called on
3934 * a closed <code>PreparedStatement</code>or if parameterIndex does not correspond to a parameter
3935 * marker in the SQL statement
3936 *
3937 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
3938 * @since 1.6
3939 */
3940 public void setClob(int parameterIndex, Reader reader)
3941 throws SQLException{
3942 throw new SQLFeatureNotSupportedException("Feature not supported");
3943 }
3944
3945 /**
3946 * Sets the designated parameter to a <code>Reader</code> object.
3947 * The <code>reader</code> must contain the number
3948 * of characters specified by length otherwise a <code>SQLException</code> will be
3949 * generated when the <code>CallableStatement</code> is executed.
3950 * This method differs from the <code>setCharacterStream (int, Reader, int)</code> method
3951 * because it informs the driver that the parameter value should be sent to
3952 * the server as a <code>CLOB</code>. When the <code>setCharacterStream</code> method is used, the
3953 * driver may have to do extra work to determine whether the parameter
3954 * data should be send to the server as a <code>LONGVARCHAR</code> or a <code>CLOB</code>
3955 * @param parameterName the name of the parameter to be set
3956 * @param reader An object that contains the data to set the parameter value to.
3957 * @param length the number of characters in the parameter data.
3958 * @throws SQLException if parameterIndex does not correspond to a parameter
3959 * marker in the SQL statement; if the length specified is less than zero;
3960 * a database access error occurs or
3961 * this method is called on a closed <code>CallableStatement</code>
3962 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3963 * this method
3964 *
3965 * @since 1.6
3966 */
3967 public void setClob(String parameterName, Reader reader, long length)
3968 throws SQLException {
3969 throw new SQLFeatureNotSupportedException("Feature not supported");
3970 }
3971
3972 /**
3973 * Sets the designated parameter to the given <code>java.sql.Clob</code> object.
3974 * The driver converts this to an SQL <code>CLOB</code> value when it
3975 * sends it to the database.
3976 *
3977 * @param parameterName the name of the parameter
3978 * @param x a <code>Clob</code> object that maps an SQL <code>CLOB</code> value
3979 * @exception SQLException if a database access error occurs or
3980 * this method is called on a closed <code>CallableStatement</code>
3981 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3982 * this method
3983 * @since 1.6
3984 */
3985 public void setClob (String parameterName, Clob x) throws SQLException {
3986 throw new SQLFeatureNotSupportedException("Feature not supported");
3987 }
3988
3989 /**
3990 * Sets the designated parameter to a <code>Reader</code> object.
3991 * This method differs from the <code>setCharacterStream (int, Reader)</code> method
3992 * because it informs the driver that the parameter value should be sent to
3993 * the server as a <code>CLOB</code>. When the <code>setCharacterStream</code> method is used, the
3994 * driver may have to do extra work to determine whether the parameter
3995 * data should be send to the server as a <code>LONGVARCHAR</code> or a <code>CLOB</code>
3996 *
3997 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3998 * it might be more efficient to use a version of
3999 * <code>setClob</code> which takes a length parameter.
4000 *
4001 * @param parameterName the name of the parameter
4002 * @param reader An object that contains the data to set the parameter value to.
4003 * @throws SQLException if a database access error occurs or this method is called on
4004 * a closed <code>CallableStatement</code>
4005 *
4006 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
4007 * @since 1.6
4008 */
4009 public void setClob(String parameterName, Reader reader) throws SQLException {
4010 throw new SQLFeatureNotSupportedException("Feature not supported");
4011 }
4012
4013 /**
4014 * Sets the designated parameter to the given <code>java.sql.Date</code> value
4015 * using the default time zone of the virtual machine that is running
4016 * the application.
4017 * The driver converts this
4018 * to an SQL <code>DATE</code> value when it sends it to the database.
4019 *
4020 * @param parameterName the name of the parameter
4021 * @param x the parameter value
4022 * @exception SQLException if a database access error occurs or
4023 * this method is called on a closed <code>CallableStatement</code>
4024 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4025 * this method
4026 * @see #getParams
4027 * @since 1.4
4028 */
4029 public void setDate(String parameterName, java.sql.Date x)
4030 throws SQLException {
4031 throw new SQLFeatureNotSupportedException("Feature not supported");
4032 }
4033
4034 /**
4035 * Sets the designated parameter to the given <code>java.sql.Date</code> value,
4036 * using the given <code>Calendar</code> object. The driver uses
4037 * the <code>Calendar</code> object to construct an SQL <code>DATE</code> value,
4038 * which the driver then sends to the database. With a
4039 * a <code>Calendar</code> object, the driver can calculate the date
4040 * taking into account a custom timezone. If no
4041 * <code>Calendar</code> object is specified, the driver uses the default
4042 * timezone, which is that of the virtual machine running the application.
4043 *
4044 * @param parameterName the name of the parameter
4045 * @param x the parameter value
4046 * @param cal the <code>Calendar</code> object the driver will use
4047 * to construct the date
4048 * @exception SQLException if a database access error occurs or
4049 * this method is called on a closed <code>CallableStatement</code>
4050 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4051 * this method
4052 * @see #getParams
4053 * @since 1.4
4054 */
4055 public void setDate(String parameterName, java.sql.Date x, Calendar cal)
4056 throws SQLException {
4057 throw new SQLFeatureNotSupportedException("Feature not supported");
4058 }
4059
4060 /**
4061 * Sets the designated parameter to the given <code>java.sql.Time</code> value.
4062 * The driver converts this
4063 * to an SQL <code>TIME</code> value when it sends it to the database.
4064 *
4065 * @param parameterName the name of the parameter
4066 * @param x the parameter value
4067 * @exception SQLException if a database access error occurs or
4068 * this method is called on a closed <code>CallableStatement</code>
4069 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4070 * this method
4071 * @see #getParams
4072 * @since 1.4
4073 */
4074 public void setTime(String parameterName, java.sql.Time x)
4075 throws SQLException {
4076 throw new SQLFeatureNotSupportedException("Feature not supported");
4077 }
4078
4079 /**
4080 * Sets the designated parameter to the given <code>java.sql.Time</code> value,
4081 * using the given <code>Calendar</code> object. The driver uses
4082 * the <code>Calendar</code> object to construct an SQL <code>TIME</code> value,
4083 * which the driver then sends to the database. With a
4084 * a <code>Calendar</code> object, the driver can calculate the time
4085 * taking into account a custom timezone. If no
4086 * <code>Calendar</code> object is specified, the driver uses the default
4087 * timezone, which is that of the virtual machine running the application.
4088 *
4089 * @param parameterName the name of the parameter
4090 * @param x the parameter value
4091 * @param cal the <code>Calendar</code> object the driver will use
4092 * to construct the time
4093 * @exception SQLException if a database access error occurs or
4094 * this method is called on a closed <code>CallableStatement</code>
4095 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4096 * this method
4097 * @see #getParams
4098 * @since 1.4
4099 */
4100 public void setTime(String parameterName, java.sql.Time x, Calendar cal)
4101 throws SQLException {
4102 throw new SQLFeatureNotSupportedException("Feature not supported");
4103 }
4104
4105 /**
4106 * Sets the designated parameter to the given <code>java.sql.Timestamp</code> value,
4107 * using the given <code>Calendar</code> object. The driver uses
4108 * the <code>Calendar</code> object to construct an SQL <code>TIMESTAMP</code> value,
4109 * which the driver then sends to the database. With a
4110 * a <code>Calendar</code> object, the driver can calculate the timestamp
4111 * taking into account a custom timezone. If no
4112 * <code>Calendar</code> object is specified, the driver uses the default
4113 * timezone, which is that of the virtual machine running the application.
4114 *
4115 * @param parameterName the name of the parameter
4116 * @param x the parameter value
4117 * @param cal the <code>Calendar</code> object the driver will use
4118 * to construct the timestamp
4119 * @exception SQLException if a database access error occurs or
4120 * this method is called on a closed <code>CallableStatement</code>
4121 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4122 * this method
4123 * @see #getParams
4124 * @since 1.4
4125 */
4126 public void setTimestamp(String parameterName, java.sql.Timestamp x, Calendar cal)
4127 throws SQLException {
4128 throw new SQLFeatureNotSupportedException("Feature not supported");
4129 }
4130
4131 /**
4132 * Sets the designated parameter to the given <code>java.sql.SQLXML</code> object. The driver converts this to an
4133 * SQL <code>XML</code> value when it sends it to the database.
4134 * @param parameterIndex index of the first parameter is 1, the second is 2, ...
4135 * @param xmlObject a <code>SQLXML</code> object that maps an SQL <code>XML</code> value
4136 * @throws SQLException if a database access error occurs, this method
4137 * is called on a closed result set,
4138 * the <code>java.xml.transform.Result</code>,
4139 * <code>Writer</code> or <code>OutputStream</code> has not been closed
4140 * for the <code>SQLXML</code> object or
4141 * if there is an error processing the XML value. The <code>getCause</code> method
4142 * of the exception may provide a more detailed exception, for example, if the
4143 * stream does not contain valid XML.
4144 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4145 * support this method
4146 * @since 1.6
4147 */
4148 public void setSQLXML(int parameterIndex, SQLXML xmlObject) throws SQLException {
4149 throw new SQLFeatureNotSupportedException("Feature not supported");
4150 }
4151
4152 /**
4153 * Sets the designated parameter to the given <code>java.sql.SQLXML</code> object. The driver converts this to an
4154 * <code>SQL XML</code> value when it sends it to the database.
4155 * @param parameterName the name of the parameter
4156 * @param xmlObject a <code>SQLXML</code> object that maps an <code>SQL XML</code> value
4157 * @throws SQLException if a database access error occurs, this method
4158 * is called on a closed result set,
4159 * the <code>java.xml.transform.Result</code>,
4160 * <code>Writer</code> or <code>OutputStream</code> has not been closed
4161 * for the <code>SQLXML</code> object or
4162 * if there is an error processing the XML value. The <code>getCause</code> method
4163 * of the exception may provide a more detailed exception, for example, if the
4164 * stream does not contain valid XML.
4165 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4166 * support this method
4167 * @since 1.6
4168 */
4169 public void setSQLXML(String parameterName, SQLXML xmlObject) throws SQLException {
4170 throw new SQLFeatureNotSupportedException("Feature not supported");
4171 }
4172
4173 /**
4174 * Sets the designated parameter to the given <code>java.sql.RowId</code> object. The
4175 * driver converts this to a SQL <code>ROWID</code> value when it sends it
4176 * to the database
4177 *
4178 * @param parameterIndex the first parameter is 1, the second is 2, ...
4179 * @param x the parameter value
4180 * @throws SQLException if a database access error occurs
4181 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4182 * support this method
4183 *
4184 * @since 1.6
4185 */
4186 public void setRowId(int parameterIndex, RowId x) throws SQLException {
4187 throw new SQLFeatureNotSupportedException("Feature not supported");
4188 }
4189
4190 /**
4191 * Sets the designated parameter to the given <code>java.sql.RowId</code> object. The
4192 * driver converts this to a SQL <code>ROWID</code> when it sends it to the
4193 * database.
4194 *
4195 * @param parameterName the name of the parameter
4196 * @param x the parameter value
4197 * @throws SQLException if a database access error occurs
4198 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4199 * support this method
4200 * @since 1.6
4201 */
4202 public void setRowId(String parameterName, RowId x) throws SQLException {
4203 throw new SQLFeatureNotSupportedException("Feature not supported");
4204 }
4205
4206 /**
4207 * Sets the designated parameter to the given <code>String</code> object.
4208 * The driver converts this to a SQL <code>NCHAR</code> or
4209 * <code>NVARCHAR</code> or <code>LONGNVARCHAR</code> value
4210 * (depending on the argument's
4211 * size relative to the driver's limits on <code>NVARCHAR</code> values)
4212 * when it sends it to the database.
4213 *
4214 * @param parameterIndex of the first parameter is 1, the second is 2, ...
4215 * @param value the parameter value
4216 * @throws SQLException if the driver does not support national
4217 * character sets; if the driver can detect that a data conversion
4218 * error could occur ; or if a database access error occurs
4219 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4220 * support this method
4221 * @since 1.6
4222 */
4223 public void setNString(int parameterIndex, String value) throws SQLException {
4224 throw new SQLFeatureNotSupportedException("Feature not supported");
4225 }
4226
4227 /**
4228 * Sets the designated parameter to the given <code>String</code> object.
4229 * The driver converts this to a SQL <code>NCHAR</code> or
4230 * <code>NVARCHAR</code> or <code>LONGNVARCHAR</code>
4231 * @param parameterName the name of the column to be set
4232 * @param value the parameter value
4233 * @throws SQLException if the driver does not support national
4234 * character sets; if the driver can detect that a data conversion
4235 * error could occur; or if a database access error occurs
4236 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4237 * support this method
4238 * @since 1.6
4239 */
4240 public void setNString(String parameterName, String value) throws SQLException {
4241 throw new SQLFeatureNotSupportedException("Feature not supported");
4242 }
4243
4244 /**
4245 * Sets the designated parameter to a <code>Reader</code> object. The
4246 * <code>Reader</code> reads the data till end-of-file is reached. The
4247 * driver does the necessary conversion from Java character format to
4248 * the national character set in the database.
4249 * @param parameterIndex of the first parameter is 1, the second is 2, ...
4250 * @param value the parameter value
4251 * @param length the number of characters in the parameter data.
4252 * @throws SQLException if the driver does not support national
4253 * character sets; if the driver can detect that a data conversion
4254 * error could occur ; or if a database access error occurs
4255 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4256 * support this method
4257 * @since 1.6
4258 */
4259 public void setNCharacterStream(int parameterIndex, Reader value, long length)
4260 throws SQLException {
4261 throw new SQLFeatureNotSupportedException("Feature not supported");
4262 }
4263
4264 /**
4265 * Sets the designated parameter to a <code>Reader</code> object. The
4266 * <code>Reader</code> reads the data till end-of-file is reached. The
4267 * driver does the necessary conversion from Java character format to
4268 * the national character set in the database.
4269 * @param parameterName the name of the column to be set
4270 * @param value the parameter value
4271 * @param length the number of characters in the parameter data.
4272 * @throws SQLException if the driver does not support national
4273 * character sets; if the driver can detect that a data conversion
4274 * error could occur; or if a database access error occurs
4275 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4276 * support this method
4277 * @since 1.6
4278 */
4279 public void setNCharacterStream(String parameterName, Reader value, long length)
4280 throws SQLException {
4281 throw new SQLFeatureNotSupportedException("Feature not supported");
4282 }
4283
4284 /**
4285 * Sets the designated parameter to a <code>Reader</code> object. The
4286 * <code>Reader</code> reads the data till end-of-file is reached. The
4287 * driver does the necessary conversion from Java character format to
4288 * the national character set in the database.
4289 * <P><B>Note:</B> This stream object can either be a standard
4290 * Java stream object or your own subclass that implements the
4291 * standard interface.
4292 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
4293 * it might be more efficient to use a version of
4294 * <code>setNCharacterStream</code> which takes a length parameter.
4295 *
4296 * @param parameterName the name of the parameter
4297 * @param value the parameter value
4298 * @throws SQLException if the driver does not support national
4299 * character sets; if the driver can detect that a data conversion
4300 * error could occur ; if a database access error occurs; or
4301 * this method is called on a closed <code>CallableStatement</code>
4302 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
4303 * @since 1.6
4304 */
4305 public void setNCharacterStream(String parameterName, Reader value)
4306 throws SQLException {
4307 throw new SQLFeatureNotSupportedException("Feature not supported");
4308 }
4309
4310 /**
4311 * Sets the designated parameter to a <code>java.sql.NClob</code> object. The object
4312 * implements the <code>java.sql.NClob</code> interface. This <code>NClob</code>
4313 * object maps to a SQL <code>NCLOB</code>.
4314 * @param parameterName the name of the column to be set
4315 * @param value the parameter value
4316 * @throws SQLException if the driver does not support national
4317 * character sets; if the driver can detect that a data conversion
4318 * error could occur; or if a database access error occurs
4319 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4320 * support this method
4321 * @since 1.6
4322 */
4323 public void setNClob(String parameterName, NClob value) throws SQLException {
4324 throw new SQLFeatureNotSupportedException("Feature not supported");
4325 }
4326
4327 /**
4328 * Sets the designated parameter to a <code>Reader</code> object. The <code>reader</code> must contain
4329 * the number
4330 * of characters specified by length otherwise a <code>SQLException</code> will be
4331 * generated when the <code>CallableStatement</code> is executed.
4332 * This method differs from the <code>setCharacterStream (int, Reader, int)</code> method
4333 * because it informs the driver that the parameter value should be sent to
4334 * the server as a <code>NCLOB</code>. When the <code>setCharacterStream</code> method is used, the
4335 * driver may have to do extra work to determine whether the parameter
4336 * data should be send to the server as a <code>LONGNVARCHAR</code> or a <code>NCLOB</code>
4337 *
4338 * @param parameterName the name of the parameter to be set
4339 * @param reader An object that contains the data to set the parameter value to.
4340 * @param length the number of characters in the parameter data.
4341 * @throws SQLException if parameterIndex does not correspond to a parameter
4342 * marker in the SQL statement; if the length specified is less than zero;
4343 * if the driver does not support national
4344 * character sets; if the driver can detect that a data conversion
4345 * error could occur; if a database access error occurs or
4346 * this method is called on a closed <code>CallableStatement</code>
4347 * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4348 * this method
4349 * @since 1.6
4350 */
4351 public void setNClob(String parameterName, Reader reader, long length)
4352 throws SQLException {
4353 throw new SQLFeatureNotSupportedException("Feature not supported");
4354 }
4355
4356 /**
4357 * Sets the designated parameter to a <code>Reader</code> object.
4358 * This method differs from the <code>setCharacterStream (int, Reader)</code> method
4359 * because it informs the driver that the parameter value should be sent to
4360 * the server as a <code>NCLOB</code>. When the <code>setCharacterStream</code> method is used, the
4361 * driver may have to do extra work to determine whether the parameter
4362 * data should be send to the server as a <code>LONGNVARCHAR</code> or a <code>NCLOB</code>
4363 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
4364 * it might be more efficient to use a version of
4365 * <code>setNClob</code> which takes a length parameter.
4366 *
4367 * @param parameterName the name of the parameter
4368 * @param reader An object that contains the data to set the parameter value to.
4369 * @throws SQLException if the driver does not support national character sets;
4370 * if the driver can detect that a data conversion
4371 * error could occur; if a database access error occurs or
4372 * this method is called on a closed <code>CallableStatement</code>
4373 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
4374 *
4375 * @since 1.6
4376 */
4377 public void setNClob(String parameterName, Reader reader) throws SQLException {
4378 throw new SQLFeatureNotSupportedException("Feature not supported");
4379 }
4380
4381 /**
4382 * Sets the designated parameter to a <code>Reader</code> object. The reader must contain the number
4383 * of characters specified by length otherwise a <code>SQLException</code> will be
4384 * generated when the <code>PreparedStatement</code> is executed.
4385 * This method differs from the <code>setCharacterStream (int, Reader, int)</code> method
4386 * because it informs the driver that the parameter value should be sent to
4387 * the server as a <code>NCLOB</code>. When the <code>setCharacterStream</code> method is used, the
4388 * driver may have to do extra work to determine whether the parameter
4389 * data should be sent to the server as a <code>LONGNVARCHAR</code> or a <code>NCLOB</code>
4390 * @param parameterIndex index of the first parameter is 1, the second is 2, ...
4391 * @param reader An object that contains the data to set the parameter value to.
4392 * @param length the number of characters in the parameter data.
4393 * @throws SQLException if parameterIndex does not correspond to a parameter
4394 * marker in the SQL statement; if the length specified is less than zero;
4395 * if the driver does not support national character sets;
4396 * if the driver can detect that a data conversion
4397 * error could occur; if a database access error occurs or
4398 * this method is called on a closed <code>PreparedStatement</code>
4399 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4400 * support this method
4401 *
4402 * @since 1.6
4403 */
4404 public void setNClob(int parameterIndex, Reader reader, long length)
4405 throws SQLException {
4406 throw new SQLFeatureNotSupportedException("Feature not supported");
4407 }
4408
4409 /**
4410 * Sets the designated parameter to a <code>java.sql.NClob</code> object. The driver converts this oa
4411 * SQL <code>NCLOB</code> value when it sends it to the database.
4412 * @param parameterIndex of the first parameter is 1, the second is 2, ...
4413 * @param value the parameter value
4414 * @throws SQLException if the driver does not support national
4415 * character sets; if the driver can detect that a data conversion
4416 * error could occur ; or if a database access error occurs
4417 * @throws SQLFeatureNotSupportedException if the JDBC driver does not
4418 * support this method
4419 * @since 1.6
4420 */
4421 public void setNClob(int parameterIndex, NClob value) throws SQLException {
4422 throw new SQLFeatureNotSupportedException("Feature not supported");
4423 }
4424
4425 /**
4426 * Sets the designated parameter to a <code>Reader</code> object.
4427 * This method differs from the <code>setCharacterStream (int, Reader)</code> method
4428 * because it informs the driver that the parameter value should be sent to
4429 * the server as a <code>NCLOB</code>. When the <code>setCharacterStream</code> method is used, the
4430 * driver may have to do extra work to determine whether the parameter
4431 * data should be sent to the server as a <code>LONGNVARCHAR</code> or a <code>NCLOB</code>
4432 * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
4433 * it might be more efficient to use a version of
4434 * <code>setNClob</code> which takes a length parameter.
4435 *
4436 * @param parameterIndex index of the first parameter is 1, the second is 2, ...
4437 * @param reader An object that contains the data to set the parameter value to.
4438 * @throws SQLException if parameterIndex does not correspond to a parameter
4439 * marker in the SQL statement;
4440 * if the driver does not support national character sets;
4441 * if the driver can detect that a data conversion
4442 * error could occur; if a database access error occurs or
4443 * this method is called on a closed <code>PreparedStatement</code>
4444 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
4445 *
4446 * @since 1.6
4447 */
4448 public void setNClob(int parameterIndex, Reader reader)throws SQLException {
4449 throw new SQLFeatureNotSupportedException("Feature not supported");
4450 }
4451
4452 /**
4453 * Sets the designated parameter to the given <code>java.net.URL</code> value.
4454 * The driver converts this to an SQL <code>DATALINK</code> value
4455 * when it sends it to the database.
4456 *
4457 * @param parameterIndex the first parameter is 1, the second is 2, ...
4458 * @param x the <code>java.net.URL</code> object to be set
4459 * @exception SQLException if a database access error occurs or
4460 * this method is called on a closed <code>PreparedStatement</code>
4461 * @throws SQLFeatureNotSupportedException if the JDBC driver does not support this method
4462 * @since 1.4
4463 */
4464 public void setURL(int parameterIndex, java.net.URL x) throws SQLException {
4465 throw new SQLFeatureNotSupportedException("Feature not supported");
4466 }
4467
4468 static final long serialVersionUID = 4886719666485113312L;
4469
4470 } //end class
|