}
List<ZNRecord> children = _baseDataAccessor.get(paths, null, 0);
// check if bucketized
for (int i = 0; i < keys.size(); i++) {
PropertyKey key = keys.get(i);
ZNRecord record = children.get(i);
PropertyType type = key.getType();
String path = key.getPath();
int options = constructOptions(type);
// ZNRecord record = null;
switch (type) {
case RESOURCEASSIGNMENTS:
case CURRENTSTATES:
case IDEALSTATES:
case EXTERNALVIEW:
// check if bucketized
if (record != null) {
HelixProperty property = new HelixProperty(record);
int bucketSize = property.getBucketSize();
if (bucketSize > 0) {
List<ZNRecord> childRecords = _baseDataAccessor.getChildren(path, null, options);
ZNRecord assembledRecord = new ZNRecordAssembler().assemble(childRecords);
// merge with parent node value
if (assembledRecord != null) {
record.getSimpleFields().putAll(assembledRecord.getSimpleFields());
record.getListFields().putAll(assembledRecord.getListFields());
record.getMapFields().putAll(assembledRecord.getMapFields());
}
}
}
break;
default:
break;
}
@SuppressWarnings("unchecked")
T t = (T) HelixProperty.convertToTypedInstance(key.getTypeClass(), record);
childValues.add(t);
}
return childValues;
}