test_class.declarator: dao
test_class.modifier: @Autowired
      private
test_class.original_string: @Autowired
      private DNCWorkUnitDao dao;
test_class.type: DNCWorkUnitDao
test_class.var_name: dao
test_class.file: pipeline/src/test/java/uk/ac/kcl/iop/brc/core/pipeline/dncpipeline/data/DNCWorkUnitDaoTest.java
test_class.identifier: DNCWorkUnitDaoTest
test_class.superclass: extends IntegrationTest
test_case.body: @Test
      public void shouldSaveAnonymisedTextToTargetDB() {
          dao.executeSQLQueryForTarget("create table TBLTESTOUTPUTCOORDINATE (SOURCETABLE varchar(100), SOURCECOLUMN varchar(100), IDINSOURCETABLE int, PROCESSEDTEXT varchar(100), UPDATETIME varchar(100))");
          DNCWorkCoordinate coordinate = new DNCWorkCoordinate().sourceTable("TBLTESTOUTPUTCOORDINATE")
                  .sourceColumn("someBinaryColumn").idInSourceTable(4L);
          coordinate.setUpdateTime("2015-02-11 16:18:43.42");
          dao.saveConvertedText(coordinate, "anonymised text");
          List list = dao.getSQLResultFromTarget("select processedText from TBLTESTOUTPUTCOORDINATE where IDINSOURCETABLE=4");
  
          String text = (String) list.get(0);
  
          assertThat(text, equalTo("anonymised text"));
          dao.executeSQLQueryForTarget("DROP TABLE TBLTESTOUTPUTCOORDINATE");
      }
test_case.class_method_signature: DNCWorkUnitDaoTest.shouldSaveAnonymisedTextToTargetDB()
test_case.full_signature: @Test public void shouldSaveAnonymisedTextToTargetDB()
test_case.identifier: shouldSaveAnonymisedTextToTargetDB
test_case.invocations: executeSQLQueryForTarget idInSourceTable sourceColumn sourceTable setUpdateTime saveConvertedText getSQLResultFromTarget get assertThat equalTo executeSQLQueryForTarget
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void shouldSaveAnonymisedTextToTargetDB()
focal_class.declarator: blobHelper
focal_class.modifier: @Autowired
      private
focal_class.original_string: @Autowired
      private BlobHelper blobHelper;
focal_class.type: BlobHelper
focal_class.var_name: blobHelper
focal_class.declarator: clobHelper
focal_class.modifier: @Autowired
      private
focal_class.original_string: @Autowired
      private ClobHelper clobHelper;
focal_class.type: ClobHelper
focal_class.var_name: clobHelper
focal_class.file: pipeline/src/main/java/uk/ac/kcl/iop/brc/core/pipeline/dncpipeline/data/DNCWorkUnitDao.java
focal_class.identifier: DNCWorkUnitDao
focal_class.class_method_signature: DNCWorkUnitDao.getTextFromCoordinate(DNCWorkCoordinate coordinate)
focal_class.full_signature: public String getTextFromCoordinate(DNCWorkCoordinate coordinate)
focal_class.identifier: getTextFromCoordinate
focal_class.modifiers: public
focal_class.parameters: (DNCWorkCoordinate coordinate)
focal_class.return: String
focal_class.signature: String getTextFromCoordinate(DNCWorkCoordinate coordinate)
focal_class.class_method_signature: DNCWorkUnitDao.getByteFromCoordinate(DNCWorkCoordinate coordinate)
focal_class.full_signature: public byte[] getByteFromCoordinate(DNCWorkCoordinate coordinate)
focal_class.identifier: getByteFromCoordinate
focal_class.modifiers: public
focal_class.parameters: (DNCWorkCoordinate coordinate)
focal_class.return: byte[]
focal_class.signature: byte[] getByteFromCoordinate(DNCWorkCoordinate coordinate)
focal_class.class_method_signature: DNCWorkUnitDao.getObjectFromCoordinate(DNCWorkCoordinate coordinate)
focal_class.full_signature: private Object getObjectFromCoordinate(DNCWorkCoordinate coordinate)
focal_class.identifier: getObjectFromCoordinate
focal_class.modifiers: private
focal_class.parameters: (DNCWorkCoordinate coordinate)
focal_class.return: Object
focal_class.signature: Object getObjectFromCoordinate(DNCWorkCoordinate coordinate)
focal_class.class_method_signature: DNCWorkUnitDao.saveConvertedText(DNCWorkCoordinate coordinate, String processedText)
focal_class.full_signature: public void saveConvertedText(DNCWorkCoordinate coordinate, String processedText)
focal_class.identifier: saveConvertedText
focal_class.modifiers: public
focal_class.parameters: (DNCWorkCoordinate coordinate, String processedText)
focal_class.return: void
focal_class.signature: void saveConvertedText(DNCWorkCoordinate coordinate, String processedText)
focal_class.superclass: extends BaseDao
focal_method.body: public void saveConvertedText(DNCWorkCoordinate coordinate, String processedText) {
          SessionWrapper sessionWrapper = getCurrentTargetSession();
          try {
              Query query = sessionWrapper.getNamedQuery("saveTextToCoordinate");
              String queryString = query.getQueryString();
              SQLQuery sqlQuery = sessionWrapper.createSQLQuery(queryString);
              sqlQuery.setParameter(0, coordinate.getSourceTable());
              sqlQuery.setParameter(1, coordinate.getSourceColumn());
              sqlQuery.setParameter(2, coordinate.getIdInSourceTable());
              sqlQuery.setParameter(3, processedText);
              sqlQuery.executeUpdate();
          } finally {
              sessionWrapper.closeSession();
          }
      }
focal_method.class_method_signature: DNCWorkUnitDao.saveConvertedText(DNCWorkCoordinate coordinate, String processedText)
focal_method.full_signature: public void saveConvertedText(DNCWorkCoordinate coordinate, String processedText)
focal_method.identifier: saveConvertedText
focal_method.invocations: getCurrentTargetSession getNamedQuery getQueryString createSQLQuery setParameter getSourceTable setParameter getSourceColumn setParameter getIdInSourceTable setParameter executeUpdate closeSession
focal_method.modifiers: public
focal_method.parameters: (DNCWorkCoordinate coordinate, String processedText)
focal_method.return: void
focal_method.signature: void saveConvertedText(DNCWorkCoordinate coordinate, String processedText)