001 /*************************************************************************************************** 002 * MODULE DESCRIPTION 003 **************************************************************************************************** 004 * 005 * NAME: IntItem.java 006 * LANGUAGE: Java2 007 * DATE: 4.12.2002 008 * AUTHOR: Miika Nurminen, University of Jyväskylä 009 * 010 **************************************************************************************************** 011 * COPYRIGHT (C) KIURU -PROJECT GROUP 012 * Limited rights granted. Please refer to license 013 **************************************************************************************************** 014 * 015 **************************************************************************************************** 016 * UPDATES 017 **************************************************************************************************** 018 * 019 * 4.12.2002: Initial release / mn 020 * 021 ****************************************************************************************************/ 022 package kiurubeans; 023 024 /** 025 * Representation of a preparedstatement item of type <code>int</code>. 026 */ 027 public class IntItem extends kiurubeans.StatementItem { 028 029 /** 030 * Creates a new instance of StateMentItem with int content. 031 * @param content content for PreparedStatement 032 */ 033 public IntItem(int content) { 034 super(new Integer(content)); 035 } 036 037 038 /** 039 * Sets target's parameter of a given index. ASSUMES target is set! 040 * 041 * @param index index number for parameter 042 * @throws SQLException if problems with setting 043 */ 044 void assignItem(int index) throws java.sql.SQLException { 045 target.setInt(index,((Integer)getContent()).intValue()); 046 } 047 048 } 049 /*************************************************************************************************** 050 * COPYRIGHT (C) KIURU -PROJECT GROUP 051 * Limited rights granted. Please refer to license. 052 **************************************************************************************************/