Package org.cipres.treebase.domain.tree

Examples of org.cipres.treebase.domain.tree.TreeType


        t.setLabel(label);
        t.setTitle(title);
       
        { // Map type -> treeType
          Collection<TreeType> tts = treeService.findSomethingByString(TreeType.class, "description", type);
          TreeType tt = null;
          if (tts.isEmpty()) {
            warn("Unknown TreeType '" + type + "'; skipping it");
/*            // Or you can manufacture a fresh one here, which is not normally allowed
*                      // Note that tt.setDescription is private, so you will have to make it public to use this code
*                      // 20090320 MJD
View Full Code Here


      logger.info("\n\t\tRunning Test: " + testName);
    }

    PhyloTreeHome fixture = getFixture();
    String desc = TreeType.TYPE_SINGLE;
    TreeType result = fixture.findTypeByDescription(desc);

    // verify
    assertTrue(result != null);
    assertTrue(result.isSingleTree());

    if (logger.isInfoEnabled()) {
      logger.info(testName + " verified.");
    }
  }
View Full Code Here

  public TreeType findTypeByDescription(String pDescription) {
    if (TreebaseUtil.isEmpty(pDescription)) {
      return null;
    }
   
    TreeType returnVal = null;

    Criteria c = getSession().createCriteria(TreeType.class).add(
      org.hibernate.criterion.Expression.eq("description", pDescription));

    returnVal = (TreeType) c.uniqueResult();
View Full Code Here

TOP

Related Classes of org.cipres.treebase.domain.tree.TreeType

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.