in SdmxStructureParser/src/main/java/org/sdmxsource/sdmx/structureparser/builder/xmlBeans/v2/AbstractBuilder.java [82:189]
void populateTextFormatType(TextFormatType textFormatType, TextFormatBean textFormat) {
if (textFormat.getTextType() != null) {
switch (textFormat.getTextType()) {
case BIG_INTEGER:
textFormatType.setTextType(TextTypeType.BIG_INTEGER);
break;
case BOOLEAN:
textFormatType.setTextType(TextTypeType.BOOLEAN);
break;
case COUNT:
textFormatType.setTextType(TextTypeType.COUNT);
break;
case DATE:
textFormatType.setTextType(TextTypeType.DATE);
break;
case DATE_TIME:
textFormatType.setTextType(TextTypeType.DATE_TIME);
break;
case DAY:
textFormatType.setTextType(TextTypeType.DAY);
break;
case DECIMAL:
textFormatType.setTextType(TextTypeType.DECIMAL);
break;
case DOUBLE:
textFormatType.setTextType(TextTypeType.DOUBLE);
break;
case DURATION:
textFormatType.setTextType(TextTypeType.DURATION);
break;
case EXCLUSIVE_VALUE_RANGE:
textFormatType.setTextType(TextTypeType.EXCLUSIVE_VALUE_RANGE);
break;
case FLOAT:
textFormatType.setTextType(TextTypeType.FLOAT);
break;
case INCLUSIVE_VALUE_RANGE:
textFormatType.setTextType(TextTypeType.INCLUSIVE_VALUE_RANGE);
break;
case INCREMENTAL:
textFormatType.setTextType(TextTypeType.INCREMENTAL);
break;
case INTEGER:
textFormatType.setTextType(TextTypeType.INTEGER);
break;
case LONG:
textFormatType.setTextType(TextTypeType.LONG);
break;
case MONTH:
textFormatType.setTextType(TextTypeType.MONTH);
break;
case MONTH_DAY:
textFormatType.setTextType(TextTypeType.MONTH_DAY);
break;
case OBSERVATIONAL_TIME_PERIOD:
textFormatType.setTextType(TextTypeType.OBSERVATIONAL_TIME_PERIOD);
break;
case SHORT:
textFormatType.setTextType(TextTypeType.SHORT);
break;
case STRING:
textFormatType.setTextType(TextTypeType.STRING);
break;
case TIME:
textFormatType.setTextType(TextTypeType.TIME);
break;
case TIMESPAN:
textFormatType.setTextType(TextTypeType.TIMESPAN);
break;
case URI:
textFormatType.setTextType(TextTypeType.URI);
break;
case YEAR:
textFormatType.setTextType(TextTypeType.YEAR);
break;
case YEAR_MONTH:
textFormatType.setTextType(TextTypeType.YEAR_MONTH);
break;
}
}
if (validString(textFormat.getPattern())) {
textFormatType.setPattern(textFormat.getPattern());
}
if (validString(textFormat.getTimeInterval())) {
textFormatType.setTimeInterval(new GDuration(textFormat.getTimeInterval()));
}
if (textFormat.getDecimals() != null) {
textFormatType.setDecimals(textFormat.getDecimals());
}
if (textFormat.getEndValue() != null) {
textFormatType.setEndValue(textFormat.getEndValue().doubleValue());
}
if (textFormat.getInterval() != null) {
textFormatType.setInterval(textFormat.getInterval().doubleValue());
}
if (textFormat.getMaxLength() != null) {
textFormatType.setMaxLength(textFormat.getMaxLength());
}
if (textFormat.getMinLength() != null) {
textFormatType.setMinLength(textFormat.getMinLength());
}
if (textFormat.getStartValue() != null) {
textFormatType.setStartValue(textFormat.getStartValue().doubleValue());
}
if (textFormat.getSequence().isSet()) {
textFormatType.setIsSequence(textFormat.getSequence().isTrue());
}
}