Project

General

Profile

« Previous | Next » 

Revision 6a8d9d7f

Added by Patrick Plitzner about 6 years ago

ref #7095 Cache description elements in row wrapper for performance

View differences:

eu.etaxonomy.taxeditor.editor/src/main/java/eu/etaxonomy/taxeditor/editor/workingSet/matrix/categorical/CategoricalDataCellEditor.java
45 45
        if(canonicalValue==null){
46 46
            Object rowWrapper = matrix.getBodyDataProvider().getRowObject(this.getRowIndex());
47 47
            if(rowWrapper instanceof RowWrapper){
48
                CategoricalData data = CategoricalData.NewInstance(feature);
49
                ((RowWrapper) rowWrapper).getSpecimenDescription().addElement(data);
50
                canonicalValue = data;
48
                canonicalValue = ((RowWrapper) rowWrapper).addCategoricalData(feature);
51 49
            }
52 50
        }
53
        if (canonicalValue instanceof CategoricalData) {
51
        else if (canonicalValue instanceof CategoricalData) {
54 52
            CategoricalData data = (CategoricalData)canonicalValue;
55 53
            List<State> states = data.getStatesOnly();
56 54
            String[] result = new String[states.size()];

Also available in: Unified diff