com.sencha.gxt.chart.client.chart.series
Class LineSeries<M>

java.lang.Object
  extended by com.sencha.gxt.chart.client.chart.series.Series<M>
      extended by com.sencha.gxt.chart.client.chart.series.ScatterSeries<M>
          extended by com.sencha.gxt.chart.client.chart.series.LineSeries<M>
Type Parameters:
M - the data type used by the series
All Implemented Interfaces:
SeriesHandler.HasSeriesHandlers, SeriesItemOutEvent.HasSeriesItemOutHandlers, SeriesItemOverEvent.HasSeriesItemOverHandlers, SeriesSelectionEvent.HasSeriesSelectionHandlers

public class LineSeries<M>
extends ScatterSeries<M>

Creates a Line Chart. A Line Chart is a useful visualization technique to display quantitative information for different categories or other real values (as opposed to the BarSeries), that can show some progression (or regression) in the data set.


Nested Class Summary
 
Nested classes/interfaces inherited from class com.sencha.gxt.chart.client.chart.series.Series
Series.LabelPosition
 
Constructor Summary
LineSeries()
          Creates a line Series.
 
Method Summary
 void delete()
          Removes all the sprites of the series from the surface.
 void drawSeries()
          Draws the series for the current chart.
 Color getFill()
          Returns the fill color of the line.
 SeriesRenderer<M> getFillRenderer()
          Returns the SeriesRenderer used on the fill sprite.
 SeriesRenderer<M> getLineRenderer()
          Returns the SeriesRenderer used on the line sprite.
 double getMarkerIndex()
          Returns the marker index of the series.
 int getSegments()
          Returns the number of segments of the smoothed line.
 void hide(int yFieldIndex)
          Hides the given y field index from the series.
 void highlight(int yFieldIndex)
          Highlights the series at the given index.
 void highlightAll(int index)
          Highlights all of the items in the series.
 boolean isShowMarkers()
          Returns whether or not markers are shown.
 boolean isSmooth()
          Returns whether or not the line is smoothed or straight.
 void setFill(Color fill)
          Sets the fill color of the line.
 void setFillRenderer(SeriesRenderer<M> fillRenderer)
          Sets the SeriesRenderer used on the fill sprite.
 void setLineRenderer(SeriesRenderer<M> lineRenderer)
          Sets the SeriesRenderer used on the line sprite
 void setMarkerIndex(double markerIndex)
          Sets the marker index.
 void setSegments(int segments)
          Sets the number of segments of the smoothed line.
 void setShowMarkers(boolean showMarkers)
          Sets whether or not to show markers.
 void setSmooth(boolean smooth)
          Sets whether or not the line is smoothed or straight.
 void show(int yFieldIndex)
          Shows the given y field index from the series.
 void unHighlight(int yFieldIndex)
          Removes highlighting from the given index.
 void unHighlightAll(int index)
          UnHighlights all items in the series.
 boolean visibleInLegend(int index)
          Returns whether or not the given index is visible in legend.
 
Methods inherited from class com.sencha.gxt.chart.client.chart.series.ScatterSeries
getMarkerConfig, getSelectionTolerance, getTitle, getYField, setLegendTitle, setMarkerConfig, setSelectionTolerance, setYField
 
Methods inherited from class com.sencha.gxt.chart.client.chart.series.Series
addSeriesHandler, addSeriesItemOutHandler, addSeriesItemOverHandler, addSeriesSelectionHandler, calculateBBox, getBBox, getChart, getGutters, getHighlighter, getLabelConfig, getLegendNames, getLegendTitles, getRenderer, getStroke, getStrokeWidth, getToolTip, getToolTipConfig, getXField, getYAxisPosition, highlightedState, isHighlighting, isShownInLegend, onMouseDown, onMouseMove, onMouseOut, removeToolTip, setChart, setHighlighter, setHighlighting, setLabelConfig, setRenderer, setShownInLegend, setStroke, setStrokeWidth, setToolTipConfig, setXField, setYAxisPosition
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LineSeries

public LineSeries()
Creates a line Series.

Method Detail

delete

