if (sparse == null) {
sparse = position != null;
}
// nested element names can specify a type
AegisType compType = getTypeMapping().getType(creader.getName());
if (compType == null) {
// use the type declared in the arrayType attribute
compType = arrayTypeInfo.getType();
}
// check for an xsi:type override
compType = TypeUtil.getReadType(creader.getXMLStreamReader(),
context.getGlobalContext(), compType);
// wrap type with soap ref to handle hrefs
compType = new SoapRefType(compType);
// read the value
Object value;
if (creader.isXsiNil()) {
value = null;
creader.readToEnd();
} else {
value = compType.readObject(creader, context);
}
// add the value
if (!sparse) {
if (values.size() + 1 > maxSize) {