Create a way to list the IdentifierBundleFactories that are active.
This commit is contained in:
parent
0b8127ea11
commit
c3ba76acdc
1 changed files with 12 additions and 1 deletions
|
@ -51,6 +51,18 @@ public class ActiveIdentifierBundleFactories {
|
||||||
getActiveFactories(ctx).addFactory(factory);
|
getActiveFactories(ctx).addFactory(factory);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Just for diagnostics. Don't expose the factories themselves, only their names.
|
||||||
|
*/
|
||||||
|
public static List<String> getFactoryNames(ServletContext ctx) {
|
||||||
|
List<String> names = new ArrayList<String>();
|
||||||
|
ActiveIdentifierBundleFactories actFact = getActiveFactories(ctx);
|
||||||
|
for (IdentifierBundleFactory factory: actFact.factories) {
|
||||||
|
names.add(factory.toString());
|
||||||
|
}
|
||||||
|
return names;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the Identifiers from the list of factories. This might return an
|
* Get the Identifiers from the list of factories. This might return an
|
||||||
* empty bundle, but it never returns null.
|
* empty bundle, but it never returns null.
|
||||||
|
@ -118,5 +130,4 @@ public class ActiveIdentifierBundleFactories {
|
||||||
}
|
}
|
||||||
return ib;
|
return ib;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue