Class Paragraph

  • All Implemented Interfaces:
    Adaptable, Resource

    public class Paragraph
    extends ResourceWrapper
    Provides an abstraction of paragraph within a paragraph system.
    • Method Detail

      • getType

        public Paragraph.Type getType()
        Returns the type of this paragraph
        Returns:
        type of this paragraph
      • getColNr

        public int getColNr()
        Returns the columns number of this paragraph. Note that Paragraph.Type.BREAK and Paragraph.Type.END paragraphs have the number of the next columns.
        Returns:
        the columns number of this paragraph.
      • getNumCols

        public int getNumCols()
        Returns the total number of columns of the column group this paragraph is in.
        Returns:
        the total number of columns.
      • getBaseCssClass

        public java.lang.String getBaseCssClass()
        Returns the css class of this paragraph.
        Returns:
        the CSS class
      • getCssClass

        public java.lang.String getCssClass()
        Returns the auto generated css class for the column of this paragraph.
        Returns:
        the CSS class
      • setDiffInfo

        public void setDiffInfo​(DiffInfo di)
        Set the diff information for this paragraph.
        Parameters:
        di - The diff information
      • adaptTo

        public <AdapterType> AdapterType adaptTo​(java.lang.Class<AdapterType> type)
        Returns the value of calling adaptTo on the wrapped resource.
        Specified by:
        adaptTo in interface Adaptable
        Overrides:
        adaptTo in class ResourceWrapper
        Type Parameters:
        AdapterType - The generic type to which this object is adapted to
        Parameters:
        type - The Class object of the target type, such as javax.jcr.Node.class or java.io.File.class
        Returns:
        The adapter target or null if the object cannot adapt to the requested type
      • toString

        public java.lang.String toString()
        Returns a human readable string representation of this resource.
        Overrides:
        toString in class ResourceWrapper