test_class.declarator: jdbcInputFormat
test_class.modifier: private
test_class.original_string: private JDBCInputFormat jdbcInputFormat;
test_class.type: JDBCInputFormat
test_class.var_name: jdbcInputFormat
test_class.declarator: jdbcOutputFormat
test_class.modifier: private
test_class.original_string: private JDBCOutputFormat jdbcOutputFormat;
test_class.type: JDBCOutputFormat
test_class.var_name: jdbcOutputFormat
test_class.declarator: conn
test_class.modifier: private static
test_class.original_string: private static Connection conn;
test_class.type: Connection
test_class.var_name: conn
test_class.declarator: dbData = {
  		{1001, ("Java for dummies"), ("Tan Ah Teck"), 11.11, 11},
  		{1002, ("More Java for dummies"), ("Tan Ah Teck"), 22.22, 22},
  		{1003, ("More Java for more dummies"), ("Mohammad Ali"), 33.33, 33},
  		{1004, ("A Cup of Java"), ("Kumar"), 44.44, 44},
  		{1005, ("A Teaspoon of Java"), ("Kevin Jones"), 55.55, 55}}
test_class.modifier: static final
test_class.original_string: static final Object[][] dbData = {
  		{1001, ("Java for dummies"), ("Tan Ah Teck"), 11.11, 11},
  		{1002, ("More Java for dummies"), ("Tan Ah Teck"), 22.22, 22},
  		{1003, ("More Java for more dummies"), ("Mohammad Ali"), 33.33, 33},
  		{1004, ("A Cup of Java"), ("Kumar"), 44.44, 44},
  		{1005, ("A Teaspoon of Java"), ("Kevin Jones"), 55.55, 55}};
test_class.type: Object[][]
test_class.var_name: dbData
test_class.file: flink-batch-connectors/flink-jdbc/src/test/java/org/apache/flink/api/java/io/jdbc/JDBCOutputFormatTest.java
test_class.identifier: JDBCOutputFormatTest
test_case.body: @Test
  	public void testJDBCOutputFormat() throws IOException {
  		String sourceTable = "books";
  		String targetTable = "newbooks";
  		String driverPath = "org.apache.derby.jdbc.EmbeddedDriver";
  		String dbUrl = "jdbc:derby:memory:ebookshop";
  
  		jdbcOutputFormat = JDBCOutputFormat.buildJDBCOutputFormat()
  				.setDBUrl(dbUrl)
  				.setDrivername(driverPath)
  				.setQuery("insert into " + targetTable + " (id, title, author, price, qty) values (?,?,?,?,?)")
  				.finish();
  		jdbcOutputFormat.open(0, 1);
  
  		jdbcInputFormat = JDBCInputFormat.buildJDBCInputFormat()
  				.setDrivername(driverPath)
  				.setDBUrl(dbUrl)
  				.setQuery("select * from " + sourceTable)
  				.setResultSetType(ResultSet.TYPE_SCROLL_INSENSITIVE)
  				.finish();
  		jdbcInputFormat.open(null);
  
  		Tuple5 tuple = new Tuple5();
  		while (!jdbcInputFormat.reachedEnd()) {
  			jdbcInputFormat.nextRecord(tuple);
  			jdbcOutputFormat.writeRecord(tuple);
  		}
  
  		jdbcOutputFormat.close();
  		jdbcInputFormat.close();
  
  		jdbcInputFormat = JDBCInputFormat.buildJDBCInputFormat()
  				.setDrivername(driverPath)
  				.setDBUrl(dbUrl)
  				.setQuery("select * from " + targetTable)
  				.setResultSetType(ResultSet.TYPE_SCROLL_INSENSITIVE)
  				.finish();
  		jdbcInputFormat.open(null);
  
  		int recordCount = 0;
  		while (!jdbcInputFormat.reachedEnd()) {
  			jdbcInputFormat.nextRecord(tuple);
  			Assert.assertEquals("Field 0 should be int", Integer.class, tuple.getField(0).getClass());
  			Assert.assertEquals("Field 1 should be String", String.class, tuple.getField(1).getClass());
  			Assert.assertEquals("Field 2 should be String", String.class, tuple.getField(2).getClass());
  			Assert.assertEquals("Field 3 should be float", Double.class, tuple.getField(3).getClass());
  			Assert.assertEquals("Field 4 should be int", Integer.class, tuple.getField(4).getClass());
  
  			for (int x = 0; x < 5; x++) {
  				Assert.assertEquals(dbData[recordCount][x], tuple.getField(x));
  			}
  
  			recordCount++;
  		}
  		Assert.assertEquals(5, recordCount);
  
  		jdbcInputFormat.close();
  	}
test_case.class_method_signature: JDBCOutputFormatTest.testJDBCOutputFormat()
test_case.full_signature: @Test public void testJDBCOutputFormat()
test_case.identifier: testJDBCOutputFormat
test_case.invocations: finish setQuery setDrivername setDBUrl buildJDBCOutputFormat open finish setResultSetType setQuery setDBUrl setDrivername buildJDBCInputFormat open reachedEnd nextRecord writeRecord close close finish setResultSetType setQuery setDBUrl setDrivername buildJDBCInputFormat open reachedEnd nextRecord assertEquals getClass getField assertEquals getClass getField assertEquals getClass getField assertEquals getClass getField assertEquals getClass getField assertEquals getField assertEquals close
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testJDBCOutputFormat()
focal_class.declarator: serialVersionUID = 1L
focal_class.modifier: private static final
focal_class.original_string: private static final long serialVersionUID = 1L;
focal_class.type: long
focal_class.var_name: serialVersionUID
focal_class.declarator: LOG = LoggerFactory.getLogger(JDBCOutputFormat.class)
focal_class.modifier: @SuppressWarnings("unused")
  	private static final
