- /**
- * Gets the score model for the given name. If the score model is one that
- * requires to get state data from the current view, allow it to do so
- *
- * @param sm
- * @return
- */
- protected ScoreModelI configureScoreModel(String modelName)
- {
- ScoreModelI sm = ScoreModels.getInstance().forName(modelName);
- if (sm instanceof ViewBasedAnalysisI)
- {
- try
- {
- sm = sm.getClass().newInstance();
- ((ViewBasedAnalysisI) sm).configureFromAlignmentView(treeCanvas.ap);
- } catch (Exception q)
- {
- Cache.log.error("Couldn't create a scoremodel instance for "
- + sm.getName());
- }
- }
- return sm;
- }
-