2.9.2: 2009-01-08

net.sf.basedb.clients.migrate
Class RawBioAssayDataTransfer

java.lang.Object
  extended by net.sf.basedb.clients.migrate.Manager
      extended by net.sf.basedb.clients.migrate.Transfer
          extended by net.sf.basedb.clients.migrate.RawBioAssayDataTransfer

public class RawBioAssayDataTransfer
extends Transfer

This class provides methods for transferring RawBioAssay and RawBioAssayData from base 1 to BASE 2. Base 1 files are located in /userfiles/rawdata/

Version:
2.0
Author:
Gregory, Martin
Last modified
$Date: 2008-09-11 22:05:50 +0200 (Thu, 11 Sep 2008) $

Field Summary
private  String[] floatProperties
          Set string and text properties, order must match the select statement except for the id and reporterId in the beginning Extended properties are defined in the extended-properties.xml file for class ReporterData Why do it this way and not using the column name for lookup?
private  String[] intProperties
           
private static Logger log
          Logger for this class
private  RawBioAssayTransfer rbaT
           
private  ReporterTransfer reporterT
           
 
Fields inherited from class net.sf.basedb.clients.migrate.Transfer
BASE2, FROM, itemList, LIMIT, LOCAL_MYSQL_TRANSFER, mapIds, progress, properties, QUICK_TRANSFER, selectOffset, sessionControl, TO
 
Constructor Summary
RawBioAssayDataTransfer(RawBioAssayTransfer rbaT, ReporterTransfer reporterT)
          Constructs a new RawBioAssayTransfer.
 
Method Summary
protected  void createItem(ResultSet rs)
          Transfers associated RawBioAssayData for each RawBioAssay and creates spotImages if necessary.
protected  void runRawBioAssay(RawBioAssay rawBioAssay, RawDataBatcher batcher, boolean hasArrayDesign, int base1RawBioAssayId)
          Recursive run over a SQL query defined by a prepared statement and LIMIT values from and size.
 void start()
          Starts the actual transfer.
private  void transferRawBioAssayData(RawBioAssay rawBioAssay, int rawBioAssayId, boolean hasArrayDesign)
          This method starts the data transfer.
 
Methods inherited from class net.sf.basedb.clients.migrate.Transfer
cleanUpMemory, commit, createItem, dependencyFailure, done, getBase2Id, getBatchSize, getCount, getDependencyStatus, getIdMap, getInt, getProperty, initIdMap, isDone, mapId, newDbControl, readRestorePointData, run, run, runUnBatched, saveItem, setup, startProgress, writeRestorePointData
 
Methods inherited from class net.sf.basedb.clients.migrate.Manager
getPreparedStatements, prepareStatementFromFile, print, printDate, setPreparedStatements, stop
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

private static final Logger log
Logger for this class


floatProperties

private String[] floatProperties
Set string and text properties, order must match the select statement except for the id and reporterId in the beginning Extended properties are defined in the extended-properties.xml file for class ReporterData Why do it this way and not using the column name for lookup? Performance is increased by using the column index instead of name.


intProperties

private String[] intProperties

rbaT

private RawBioAssayTransfer rbaT

reporterT

private ReporterTransfer reporterT
Constructor Detail

RawBioAssayDataTransfer

RawBioAssayDataTransfer(RawBioAssayTransfer rbaT,
                        ReporterTransfer reporterT)
Constructs a new RawBioAssayTransfer.

Parameters:
rbaT - A finished RawBioAssayTransfer
reporterT - A finished ReporterTransfer
Method Detail

start

public void start()
Description copied from class: Transfer
Starts the actual transfer.

Specified by:
start in class Transfer

createItem

protected void createItem(ResultSet rs)
                   throws SQLException
Transfers associated RawBioAssayData for each RawBioAssay and creates spotImages if necessary.

Overrides:
createItem in class Transfer
Parameters:
rs - ResultSet containing the data for this item.
Throws:
SQLException - If current ResultSet position is invalid or number of columns in the select statement is to low.

transferRawBioAssayData

private void transferRawBioAssayData(RawBioAssay rawBioAssay,
                                     int rawBioAssayId,
                                     boolean hasArrayDesign)
This method starts the data transfer. Defining the SQL statement used for data selection.

Parameters:
rawBioAssay - Existing rawBioAssay for which data will be transfered.
rawBioAssayId - Base 1 id of the rawBioAssay.

runRawBioAssay

protected void runRawBioAssay(RawBioAssay rawBioAssay,
                              RawDataBatcher batcher,
                              boolean hasArrayDesign,
                              int base1RawBioAssayId)
Recursive run over a SQL query defined by a prepared statement and LIMIT values from and size.

Parameters:
rawBioAssay - The raw bio assay to transfer data to
batcher - RawDataBatcher used in this transfer
hasArrayDesign - (Currently not used)
base1RawBioAssayId - The ID of the raw bioassay in the BASE 1.2 installation
See Also:
Manager.prepareStatementFromFile(String)

2.9.2: 2009-01-08