focal_class.original_string: @SuppressWarnings("unused")
  	private static final Logger LOG = LoggerFactory.getLogger(JDBCOutputFormat.class);
focal_class.type: Logger
focal_class.var_name: LOG
focal_class.declarator: username
focal_class.modifier: private
focal_class.original_string: private String username;
focal_class.type: String
focal_class.var_name: username
focal_class.declarator: password
focal_class.modifier: private
focal_class.original_string: private String password;
focal_class.type: String
focal_class.var_name: password
focal_class.declarator: drivername
focal_class.modifier: private
focal_class.original_string: private String drivername;
focal_class.type: String
focal_class.var_name: drivername
focal_class.declarator: dbURL
focal_class.modifier: private
focal_class.original_string: private String dbURL;
focal_class.type: String
focal_class.var_name: dbURL
focal_class.declarator: query
focal_class.modifier: private
focal_class.original_string: private String query;
focal_class.type: String
focal_class.var_name: query
focal_class.declarator: batchInterval = 5000
focal_class.modifier: private
focal_class.original_string: private int batchInterval = 5000;
focal_class.type: int
focal_class.var_name: batchInterval
focal_class.declarator: dbConn
focal_class.modifier: private
focal_class.original_string: private Connection dbConn;
focal_class.type: Connection
focal_class.var_name: dbConn
focal_class.declarator: upload
focal_class.modifier: private
focal_class.original_string: private PreparedStatement upload;
focal_class.type: PreparedStatement
focal_class.var_name: upload
focal_class.declarator: types = null
focal_class.modifier: private
focal_class.original_string: private SupportedTypes[] types = null;
focal_class.type: SupportedTypes[]
focal_class.var_name: types
focal_class.declarator: batchCount = 0
focal_class.modifier: private
focal_class.original_string: private int batchCount = 0;
focal_class.type: int
focal_class.var_name: batchCount
focal_class.file: flink-batch-connectors/flink-jdbc/src/main/java/org/apache/flink/api/java/io/jdbc/JDBCOutputFormat.java
focal_class.identifier: JDBCOutputFormat
focal_class.class_method_signature: JDBCOutputFormat.JDBCOutputFormat()
focal_class.full_signature: public  JDBCOutputFormat()
focal_class.identifier: JDBCOutputFormat
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  JDBCOutputFormat()
focal_class.class_method_signature: JDBCOutputFormat.configure(Configuration parameters)
focal_class.full_signature: @Override public void configure(Configuration parameters)
focal_class.identifier: configure
focal_class.modifiers: @Override public
focal_class.parameters: (Configuration parameters)
focal_class.return: void
focal_class.signature: void configure(Configuration parameters)
focal_class.class_method_signature: JDBCOutputFormat.open(int taskNumber, int numTasks)
focal_class.full_signature: @Override public void open(int taskNumber, int numTasks)
focal_class.identifier: open
focal_class.modifiers: @Override public
focal_class.parameters: (int taskNumber, int numTasks)
focal_class.return: void
focal_class.signature: void open(int taskNumber, int numTasks)
focal_class.class_method_signature: JDBCOutputFormat.establishConnection()
focal_class.full_signature: private void establishConnection()
focal_class.identifier: establishConnection
focal_class.modifiers: private
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void establishConnection()
focal_class.class_method_signature: JDBCOutputFormat.writeRecord(OUT tuple)
focal_class.full_signature: @Override public void writeRecord(OUT tuple)
focal_class.identifier: writeRecord
focal_class.modifiers: @Override public
focal_class.parameters: (OUT tuple)
focal_class.return: void
focal_class.signature: void writeRecord(OUT tuple)
focal_class.class_method_signature: JDBCOutputFormat.extractTypes(OUT tuple)
focal_class.full_signature: private void extractTypes(OUT tuple)
focal_class.identifier: extractTypes
focal_class.modifiers: private
focal_class.parameters: (OUT tuple)
focal_class.return: void
focal_class.signature: void extractTypes(OUT tuple)
focal_class.class_method_signature: JDBCOutputFormat.addValues(OUT tuple)
focal_class.full_signature: private void addValues(OUT tuple)
focal_class.identifier: addValues
focal_class.modifiers: private
focal_class.parameters: (OUT tuple)
focal_class.return: void
focal_class.signature: void addValues(OUT tuple)
focal_class.class_method_signature: JDBCOutputFormat.close()
focal_class.full_signature: @Override public void close()
focal_class.identifier: close
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void close()
focal_class.class_method_signature: JDBCOutputFormat.buildJDBCOutputFormat()
focal_class.full_signature: public static JDBCOutputFormatBuilder buildJDBCOutputFormat()
focal_class.identifier: buildJDBCOutputFormat
focal_class.modifiers: public static
focal_class.parameters: ()
focal_class.return: JDBCOutputFormatBuilder
focal_class.signature: JDBCOutputFormatBuilder buildJDBCOutputFormat()
focal_class.superclass: extends RichOutputFormat<OUT>
focal_method.body: public JDBCOutputFormat() {
  	}
focal_method.class_method_signature: JDBCOutputFormat.JDBCOutputFormat()
focal_method.full_signature: public  JDBCOutputFormat()
focal_method.identifier: JDBCOutputFormat
focal_method.modifiers: public
focal_method.parameters: ()
focal_method.signature:  JDBCOutputFormat()