return symbol;
}
/** Internal parse method - made protected for unit testing */
protected ShadedRelief parseShadedRelief(Node root) {
ShadedRelief symbol = new ShadedReliefImpl();
NodeList children = root.getChildNodes();
final int length = children.getLength();
for (int i = 0; i < length; i++) {
Node child = children.item(i);
if ((child == null) || (child.getNodeType() != Node.ELEMENT_NODE)) {
continue;
}
String childName = child.getLocalName();
if (childName == null) {
childName = child.getNodeName();
}
if ("BrightnessOnly".equalsIgnoreCase(childName)) {
symbol.setBrightnessOnly(Boolean
.getBoolean(getFirstChildValue(child)));
} else if ("ReliefFactor".equalsIgnoreCase(childName)) {
try {
final String reliefString = getFirstChildValue(child);
Expression relief = ExpressionDOMParser
.parseExpression(child);
symbol.setReliefFactor(relief);
} catch (Exception e) {
if (LOGGER.isLoggable(Level.WARNING))
LOGGER.log(Level.WARNING, e.getLocalizedMessage(), e);
}
}