Class StaticFormTheme.FormThemeFileMeta.Builder

java.lang.Object
de.xima.fc.common.form_theme.StaticFormTheme.FormThemeFileMeta.Builder
Enclosing class:
StaticFormTheme.FormThemeFileMeta

public static final class StaticFormTheme.FormThemeFileMeta.Builder extends Object
A builder for configuring the metadata of a file in a form theme.
Since:
8.3.0
Author:
XIMA MEDIA GmbH
  • Method Details

    • build

      Creates a new metadata instance for a file in a form theme with the current configuration. Subsequent changes to the builder do not affect the returned metadata instance.
      Returns:
      A new metadata instance for a file in a form theme.
    • content

      Sets the content of the form theme file, see IFormTheme#openFile. Overrides any previously set content or fileLoader. Uses the UTF-8 charset for encoding the content.
      Parameters:
      content - The content of the form theme file.
      Returns:
      This builder for chaining method calls.
    • content

      public StaticFormTheme.FormThemeFileMeta.Builder content(String content, Charset charset)
      Sets the content of the form theme file, see IFormTheme#openFile. Overrides any previously set content or fileLoader.
      Parameters:
      content - The content of the form theme file.
      charset - The charset for encoding the content.
      Returns:
      This builder for chaining method calls.
    • content

      public StaticFormTheme.FormThemeFileMeta.Builder content(byte[] content)
      Sets the content of the form theme file, see IFormTheme#openFile. Overrides any previously set content or fileLoader.
      Parameters:
      content - The content of the form theme file.
      Returns:
      This builder for chaining method calls.
    • fileLoader

      Sets the file loader for retrieving the content of the form theme file, see IFormTheme#openFile. Overrides any previously set content or file loader.
      Parameters:
      fileLoader - The file loader for the form theme file.
      Returns:
      This builder for chaining method calls.
    • inheritanceMode

      Sets the inheritance mode for the form theme file, see IFormTheme#getFileInheritanceMode. Overrides any previously set inheritance mode.
      Parameters:
      inheritanceMode - The inheritance mode for the form theme file.
      Returns:
      This builder for chaining method calls.
    • offerCssClassesAsSuggestions

      public StaticFormTheme.FormThemeFileMeta.Builder offerCssClassesAsSuggestions()
      Indicates that CSS classes of the form theme file should be offered as suggestions in the form designer. Users can add custom CSS classes to a form element. When this option is enabled, the form designer offers the CSS classes of the form theme file as suggestions. Overrides any previously set value.
      Returns:
      This builder for chaining method calls.
    • offerCssClassesAsSuggestions

      public StaticFormTheme.FormThemeFileMeta.Builder offerCssClassesAsSuggestions(boolean offerCssClassesAsSuggestions)
      Sets whether the CSS classes of the form theme file should be offered as suggestions in the form designer. Users can add custom CSS classes to a form element. When this option is enabled, the form designer offers the CSS classes of the form theme file as suggestions. Overrides any previously set value.
      Parameters:
      offerCssClassesAsSuggestions - Whether the CSS classes should be offered as suggestions.
      Returns:
      This builder for chaining method calls.