Interface IExportTemplateFactory

All Known Implementing Classes:
BaseTemplateFactory

public interface IExportTemplateFactory
The factory for templates for an exporter. This factory is used by the export manager to create export templates from repository files, but it can also be used directly by clients that want to use a custom template for particular export.
Since:
3.17.1
  • Method Details

    • createRepositoryTemplate

      @NotNull IExportTemplate createRepositoryTemplate(@NotNull ILocation location)
      Creates a template from a location in the repository. (It is used by the export manager to create templates).
    • createCustomTemplate

      @NotNull IExportTemplate createCustomTemplate(@NotNull Supplier<InputStream> contentSupplier, @Nullable String label)
      Creates custom templates. Custom template are not stored in the repository and are managed by the export manager with the given content and label.
      Throws:
      UnsupportedOperationException - if this factory does not support the creation of custom templates. (This only happens with legacy exporters that do not provide their own template factory, but still use custom templates. See ITemplateExportCommandFactory)
    • getDefaultTemplate

      @Nullable IExportTemplate getDefaultTemplate(@NotNull IExportConfiguration configuration)
      Returns the default template that would be used by the corresponding exporter with the particular export configuration, if it does not specify the template. (i.e. if configuration.getTemplate() == null). This might be useful, for example, for export configuration preprocessors. See IExportConfigurationPreprocessor.