public void delete()
Description copied from class: Series
Removes all the sprites of the series from the surface.

Overrides:
delete in class Series<M>

drawSeries

public void drawSeries()
Description copied from class: Series
Draws the series for the current chart.

Overrides:
drawSeries in class ScatterSeries<M>

getFill

public Color getFill()
Returns the fill color of the line.

Returns:
the fill color of the line

getFillRenderer

public SeriesRenderer<M> getFillRenderer()
Returns the SeriesRenderer used on the fill sprite.

Returns:
the series renderer used on the fill sprite

getLineRenderer

public SeriesRenderer<M> getLineRenderer()
Returns the SeriesRenderer used on the line sprite.

Returns:
the series renderer used on the line sprite

getMarkerIndex

public double getMarkerIndex()
Returns the marker index of the series. Determines the number of markers to animate to simulate progression.

Returns:
the marker index of the series

getSegments

public int getSegments()
Returns the number of segments of the smoothed line.

Returns:
the number of segments of the smoothed line

hide

public void hide(int yFieldIndex)
Description copied from class: Series
Hides the given y field index from the series.

Overrides:
hide in class ScatterSeries<M>
Parameters:
yFieldIndex - the index of the y field

highlight

public void highlight(int yFieldIndex)
Description copied from class: Series
Highlights the series at the given index.

Overrides:
highlight in class ScatterSeries<M>
Parameters:
yFieldIndex - the index to be highlighted

highlightAll

public void highlightAll(int index)
Description copied from class: Series
Highlights all of the items in the series.

Overrides:
highlightAll in class ScatterSeries<M>
Parameters:
index - the index of the series

isShowMarkers

public boolean isShowMarkers()
Returns whether or not markers are shown.

Returns:
whether or not markers are shown

isSmooth

public boolean isSmooth()
Returns whether or not the line is smoothed or straight.

Returns:
true if smooth

setFill

public void setFill(Color fill)
Sets the fill color of the line. If none the fill will not be drawn.

Parameters:
fill - the color of the fill

setFillRenderer

public void setFillRenderer(SeriesRenderer<M> fillRenderer)
Sets the SeriesRenderer used on the fill sprite.

Parameters:
fillRenderer - the series renderer used on the fill sprite

setLineRenderer

public void setLineRenderer(SeriesRenderer<M> lineRenderer)
Sets the SeriesRenderer used on the line sprite

Parameters:
lineRenderer - the series renderer used on the line sprite

setMarkerIndex

public void setMarkerIndex(double markerIndex)
Sets the marker index. Determines the number of markers to animate to simulate progression.

Parameters:
markerIndex - the marker index

setSegments

public void setSegments(int segments)
Sets the number of segments of the smoothed line. Smooth line enabled using setSmooth(boolean).

Parameters:
segments - the number of segments of the smoothed line

setShowMarkers

public void setShowMarkers(boolean showMarkers)
Sets whether or not to show markers.

Parameters:
showMarkers - whether or not to show markers

setSmooth

public void setSmooth(boolean smooth)
Sets whether or not the line is smoothed or straight.

Parameters:
smooth - true if smooth

show

public void show(int yFieldIndex)
Description copied from class: Series
Shows the given y field index from the series.

Overrides:
show in class ScatterSeries<M>
Parameters:
yFieldIndex - the index of the y field

unHighlight

public void unHighlight(int yFieldIndex)
Description copied from class: Series
Removes highlighting from the given index.

Overrides:
unHighlight in class ScatterSeries<M>
Parameters:
yFieldIndex - the index to have its highlighting removed

unHighlightAll

public void unHighlightAll(int index)
Description copied from class: Series
UnHighlights all items in the series.

Overrides:
unHighlightAll in class ScatterSeries<M>
Parameters:
index - the index of the series

visibleInLegend

public boolean visibleInLegend(int index)
Description copied from class: Series
Returns whether or not the given index is visible in legend.

Overrides:
visibleInLegend in class ScatterSeries<M>
Parameters:
index - the index to determine visible
Returns:
whether or not it is visible


Copyright © 2011. All Rights Reserved.