} else if ("nonNegativeInteger".equals(attributeType)) {
returnObject = new NonNegativeInteger(attribValue);
} else if ("nonPositiveInteger".equals(attributeType)) {
returnObject = new NonPositiveInteger(attribValue);
} else {
throw new ADBException("Unknown type ==> " + attributeType);
}
} else {
throw new ADBException("Attribute value is null");
}
}
} else {
try {
Method getObjectMethod = extensionMapperClass.getMethod("getTypeObject",
new Class[]{String.class, String.class, XMLStreamReader.class});
returnObject = getObjectMethod.invoke(null,
new Object[]{attributeNameSpace, attributeType, xmlStreamReader});
} catch (NoSuchMethodException e) {
throw new ADBException("Can not find the getTypeObject method in the " +
"extension mapper class ", e);
} catch (IllegalAccessException e) {
throw new ADBException("Can not access the getTypeObject method in the " +
"extension mapper class ", e);
} catch (InvocationTargetException e) {
throw new ADBException("Can not invoke the getTypeObject method in the " +
"extension mapper class ", e);
}
}
} else {
throw new ADBException("Any type element type has not been given");
}
}
return returnObject;
}