for (FObj node : this.getChildren()) {
if (node instanceof ColorProfile) {
this.colorProfiles[colorProfileCount] = (ColorProfile) node;
colorProfileCount ++;
} else if (node instanceof Metadata) {
final Metadata metadata = (Metadata) node;
final String key = metadata.getMetadataName();
/* Does it already exist? */
final Metadata existingMetadata = this.metadata.get(key);
if (existingMetadata != null) {
throwException("fo:metadata for \"" + key
+ "\" cannot be declared more than once.");
}
this.metadata.put(key, metadata);