public interface Snippet
Interface representing a snippet definition.
See the section 'Snippet' of the ODFS (online documentation - /help/odfs/template-develo/snippets/index.html) for further information.
Since:
5.2.9
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    @Nullable String
    Returns extract expression of this snippet.
    @Nullable String
    Returns header expression of this snippet.
    @Nullable String
    Returns expression for the thumbnail of this snippet used to request a medium
    void
    setExtract(@Nullable String extractExpression)
    Set the extract expression for this snippet.
    void
    setHeader(@Nullable String headerExpression)
    Set the header expression for this snippet.
    void
    setThumbnail(@Nullable String thumbNailExpression)
    Sets the expression for the thumbnail of this snippet.
  • Method Details

    • setThumbnail

      void setThumbnail(@Nullable @Nullable String thumbNailExpression)
      Sets the expression for the thumbnail of this snippet. The provided expression should evaluate to a medium reference.
      examples:
      • "mediumUid" (referenced by uid)
      • 'medium("mediumUid", "remoteProjectConfigName")' (reference to a remote medium)
      • 'st_picture' (identifier of form element)
      Since:
      5.2.9
      See Also:
    • getThumbnail

      @Nullable @Nullable String getThumbnail()
      Returns expression for the thumbnail of this snippet used to request a medium
      Since:
      5.2.9
      See Also:
    • setHeader

      void setHeader(@Nullable @Nullable String headerExpression)
      Set the header expression for this snippet. The header expression should evaluate to a short description of the related element. (e.g. title, headline)
      examples:
      • 'st_text' (name of a form element)
      Since:
      5.2.9
      See Also:
    • getHeader

      @Nullable @Nullable String getHeader()
      Returns header expression of this snippet.
      Since:
      5.2.9
      See Also:
    • setExtract

      void setExtract(@Nullable @Nullable String extractExpression)
      Set the extract expression for this snippet. The extract expression should evaluate to a longer content extract of the related element.
      examples:
      • 'st_dom.toText(false)' (content of a dom form element)
      Since:
      5.2.9
    • getExtract

      @Nullable @Nullable String getExtract()
      Returns extract expression of this snippet.
      Since:
      5.2.9