use of ubic.gemma.core.analysis.sequence.CompositeSequenceMapValueObject in project Gemma by PavlidisLab.
the class CompositeSequenceController method filter.
@RequestMapping("/filter")
public ModelAndView filter(HttpServletRequest request, HttpServletResponse response) {
String filter = request.getParameter("filter");
String arid = request.getParameter("arid");
ModelAndView mav = new ModelAndView("compositeSequences.geneMap");
// Validate the filtering search criteria.
if (StringUtils.isBlank(filter)) {
mav.getModel().put("message", "No search critera provided");
// return showAll( request, response );
} else {
Collection<CompositeSequenceMapValueObject> compositeSequenceSummary = search(filter, arid);
if ((compositeSequenceSummary == null) || (compositeSequenceSummary.size() == 0)) {
mav.getModel().put("message", "Your search yielded no results");
compositeSequenceSummary = new ArrayList<>();
} else {
mav.getModel().put("message", compositeSequenceSummary.size() + " probes matched your search.");
}
mav.addObject("arrayDesign", loadArrayDesign(arid));
mav.addObject("sequenceData", compositeSequenceSummary);
mav.addObject("numCompositeSequences", compositeSequenceSummary.size());
}
return mav;
}
use of ubic.gemma.core.analysis.sequence.CompositeSequenceMapValueObject in project Gemma by PavlidisLab.
the class ArrayDesignControllerImpl method showCompositeSequences.
@Override
@RequestMapping("/showCompositeSequenceSummary.html")
public ModelAndView showCompositeSequences(HttpServletRequest request) {
String arrayDesignIdStr = request.getParameter("id");
if (arrayDesignIdStr == null) {
// should be a validation error, on 'submit'.
throw new EntityNotFoundException("Must provide a platform name or Id");
}
ArrayDesign arrayDesign = arrayDesignService.load(Long.parseLong(arrayDesignIdStr));
ModelAndView mav = new ModelAndView("compositeSequences.geneMap");
if (!AJAX) {
Collection<CompositeSequenceMapValueObject> compositeSequenceSummary = getDesignSummaries(arrayDesign);
if (compositeSequenceSummary == null || compositeSequenceSummary.size() == 0) {
throw new RuntimeException("No probes found for " + arrayDesign);
}
mav.addObject("sequenceData", compositeSequenceSummary);
mav.addObject("numCompositeSequences", compositeSequenceSummary.size());
}
mav.addObject("arrayDesign", arrayDesign);
return mav;
}
Aggregations