Record Class LineStyle
java.lang.Object
java.lang.Record
io.leandev.appfuse.report.node.LineStyle
- Record Components:
width- 線寬color- 顏色dashPattern- 交替的線段與空白長度;空清單為實線,奇數個元素重複兩次形成週期dashPhase- 週期起點偏移;預設 0,實線必須為 0
-
Constructor Summary
ConstructorsConstructorDescriptionLineStyle(Length width, ReportColor color) 保留既有雙參數建構器,預設實線。Creates an instance of aLineStylerecord class. -
Method Summary
Modifier and TypeMethodDescriptioncolor()Returns the value of thecolorrecord component.dashed()Returns the value of thedashPatternrecord component.Returns the value of thedashPhaserecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.solid()final StringtoString()Returns a string representation of this record class.width()Returns the value of thewidthrecord component.長度均以 Length 指定,renderer 轉換為 PDF pt(1/72 inch);不是線寬倍數。 phase 可大於週期,由 PDF 依週期循環;空 pattern 只接受零 phase。
-
Constructor Details
-
LineStyle
保留既有雙參數建構器,預設實線。 -
LineStyle
Creates an instance of aLineStylerecord class.- Parameters:
width- the value for thewidthrecord componentcolor- the value for thecolorrecord componentdashPattern- the value for thedashPatternrecord componentdashPhase- the value for thedashPhaserecord component
-
-
Method Details
-
withDash
-
dashed
- Returns:
- 2pt 線段、2pt 空白、零 phase 的虛線
-
solid
- Returns:
- 相同線寬與顏色的實線
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
width
-
color
-
dashPattern
Returns the value of thedashPatternrecord component.- Returns:
- the value of the
dashPatternrecord component
-
dashPhase
-