throws IllegalArgumentException {
validateRelationDefinition(parent, rd);
// Get the target entry.
DN targetDN = DNBuilder.create(parent, rd);
ConfigEntry configEntry;
try {
configEntry = DirectoryServer.getConfigEntry(targetDN);
} catch (ConfigException e) {
return new String[0];
}
if (configEntry == null) {
return new String[0];
}
// Retrieve the children.
Set<DN> children = configEntry.getChildren().keySet();
ArrayList<String> names = new ArrayList<String>(children.size());
for (DN child : children) {
// Assume that RDNs are single-valued and can be trimmed.
AttributeValue av = child.getRDN().getAttributeValue(0);
names.add(av.toString().trim());