static void handleElementText(final XMLExtendedStreamReader reader, final Element element, final ModelNode node) throws XMLStreamException {
handleElementText(reader, element, null, node);
}
static void handleElementText(final XMLExtendedStreamReader reader, final Element element, final String modelName, final ModelNode node) throws XMLStreamException {
AttributeDefinition attributeDefinition = modelName == null ? element.getDefinition() : element.getDefinition(modelName);
if (attributeDefinition != null) {
Location location = reader.getLocation();
final String value = reader.getElementText();
if (attributeDefinition instanceof SimpleAttributeDefinition) {
((SimpleAttributeDefinition) attributeDefinition).parseAndSetParameter(value, node, location);