ExpressionExperimentController { public Collection<ExpressionExperimentDetailsValueObject> loadStatusSummaries( Long taxonId, List<Long> ids, Integer limit, Integer filter, Boolean showPublic ) { StopWatch timer = new StopWatch(); timer.start(); Collection<ExpressionExperimentDetailsValueObject> vos; if ( !SecurityUtil.isUserLoggedIn() ) { throw new AccessDeniedException( "User does not have access to experiment management" ); } if ( limit == null ) { limit = 50; } vos = this.getEEVOsForManager( taxonId, ids, limit, filter, showPublic ); if ( vos.isEmpty() ) { return new HashSet<>(); } if ( timer.getTime() > 1000 ) { ExpressionExperimentController.log.info( "Fetching basic data took: " + timer.getTime() + "ms" ); } timer.reset(); timer.start(); expressionExperimentReportService.getAnnotationInformation( vos ); expressionExperimentReportService.populateEventInformation( vos ); if ( timer.getTime() > 1000 ) { ExpressionExperimentController.log .info( "Filling in report data for " + vos.size() + " EEs: " + timer.getTime() + "ms" ); } for ( ExpressionExperimentDetailsValueObject vo : vos ) { vo.setArrayDesigns( arrayDesignService.loadValueObjectsForEE( vo.getId() ) ); } return vos; }  JsonReaderResponse<ExpressionExperimentDetailsValueObject> browse( ListBatchCommand batch ); JsonReaderResponse<ExpressionExperimentDetailsValueObject> browseByTaxon( ListBatchCommand batch,
            Long taxonId ); JsonReaderResponse<ExpressionExperimentDetailsValueObject> browseSpecificIds( ListBatchCommand batch,
            Collection<Long> ids ); boolean canCurrentUserEditExperiment( Long eeId ); void clearFromCaches( Long eeId ); String deleteById( Long id ); boolean doesCurrentUserOwnExperiment( Long eeId ); @RequestMapping("/filterExpressionExperiments.html") ModelAndView filter( HttpServletRequest request, HttpServletResponse response ); Collection<Long> find( String query, Long taxonId ); List<SearchResultDisplayObject> getAllTaxonExperimentGroup( Long taxonId ); Collection<AnnotationValueObject> getAnnotation( EntityDelegator e ); String getDescription( Long id ); Collection<DesignMatrixRowValueObject> getDesignMatrixRows( EntityDelegator e ); Collection<ExperimentalFactorValueObject> getExperimentalFactors( EntityDelegator e ); Collection<FactorValueValueObject> getFactorValues( EntityDelegator e ); String getQCTagHTML( ExpressionExperiment ee ); JSONObject loadCountsForDataSummaryTable(); ExpressionExperimentDetailsValueObject loadExpressionExperimentDetails( Long id ); void recalculateBatchConfound( Long id ); void recalculateBatchEffect( Long id ); void runGeeq( Long id, String mode ); void setGeeqManualSettings( long id, GeeqAdminValueObject vo ); Collection<ExpressionExperimentDetailsValueObject> loadExpressionExperiments( List<Long> ids ); Collection<ExpressionExperimentDetailsValueObject> loadExperimentsForPlatform( Long id ); Collection<ExpressionExperimentDetailsValueObject> loadDetailedExpressionExperiments(
            Collection<Long> ids ); JsonReaderResponse<JSONObject> loadExpressionExperimentsWithQcIssues(); Collection<QuantitationTypeValueObject> loadQuantitationTypes( Long eeId ); Collection<ExpressionExperimentDetailsValueObject> loadStatusSummaries( Long taxonId, List<Long> ids,
            Integer limit, Integer filter, Boolean showPublic ); @SuppressWarnings("UnusedReturnValue") // AJAX method - Possibly used in JS String removePrimaryPublication( Long eeId ); List<SearchResultDisplayObject> searchExperimentsAndExperimentGroups( String query, Long taxonId ); Collection<ExpressionExperimentValueObject> searchExpressionExperiments( String query ); @RequestMapping(value = { "/showAllExpressionExperiments.html", "/showAll" }) ModelAndView showAllExpressionExperiments( HttpServletRequest request, HttpServletResponse response ); @RequestMapping(value = { "/showAllExpressionExperimentLinkSummaries.html", "/manage.html" }) ModelAndView showAllLinkSummaries( HttpServletRequest request, HttpServletResponse response ); @RequestMapping(value = { "/showBioAssaysFromExpressionExperiment.html", "/bioAssays" }) ModelAndView showBioAssays( HttpServletRequest request, HttpServletResponse response ); @RequestMapping(value = { "/showBioMaterialsFromExpressionExperiment.html", "/bioMaterials" }) ModelAndView showBioMaterials( HttpServletRequest request, HttpServletResponse response ); @RequestMapping({ "/showExpressionExperiment.html", "/", "/show" }) ModelAndView showExpressionExperiment( HttpServletRequest request, HttpServletResponse response ); @RequestMapping(value = { "/showExpressionExperimentSubSet.html", "/showSubset" }) ModelAndView showSubSet( HttpServletRequest request, HttpServletResponse response ); void unmatchAllBioAssays( Long eeId ); ExpressionExperimentDetailsValueObject updateBasics( UpdateEEDetailsCommand command ); @SuppressWarnings("UnusedReturnValue") // AJAX method - possibly used in JS String updatePubMed( Long eeId, String pubmedId );  }
@Test public void testLoadStatusSummariesLimit() { List<Long> ids = new ArrayList<>(); int limit; ExpressionExperiment lastUpdated = null; for ( int i = 0; i < 2; i++ ) { ExpressionExperiment ee = this.getTestPersistentCompleteExpressionExperiment( false ); if ( lastUpdated == null || lastUpdated.getCurationDetails().getLastUpdated() .before( ee.getCurationDetails().getLastUpdated() ) ) { lastUpdated = ee; } ids.add( ee.getId() ); } limit = 1; Collection<ExpressionExperimentDetailsValueObject> ret = eeController .loadStatusSummaries( -1L, ids, limit, null, true ); assertEquals( 1, ret.size() ); ExpressionExperimentDetailsValueObject out = ret.iterator().next(); assertEquals( lastUpdated.getId(), out.getId() ); }