segmentedtimeline.html
来自「JFreeChart的帮助文档」· HTML 代码 · 共 1,510 行 · 第 1/4 页
HTML
1,510 行
used to compute the included and excluded segments of the timeline.<DD><CODE>segmentsIncluded</CODE> - Number of consecutive segments to include.<DD><CODE>segmentsExcluded</CODE> - Number of consecutive segments to exclude.</DL><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="newMondayThroughFridayTimeline()"><!-- --></A><H3>newMondayThroughFridayTimeline</H3><PRE>public static <A HREF="../../../../org/jfree/chart/axis/SegmentedTimeline.html">SegmentedTimeline</A> <B>newMondayThroughFridayTimeline</B>()</PRE><DL><DD>Factory method to create a Monday through Friday SegmentedTimeline. <P> The <code>startTime</code> of the resulting timeline will be midnight of the firt Monday after 1/1/1900.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>A fully initialized SegmentedTimeline.</DL></DD></DL><HR><A NAME="newFifteenMinuteTimeline()"><!-- --></A><H3>newFifteenMinuteTimeline</H3><PRE>public static <A HREF="../../../../org/jfree/chart/axis/SegmentedTimeline.html">SegmentedTimeline</A> <B>newFifteenMinuteTimeline</B>()</PRE><DL><DD>Factory method to create a 15-min, 9:00 AM thought 4:00 PM, Monday through Friday SegmentedTimeline. <P> This timeline uses a segmentSize of FIFTEEN_MIN_SEGMENT_SIZE. The segment group is defined as 28 included segments (9:00 AM through 4:00 PM) and 68 excluded segments (4:00 PM through 9:00 AM the next day). <P> In order to exclude Saturdays and Sundays it uses a baseTimeline that only includes Monday through Friday days. <P> The <code>startTime</code> of the resulting timeline will be 9:00 AM after the startTime of the baseTimeline. This will correspond to 9:00 AM of the firt Monday after 1/1/1900.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>A fully initialized SegmentedTimeline.</DL></DD></DL><HR><A NAME="setStartTime(long)"><!-- --></A><H3>setStartTime</H3><PRE>public void <B>setStartTime</B>(long millisecond)</PRE><DL><DD>Sets the start time for the timeline. This is the beginning of segment zero.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>millisecond</CODE> - the start time (encoded as in java.util.Date).</DL></DD></DL><HR><A NAME="getStartTime()"><!-- --></A><H3>getStartTime</H3><PRE>public long <B>getStartTime</B>()</PRE><DL><DD>Returns the start time for the timeline. This is the beginning of segment zero.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The start time.</DL></DD></DL><HR><A NAME="getSegmentsExcluded()"><!-- --></A><H3>getSegmentsExcluded</H3><PRE>public int <B>getSegmentsExcluded</B>()</PRE><DL><DD>Returns the number of segments excluded per segment group.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The number of segments excluded.</DL></DD></DL><HR><A NAME="getSegmentsExcludedSize()"><!-- --></A><H3>getSegmentsExcludedSize</H3><PRE>public long <B>getSegmentsExcludedSize</B>()</PRE><DL><DD>Returns the size in milliseconds of the segments excluded per segment group.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The size in milliseconds.</DL></DD></DL><HR><A NAME="getGroupSegmentCount()"><!-- --></A><H3>getGroupSegmentCount</H3><PRE>public int <B>getGroupSegmentCount</B>()</PRE><DL><DD>Returns the number of segments in a segment group. This will be equal to segments included plus segments excluded.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The number of segments.</DL></DD></DL><HR><A NAME="getSegmentsGroupSize()"><!-- --></A><H3>getSegmentsGroupSize</H3><PRE>public long <B>getSegmentsGroupSize</B>()</PRE><DL><DD>Returns the size in milliseconds of a segment group. This will be equal to size of the segments included plus the size of the segments excluded.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The segment group size in milliseconds.</DL></DD></DL><HR><A NAME="getSegmentsIncluded()"><!-- --></A><H3>getSegmentsIncluded</H3><PRE>public int <B>getSegmentsIncluded</B>()</PRE><DL><DD>Returns the number of segments included per segment group.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The number of segments.</DL></DD></DL><HR><A NAME="getSegmentsIncludedSize()"><!-- --></A><H3>getSegmentsIncludedSize</H3><PRE>public long <B>getSegmentsIncludedSize</B>()</PRE><DL><DD>Returns the size in ms of the segments included per segment group.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The segment size in milliseconds.</DL></DD></DL><HR><A NAME="getSegmentSize()"><!-- --></A><H3>getSegmentSize</H3><PRE>public long <B>getSegmentSize</B>()</PRE><DL><DD>Returns the size of one segment in ms.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The segment size in milliseconds.</DL></DD></DL><HR><A NAME="getExceptionSegments()"><!-- --></A><H3>getExceptionSegments</H3><PRE>public java.util.List <B>getExceptionSegments</B>()</PRE><DL><DD>Returns a list of all the exception segments. This list is not modifiable.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The exception segments.</DL></DD></DL><HR><A NAME="setExceptionSegments(java.util.List)"><!-- --></A><H3>setExceptionSegments</H3><PRE>public void <B>setExceptionSegments</B>(java.util.List exceptionSegments)</PRE><DL><DD>Sets the exception segments list.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>exceptionSegments</CODE> - the exception segments.</DL></DD></DL><HR><A NAME="getBaseTimeline()"><!-- --></A><H3>getBaseTimeline</H3><PRE>public <A HREF="../../../../org/jfree/chart/axis/SegmentedTimeline.html">SegmentedTimeline</A> <B>getBaseTimeline</B>()</PRE><DL><DD>Returns our baseTimeline, or <code>null</code> if none.<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>The base timeline.</DL></DD></DL><HR><A NAME="setBaseTimeline(org.jfree.chart.axis.SegmentedTimeline)"><!-- --></A><H3>setBaseTimeline</H3><PRE>public void <B>setBaseTimeline</B>(<A HREF="../../../../org/jfree/chart/axis/SegmentedTimeline.html">SegmentedTimeline</A> baseTimeline)</PRE><DL><DD>Sets the base timeline.<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>baseTimeline</CODE> - the timeline.</DL></DD></DL><HR><A NAME="toTimelineValue(long)"><!-- --></A><H3>toTimelineValue</H3><PRE>public long <B>toTimelineValue</B>(long millisecond)</PRE><DL><DD>Translates a value relative to the domain value (all Dates) into a value relative to the segmented timeline. The values relative to the segmented timeline are all consecutives starting at zero at the startTime.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jfree/chart/axis/Timeline.html#toTimelineValue(long)">toTimelineValue</A></CODE> in interface <CODE><A HREF="../../../../org/jfree/chart/axis/Timeline.html">Timeline</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>millisecond</CODE> - the millisecond (as encoded by java.util.Date).<DT><B>Returns:</B><DD>The timeline value.</DL></DD></DL><HR><A NAME="toTimelineValue(java.util.Date)"><!-- --></A><H3>toTimelineValue</H3><PRE>public long <B>toTimelineValue</B>(java.util.Date date)</PRE><DL><DD>Translates a date into a value relative to the segmented timeline. The values relative to the segmented timeline are all consecutives starting at zero at the startTime.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jfree/chart/axis/Timeline.html#toTimelineValue(java.util.Date)">toTimelineValue</A></CODE> in interface <CODE><A HREF="../../../../org/jfree/chart/axis/Timeline.html">Timeline</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>date</CODE> - date relative to the domain.<DT><B>Returns:</B><DD>The timeline value.</DL></DD></DL><HR><A NAME="toMillisecond(long)"><!-- --></A><H3>toMillisecond</H3><PRE>public long <B>toMillisecond</B>(long timelineValue)</PRE><DL><DD>Translates a value relative to the timeline into a millisecond.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jfree/chart/axis/Timeline.html#toMillisecond(long)">toMillisecond</A></CODE> in interface <CODE><A HREF="../../../../org/jfree/chart/axis/Timeline.html">Timeline</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>timelineValue</CODE> - the timeline value.<DT><B>Returns:</B><DD>The domain value.<DT><B>See Also:</B><DD><A HREF="../../../../org/jfree/chart/axis/SegmentedTimeline.html"><CODE>SegmentedTimeline</CODE></A></DL></DD></DL><HR><A NAME="containsDomainValue(long)"><!-- --></A><H3>containsDomainValue</H3><PRE>public boolean <B>containsDomainValue</B>(long millisecond)</PRE><DL><DD>Returns <code>true</code> if a value is contained in the timeline.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jfree/chart/axis/Timeline.html#containsDomainValue(long)">containsDomainValue</A></CODE> in interface <CODE><A HREF="../../../../org/jfree/chart/axis/Timeline.html">Timeline</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>millisecond</CODE> - the millisecond.<DT><B>Returns:</B><DD><code>true</code> if value is contained in the timeline.</DL></DD></DL><HR><A NAME="containsDomainValue(java.util.Date)"><!-- --></A><H3>containsDomainValue</H3><PRE>public boolean <B>containsDomainValue</B>(java.util.Date date)</PRE><DL><DD>Returns true if a value is contained in the timeline.<P><DD><DL><DT><B>Specified by:</B><DD><CODE><A HREF="../../../../org/jfree/chart/axis/Timeline.html#containsDomainValue(java.util.Date)">containsDomainValue</A></CODE> in interface <CODE><A HREF="../../../../org/jfree/chart/axis/Timeline.html">Timeline</A></CODE></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>date</CODE> - date to verify<DT><B>Returns:</B><DD>true if value is contained in the timeline</DL></DD></DL><HR><A NAME="containsDomainRange(long, long)"><!-- --></A><H3>containsDomainRange</H3><PRE>public boolean <B>containsDomainRange</B>(long domainValueStart, long domainValueEnd)</PRE><DL><DD>Returns true if a range of values are contained in the timeline. This is implemented verifying that all segments are in the range.
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?