2 * Copyright (C) 2017 EDIT
3 * European Distributed Institute of Taxonomy
4 * http://www.e-taxonomy.eu
6 * The contents of this file are subject to the Mozilla Public License Version 1.1
7 * See LICENSE.TXT at the top of this package for the full license terms.
9 package eu
.etaxonomy
.taxeditor
.editor
.descriptiveDataSet
.matrix
.quantitative
;
11 import org
.eclipse
.nebula
.widgets
.nattable
.data
.convert
.DisplayConverter
;
13 import eu
.etaxonomy
.cdm
.model
.description
.QuantitativeData
;
14 import eu
.etaxonomy
.taxeditor
.editor
.descriptiveDataSet
.matrix
.MatrixUtility
;
17 * Converts QuantitativeData of one cell of the character matrix to a String.
23 public class QuantitativeDataNormalModeDisplayConverter
extends DisplayConverter
{
26 public Object
canonicalToDisplayValue(Object canonicalValue
) {
27 if(canonicalValue
instanceof QuantitativeData
){
28 return MatrixUtility
.getQuantitativeLabel((QuantitativeData
) canonicalValue
);
30 if(canonicalValue
!=null){
31 return canonicalValue
.toString();
37 public Object
displayToCanonicalValue(Object displayValue
) {