test_class.declarator: xyPlot
test_class.modifier: private
test_class.original_string: private XYPlot xyPlot;
test_class.type: XYPlot
test_class.var_name: xyPlot
test_class.declarator: canvas
test_class.modifier: @Mock
test_class.original_string: @Mock
      Canvas canvas;
test_class.type: Canvas
test_class.var_name: canvas
test_class.declarator: plotArea = new RectF(0, 0, 100, 100)
test_class.original_string: RectF plotArea = new RectF(0, 0, 100, 100);
test_class.type: RectF
test_class.var_name: plotArea
test_class.file: androidplot-core/src/test/java/com/androidplot/xy/LineAndPointRendererTest.java
test_class.identifier: LineAndPointRendererTest
test_class.superclass: extends AndroidplotTest
test_case.body: @Test
      public void drawSeries_withPointLabelFormatter_drawsPointLabels() {
          LineAndPointFormatter formatter =
                  new LineAndPointFormatter(0, 0, 0, null);
          formatter.setPointLabelFormatter(new PointLabelFormatter(Color.RED));
          SimpleXYSeries series = new SimpleXYSeries(
                  SimpleXYSeries.ArrayFormat.Y_VALS_ONLY, "some data", 1, 2, 3, 4, 5, 6, 7, 8, 9, 10);
          xyPlot.addSeries(series, formatter);
          LineAndPointRenderer renderer = xyPlot.getRenderer(LineAndPointRenderer.class);
          renderer.drawSeries(canvas, plotArea, series, formatter);
  
          verify(canvas, times(series.size())).drawText(
                  anyString(),
                  anyFloat(),
                  anyFloat(),
                  eq(formatter.getPointLabelFormatter().getTextPaint()));
  
      }
test_case.class_method_signature: LineAndPointRendererTest.drawSeries_withPointLabelFormatter_drawsPointLabels()
test_case.full_signature: @Test public void drawSeries_withPointLabelFormatter_drawsPointLabels()
test_case.identifier: drawSeries_withPointLabelFormatter_drawsPointLabels
test_case.invocations: setPointLabelFormatter addSeries getRenderer drawSeries drawText verify times size anyString anyFloat anyFloat eq getTextPaint getPointLabelFormatter
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void drawSeries_withPointLabelFormatter_drawsPointLabels()
focal_class.declarator: ZERO = 0
focal_class.modifier: protected static final
focal_class.original_string: protected static final int ZERO = 0;
focal_class.type: int
focal_class.var_name: ZERO
focal_class.declarator: ONE = 1
focal_class.modifier: protected static final
focal_class.original_string: protected static final int ONE = 1;
focal_class.type: int
focal_class.var_name: ONE
focal_class.declarator: path = new Path()
focal_class.modifier: private final
focal_class.original_string: private final Path path = new Path();
focal_class.type: Path
focal_class.var_name: path
focal_class.declarator: pointsCaches
              = new ConcurrentHashMap<>(2, 0.75f, 2)
focal_class.modifier: protected final
focal_class.original_string: protected final ConcurrentHashMap<XYSeries, ArrayList<PointF>> pointsCaches
              = new ConcurrentHashMap<>(2, 0.75f, 2);
