Class QuoteModule

All Implemented Interfaces:
Component

public class QuoteModule extends Module
Module for rendering emphasized quote/testimonial content.

Mutability and thread-safety: mutable and not thread-safe. Mutate within a request-scoped flow. For reuse, stop mutating shared instances and render stable structures with per-request context data.

  • Constructor Details

    • QuoteModule

      public QuoteModule()
  • Method Details

    • create

      public static QuoteModule create()
    • withTitle

      public QuoteModule withTitle(String title)
      Description copied from class: Module
      Sets optional title consumed by Module.buildContent() implementations.
      Overrides:
      withTitle in class Module
    • withModuleId

      public QuoteModule withModuleId(String moduleId)
      Description copied from class: Module
      Sets module id and synchronizes the underlying id attribute.
      Overrides:
      withModuleId in class Module
    • withQuote

      public QuoteModule withQuote(String quote)
      Sets the quote text.
      Parameters:
      quote - the quote content
    • withAuthor

      public QuoteModule withAuthor(String author)
      Sets the author of the quote.
      Parameters:
      author - the author name
    • withAttribution

      public QuoteModule withAttribution(String attribution)
      Sets additional attribution information (title, organization, etc.).
      Parameters:
      attribution - attribution details
    • withDate

      public QuoteModule withDate(String date)
      Sets the date of the quote.
      Parameters:
      date - the quote date
    • large

      public QuoteModule large()
      Makes the quote display in a larger size.
    • centered

      public QuoteModule centered()
      Centers the quote content.
    • buildContent

      protected void buildContent()
      Description copied from class: Module
      Composes module structure.

      Called at most once by Module.build() unless Module.rebuildContent() is invoked. Do not rely on this method for per-request mutation.

      Specified by:
      buildContent in class Module