Package de.xima.fc.form.export
Class FormExporter
java.lang.Object
de.xima.fc.form.export.FormExporter
Exporter for creating documents from formcycle forms
- Author:
- XIMA MEDIA GmbH
-
Constructor Summary
ConstructorsConstructorDescriptionFormExporter(com.alibaba.fastjson.JSONObject persist, IXFormRenderConfig renderConfig) -
Method Summary
Modifier and TypeMethodDescriptionbyte[]doExport()Creates a document for the configured formwithExcludeImages(boolean excludeImages) Sets whether or not to exclude images in exported documentwithFormat(EFormPrintFormat format) withKeepPlaceholder(boolean keepPlaceholder) withLocale(Locale locale) Sets the default editing language for the created document.withTemplate(ERessourcenTyp resourceType, UUID resourceUUID) Sets the template that should be used via its resource type (client or project) and UUID
-
Constructor Details
-
FormExporter
- Parameters:
persist- Persist with the data of the form to export.renderConfig- Render config to use for exporting.
-
-
Method Details
-
withFormat
- Parameters:
format-EFormPrintFormatexport format- Returns:
FormExporterfor fluent API
-
withKeepPlaceholder
- Parameters:
keepPlaceholder- Whether placeholders in form field properties are replaced.- Returns:
FormExporterfor fluent API
-
withTemplate
Sets the template that should be used via its resource type (client or project) and UUID- Parameters:
resourceType-ERessourcenTypclient or project resourceresourceUUID-UUIDof the resource- Returns:
FormExporterfor fluent API
-
withLocale
Sets the default editing language for the created document.- Parameters:
locale- Locale to set.- Returns:
FormExporterfor fluent API
-
withExcludeImages
Sets whether or not to exclude images in exported document- Parameters:
excludeImages-BooleanexcludeXImagein the exported form- Returns:
FormExporterfor fluent API
-
doExport
public byte[] doExport()Creates a document for the configured form- Returns:
- byte array of the exported form document
-