focal_class.type: ConcurrentHashMap<XYSeries, ArrayList<PointF>>
focal_class.var_name: pointsCaches
focal_class.file: androidplot-core/src/main/java/com/androidplot/xy/LineAndPointRenderer.java
focal_class.identifier: LineAndPointRenderer
focal_class.class_method_signature: LineAndPointRenderer.LineAndPointRenderer(XYPlot plot)
focal_class.full_signature: public  LineAndPointRenderer(XYPlot plot)
focal_class.identifier: LineAndPointRenderer
focal_class.modifiers: public
focal_class.parameters: (XYPlot plot)
focal_class.signature:  LineAndPointRenderer(XYPlot plot)
focal_class.class_method_signature: LineAndPointRenderer.onRender(Canvas canvas, RectF plotArea, XYSeries series, FormatterType formatter, RenderStack stack)
focal_class.full_signature: @Override public void onRender(Canvas canvas, RectF plotArea, XYSeries series, FormatterType formatter, RenderStack stack)
focal_class.identifier: onRender
focal_class.modifiers: @Override public
focal_class.parameters: (Canvas canvas, RectF plotArea, XYSeries series, FormatterType formatter, RenderStack stack)
focal_class.return: void
focal_class.signature: void onRender(Canvas canvas, RectF plotArea, XYSeries series, FormatterType formatter, RenderStack stack)
focal_class.class_method_signature: LineAndPointRenderer.doDrawLegendIcon(Canvas canvas, RectF rect, LineAndPointFormatter formatter)
focal_class.full_signature: @Override public void doDrawLegendIcon(Canvas canvas, RectF rect, LineAndPointFormatter formatter)
focal_class.identifier: doDrawLegendIcon
focal_class.modifiers: @Override public
focal_class.parameters: (Canvas canvas, RectF rect, LineAndPointFormatter formatter)
focal_class.return: void
focal_class.signature: void doDrawLegendIcon(Canvas canvas, RectF rect, LineAndPointFormatter formatter)
focal_class.class_method_signature: LineAndPointRenderer.appendToPath(Path path, PointF thisPoint, PointF lastPoint)
focal_class.full_signature: protected void appendToPath(Path path, PointF thisPoint, PointF lastPoint)
focal_class.identifier: appendToPath
focal_class.modifiers: protected
focal_class.parameters: (Path path, PointF thisPoint, PointF lastPoint)
focal_class.return: void
focal_class.signature: void appendToPath(Path path, PointF thisPoint, PointF lastPoint)
focal_class.class_method_signature: LineAndPointRenderer.getPointsCache(XYSeries series)
focal_class.full_signature: protected ArrayList<PointF> getPointsCache(XYSeries series)
focal_class.identifier: getPointsCache
focal_class.modifiers: protected
focal_class.parameters: (XYSeries series)
focal_class.return: ArrayList<PointF>
focal_class.signature: ArrayList<PointF> getPointsCache(XYSeries series)
focal_class.class_method_signature: LineAndPointRenderer.cullPointsCache()
focal_class.full_signature: protected void cullPointsCache()
focal_class.identifier: cullPointsCache
focal_class.modifiers: protected
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void cullPointsCache()
focal_class.class_method_signature: LineAndPointRenderer.drawSeries(Canvas canvas, RectF plotArea, XYSeries series, LineAndPointFormatter formatter)
focal_class.full_signature: protected void drawSeries(Canvas canvas, RectF plotArea, XYSeries series, LineAndPointFormatter formatter)
focal_class.identifier: drawSeries
focal_class.modifiers: protected
focal_class.parameters: (Canvas canvas, RectF plotArea, XYSeries series, LineAndPointFormatter formatter)
focal_class.return: void
focal_class.signature: void drawSeries(Canvas canvas, RectF plotArea, XYSeries series, LineAndPointFormatter formatter)
focal_class.class_method_signature: LineAndPointRenderer.getInterpolator(InterpolationParams params)
focal_class.full_signature: protected Interpolator getInterpolator(InterpolationParams params)
focal_class.identifier: getInterpolator
focal_class.modifiers: protected
focal_class.parameters: (InterpolationParams params)
focal_class.return: Interpolator
focal_class.signature: Interpolator getInterpolator(InterpolationParams params)
focal_class.class_method_signature: LineAndPointRenderer.convertPoint(XYCoords coord, RectF plotArea)
focal_class.full_signature: protected PointF convertPoint(XYCoords coord, RectF plotArea)
focal_class.identifier: convertPoint
focal_class.modifiers: protected
focal_class.parameters: (XYCoords coord, RectF plotArea)
focal_class.return: PointF
focal_class.signature: PointF convertPoint(XYCoords coord, RectF plotArea)
focal_class.class_method_signature: LineAndPointRenderer.renderPoints(Canvas canvas, RectF plotArea, XYSeries series, int iStart, int iEnd, List<PointF> points,
                                  LineAndPointFormatter formatter)
focal_class.full_signature: protected void renderPoints(Canvas canvas, RectF plotArea, XYSeries series, int iStart, int iEnd, List<PointF> points,
                                  LineAndPointFormatter formatter)
focal_class.identifier: renderPoints
focal_class.modifiers: protected
focal_class.parameters: (Canvas canvas, RectF plotArea, XYSeries series, int iStart, int iEnd, List<PointF> points,
                                  LineAndPointFormatter formatter)
focal_class.return: void
focal_class.signature: void renderPoints(Canvas canvas, RectF plotArea, XYSeries series, int iStart, int iEnd, List<PointF> points,
                                  LineAndPointFormatter formatter)
