@Override @Deprecated @PotentialThreat( description = "Labels are not unique in the database, so you could " + "get more than one result and this method would fail" ) public T getByShortLabel( String value ) { return super.getByShortLabel( value ); }
@PotentialThreat( description = "This method is using raw SQL (DELETE Query), which may create problems " + "when run with hibernate", origin = "This code is used in a EventListener, so the session cannot be committed and we" + "need a workaroung" ) public void delete( SearchItem searchItem ) { String sql = "DELETE from ia_search WHERE ac=? AND value=? AND objclass=? AND type=?"; executeQueryUpdateForSearchItem( sql, searchItem ); }
@PotentialThreat( description = "This method is using raw SQL (INSERT Query), which may create problems " + "when run with hibernate", origin = "This code is used in a EventListener, so the session cannot be committed and we" + "need a workaroung" ) public void persist( SearchItem searchItem ) { String sql = "INSERT INTO ia_search (ac,value,objclass,type) VALUES (?,?,?,?)"; executeQueryUpdateForSearchItem( sql, searchItem ); }
@Override @Deprecated @PotentialThreat( description = "Labels are not unique in the database, so you could " + "get more than one result and this method would fail" ) public T getByShortLabel( String value ) { return super.getByShortLabel( value ); }
@Override @Deprecated @PotentialThreat( description = "Labels are not unique in the database, so you could " + "get more than one result and this method would fail" ) public T getByShortLabel( String value ) { return super.getByShortLabel( value ); }
@PotentialThreat( description = "This method is using raw SQL (DELETE Query), which may create problems " + "when run with hibernate", origin = "This code is used in a EventListener, so the session cannot be committed and we" + "need a workaroung" ) public int deleteByAc( String ac ) { String sql = "DELETE FROM ia_search WHERE ac=?"; int rows = 0; Connection connection = null; try { connection = getSession().connection(); PreparedStatement statement = connection.prepareStatement( sql ); statement.setString( 1, ac ); rows = statement.executeUpdate(); } catch ( SQLException e ) { e.printStackTrace(); } finally { if ( connection != null ) { try { connection.close(); } catch ( SQLException e ) { e.printStackTrace(); } } } return rows; }
@PotentialThreat(description = "Contains direct SQL code, including Alias and Xref references") public Collection<BioSourceSearchObject> getAllBioSources( String sqlQuery ) throws IntactException {
@PotentialThreat(description = "Contains direct SQL, including usage of Xref and Alias related tables") public Collection<CvSearchObject> getAllCvObjects( String sqlQuery ) throws IntactException {
@PotentialThreat( description = "Contains direct SQL code, including Alias and Xref references" ) public Collection<BioSourceSearchObject> getAllBioSources( String sqlQuery ) throws IntactException {
@PotentialThreat( description = "Contains direct SQL, including usage of Xref and Alias related tables" ) public Collection<CvSearchObject> getAllCvObjects( String sqlQuery ) throws IntactException {
@PotentialThreat(description = "Contains direct SQL, including usage of Xref and Alias related tables") public Collection<ProteinSearchObject> getAllProteins( String sqlQuery ) throws IntactException {
@PotentialThreat( description = "Contains direct SQL, including usage of Xref and Alias related tables" ) public Collection<ProteinSearchObject> getAllProteins( String sqlQuery ) throws IntactException {
@PotentialThreat(description = "Contains direct SQL, including usage of Xref and Alias related tables") public Collection<InteractionSearchObject> getAllInteractions( String sqlQuery ) throws IntactException {
@PotentialThreat( description = "Contains direct SQL, including usage of Xref and Alias related tables" ) public Collection<InteractionSearchObject> getAllInteractions( String sqlQuery ) throws IntactException {
@PotentialThreat(description = "Contains direct SQL, including usage of Xref and Alias related tables") public Collection<ExperimentSearchObject> getAllExperiments( String sqlQuery ) throws IntactException {
@PotentialThreat( description = "Contains direct SQL, including usage of Xref and Alias related tables" ) public Collection<ExperimentSearchObject> getAllExperiments( String sqlQuery ) throws IntactException {