Package org.eclipse.draw2d.geometry

# Class PrecisionPointList

java.lang.Object
org.eclipse.draw2d.geometry.PointList
org.eclipse.draw2d.geometry.PrecisionPointList

All Implemented Interfaces:
  `Serializable`, `Translatable`

public final class PrecisionPointList extends PointList
A PointList implementation using floating point values which are truncated into the inherited integer fields. The use of floating point prevents rounding errors from accumulating. EXPERIMENTAL This class has been added as part of a work in progress and there is no guarantee that this API will remain unchanged. This is likely to not function properly outside some very specific use-cases.

Since:
  3.21
See Also:
  - Serialized Form
@noreference
  This class is not intended to be referenced by clients.

## Constructor Summary

Constructors
Constructor
Description
`PrecisionPointList(int[] points)`
Constructs a PrecisionPointList with the given points.
`PrecisionPointList(PointList points)`
Constructs a PrecisionPointList with the given points.

## Method Summary

Modifier and Type
Method
Description
`void`
`performScale(double factor)`
Scales this object by the scale factor.

### Methods inherited from class org.eclipse.draw2d.geometry.PointList

`addAll, addPoint, addPoint, getBounds, getCopy, getFirstPoint, getLastPoint, getMidpoint, getPoint, getPoint, insertPoint, intersects, performTranslate, polygonContainsPoint, polylineContainsPoint, removeAllPoints, removePoint, reverse, setPoint, setSize, size, toIntArray, translate, translate, transpose`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Methods inherited from interface org.eclipse.draw2d.geometry.Translatable

`performTranslate, performTranslate, performTranslate`

## Constructor Details

### PrecisionPointList

public PrecisionPointList(int[] points)
Constructs a PrecisionPointList with the given points.

Parameters:
  `points` - int array where two consecutive ints form the coordinates of a point

### PrecisionPointList

public PrecisionPointList(PointList points)
Constructs a PrecisionPointList with the given points.

Parameters:
  `points` - PointList from which the initial values are taken

## Method Details

### performScale

public void performScale(double factor)
Description copied from interface: `Translatable`
Scales this object by the scale factor.

Specified by:
  `performScale` in interface `Translatable`
Overrides:
  `performScale` in class `PointList`
Parameters:
  `factor` - The scale factor
See Also:
  - `Translatable.performScale(double)`