Class LineDashPatternSpec

java.lang.Object
com.helger.pdflayout.spec.LineDashPatternSpec
All Implemented Interfaces:
Serializable

@MustImplementEqualsAndHashcode public class LineDashPatternSpec extends Object implements Serializable
Different dashed line times
Author:
Philip Helger
See Also:
  • Field Details

  • Constructor Details

    • LineDashPatternSpec

      public LineDashPatternSpec()
    • LineDashPatternSpec

      public LineDashPatternSpec(@Nonnegative float fPattern)
    • LineDashPatternSpec

      public LineDashPatternSpec(@Nonnegative float fPatternOn, @Nonnegative float fPatternOff)
    • LineDashPatternSpec

      public LineDashPatternSpec(@Nonnull float[] aPattern, float fPhase)
      Parameters:
      aPattern - The pattern array. May not be null. Must have 0-2 items. 0 items means solid line, 1 item means identical on and off length and 2 items means potentially different on and off length. All contains values must be > 0.
      fPhase - The phase of the pattern. Where to start the painting, first counting on than off.
  • Method Details

    • getPattern

      @Nonnull @ReturnsMutableCopy public final float[] getPattern()
      Returns:
      A copy with all patterns. 0-2 elements.
    • getPatternCOSArray

      @Nonnull @ReturnsMutableCopy public final org.apache.pdfbox.cos.COSArray getPatternCOSArray()
      Returns:
      A COS array with 0-2 elements. Never null.
    • getPhase

      public final float getPhase()
      Returns:
      The phase to use.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object