use of org.xwiki.wiki.internal.descriptor.builder.WikiDescriptorBuilderException in project xwiki-platform by xwiki.
the class DefaultWikiCreator method createDescriptor.
private WikiDescriptor createDescriptor(String wikiId, String wikiAlias) throws WikiManagerException {
// Create the descriptor
WikiDescriptor descriptor = new DefaultWikiDescriptor(wikiId, wikiAlias);
try {
// Build the document
wikiDescriptorBuilder.save(descriptor);
// Reload the descriptor from the cache because it should have been seen by the DescriptorListener.
descriptor = wikiDescriptorManager.getById(wikiId);
} catch (WikiDescriptorBuilderException e) {
throw new WikiManagerException("Failed to build the descriptor document.", e);
}
return descriptor;
}
Aggregations