use of org.structr.schema.parser.DoublePropertyParser in project structr by structr.
the class StructrNumberProperty method deserialize.
@Override
void deserialize(final SchemaProperty property) {
super.deserialize(property);
final DoublePropertyParser doublePropertyParser = property.getDoublePropertyParser();
if (doublePropertyParser != null) {
this.exclusiveMinimum = doublePropertyParser.isLowerExclusive();
this.exclusiveMaximum = doublePropertyParser.isUpperExclusive();
final Number min = doublePropertyParser.getLowerBound();
if (min != null) {
this.minimum = min.doubleValue();
}
final Number max = doublePropertyParser.getUpperBound();
if (max != null) {
this.maximum = max.doubleValue();
}
}
}
use of org.structr.schema.parser.DoublePropertyParser in project structr by structr.
the class SchemaProperty method getDoublePropertyParser.
public DoublePropertyParser getDoublePropertyParser() {
if (doublePropertyParser == null) {
try {
doublePropertyParser = new DoublePropertyParser(new ErrorBuffer(), getName(), this);
doublePropertyParser.getPropertySource(new StringBuilder(), getProperty(SchemaProperty.schemaNode));
} catch (FrameworkException fex) {
logger.warn("", fex);
}
}
return doublePropertyParser;
}
Aggregations