Package org.cipres.treebase.domain.matrix

Examples of org.cipres.treebase.domain.matrix.MatrixService


      SearchType searchType,
      BindException errors,
      String searchTerm) throws InstantiationException {

    Collection<Matrix> matches = null;
    MatrixService matrixService = getSearchService().getMatrixService()

    switch(searchType) {
    case byID:
      matches = (Collection<Matrix>) doSearchByIDString(request, matrixService, Matrix.class, searchTerm);
      break;
   
    case byTB1ID:
      matches = new HashSet<Matrix>();
      matches.add(matrixService.findByTB1StudyID(searchTerm));
      break;
     
    case byTitle:
      matches = matrixService
        .findSomethingBySubstring(Matrix.class, "title", searchTerm);
      break;

    case byType:
      matches = matrixService
        .findSomethingByItsDescription(Matrix.class, "matrixKind", searchTerm, false);
      break;

    case byNCHAR:
      try {
        matches = matrixService
        .findSomethingByRangeExpression(CharacterMatrix.class, "nChar", searchTerm);
      } catch (MalformedRangeExpression e) {
        addMessage(request, "Malformed range expression: " + e.getMessage());
      }
      break;


    case byNTAX:
      try {
        matches = matrixService
        .findSomethingByRangeExpression(CharacterMatrix.class, "nTax", searchTerm);
      } catch (MalformedRangeExpression e) {
        addMessage(request, "Malformed range expression: " + e.getMessage());
      }
      break;
View Full Code Here

TOP

Related Classes of org.cipres.treebase.domain.matrix.MatrixService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.