focal_class.class_method_signature: LineAndPointRenderer.renderPath(Canvas canvas, RectF plotArea, Path path, PointF firstPoint, PointF lastPoint, LineAndPointFormatter formatter)
focal_class.full_signature: protected void renderPath(Canvas canvas, RectF plotArea, Path path, PointF firstPoint, PointF lastPoint, LineAndPointFormatter formatter)
focal_class.identifier: renderPath
focal_class.modifiers: protected
focal_class.parameters: (Canvas canvas, RectF plotArea, Path path, PointF firstPoint, PointF lastPoint, LineAndPointFormatter formatter)
focal_class.return: void
focal_class.signature: void renderPath(Canvas canvas, RectF plotArea, Path path, PointF firstPoint, PointF lastPoint, LineAndPointFormatter formatter)
focal_class.superclass: extends XYSeriesRenderer<XYSeries, FormatterType>
focal_method.body: protected void drawSeries(Canvas canvas, RectF plotArea, XYSeries series, LineAndPointFormatter formatter) {
          PointF thisPoint;
          PointF lastPoint = null;
          PointF firstPoint = null;
          path.reset();
          final List<PointF> points = getPointsCache(series);
  
          int iStart = 0;
          int iEnd = series.size();
          if(SeriesUtils.getXYOrder(series) == OrderedXYSeries.XOrder.ASCENDING) {
              final Region iBounds = SeriesUtils.iBounds(series, getPlot().getBounds());
              iStart = iBounds.getMin().intValue();
              if(iStart > 0) {
                  iStart--;
              }
              iEnd = iBounds.getMax().intValue() + 1;
              if(iEnd < series.size() - 1) {
                  iEnd++;
              }
          }
          for (int i = iStart; i < iEnd; i++) {
              final Number y = series.getY(i);
              final Number x = series.getX(i);
              PointF iPoint = points.get(i);
  
              if (y != null && x != null) {
                  if(iPoint == null) {
                      iPoint = new PointF();
                      points.set(i, iPoint);
                  }
                  thisPoint = iPoint;
                  getPlot().getBounds().transformScreen(thisPoint, x, y, plotArea);
              } else {
                  thisPoint = null;
                  iPoint = null;
                  points.set(i, iPoint);
              }
  
              // don't need to do any of this if the line isnt going to be drawn:
              if(formatter.hasLinePaint() && formatter.getInterpolationParams() == null) {
                  if (thisPoint != null) {
  
                      // record the first point of the new Path
                      if (firstPoint == null) {
                          path.reset();
                          firstPoint = thisPoint;
  
                          // create our first point at the bottom/x position so filling will look good:
                          path.moveTo(firstPoint.x, firstPoint.y);
                      }
  
                      if (lastPoint != null) {
                          appendToPath(path, thisPoint, lastPoint);
                      }
  
                      lastPoint = thisPoint;
                  } else {
                      if (lastPoint != null) {
                          renderPath(canvas, plotArea, path, firstPoint, lastPoint, formatter);
                      }
                      firstPoint = null;
                      lastPoint = null;
                  }
              }
          }
  
          if(formatter.hasLinePaint()) {
              if(formatter.getInterpolationParams() != null) {
                  List<XYCoords> interpolatedPoints = getInterpolator(
                          formatter.getInterpolationParams()).interpolate(series,
                          formatter.getInterpolationParams());
                  firstPoint = convertPoint(interpolatedPoints.get(ZERO), plotArea);
                  lastPoint = convertPoint(interpolatedPoints.get(interpolatedPoints.size()-ONE), plotArea);
                  path.reset();
                  path.moveTo(firstPoint.x, firstPoint.y);
                  for(int i = 1; i < interpolatedPoints.size(); i++) {
                      thisPoint = convertPoint(interpolatedPoints.get(i), plotArea);
                      path.lineTo(thisPoint.x, thisPoint.y);
                  }
              }
  
              if(firstPoint != null) {
                  renderPath(canvas, plotArea, path, firstPoint, lastPoint, formatter);
              }
          }
          renderPoints(canvas, plotArea, series, iStart, iEnd, points, formatter);
      }
focal_method.class_method_signature: LineAndPointRenderer.drawSeries(Canvas canvas, RectF plotArea, XYSeries series, LineAndPointFormatter formatter)
focal_method.full_signature: protected void drawSeries(Canvas canvas, RectF plotArea, XYSeries series, LineAndPointFormatter formatter)
focal_method.identifier: drawSeries
focal_method.invocations: reset getPointsCache size getXYOrder iBounds getBounds getPlot intValue getMin intValue getMax size getY getX get set transformScreen getBounds getPlot set hasLinePaint getInterpolationParams reset moveTo appendToPath renderPath hasLinePaint getInterpolationParams interpolate getInterpolator getInterpolationParams getInterpolationParams convertPoint get convertPoint get size reset moveTo size convertPoint get lineTo renderPath renderPoints
focal_method.modifiers: protected
focal_method.parameters: (Canvas canvas, RectF plotArea, XYSeries series, LineAndPointFormatter formatter)
focal_method.return: void
focal_method.signature: void drawSeries(Canvas canvas, RectF plotArea, XYSeries series, LineAndPointFormatter formatter)