Package org.eclipse.gef.geometry.planar

# Class Arc

java.lang.Object
org.eclipse.gef.geometry.planar.Arc

All Implemented Interfaces:
  `Serializable`, `Cloneable`, `ICurve`, `IGeometry`, `IRotatable<PolyBezier>`, `IScalable<Arc>`, `ITranslatable<Arc>`

public final class Arc extends Object implements ICurve
Represents the geometric shape of an `Arc`, which is defined by its enclosing framing `Rectangle`, a start `Angle` (relative to the x-axis), and an angular extend in counter-clockwise (CCW) direction.

See Also:
  - Serialized Form

## Field Summary

Fields
Modifier and Type
Field
Description
`protected Angle`
`angularExtent`
The counter-clockwise (CCW) `Angle` that spans this `AbstractArcBasedGeometry`.
`protected Angle`
`startAngle`
The counter-clockwise (CCW) `Angle` to the x-axis at which this `AbstractArcBasedGeometry` begins.

## Constructor Summary

Constructors
Constructor
Description
`Arc(double x, double y, double width, double height, Angle startAngle, Angle angularExtent)`
Constructs a new `Arc` of the given values.
`Arc(org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?> r, Angle startAngle, Angle angularExtent)`
Constructs a new `Arc` of the given values.

## Method Summary

Modifier and Type
Method
Description
`Object`
`clone()`
Overridden with public visibility as recommended within `Cloneable` .
`protected CubicCurve[]`
`computeBezierApproximation()`
Computes a `CubicCurve` approximation for this `AbstractArcBasedGeometry`.
`boolean`
`contains(Point p)`
Returns whether the given `Point` is contained within this `IGeometry`.
`boolean`
`equals(Object obj)`
`Arc`
`expand(double h, double v)`
Expands the horizontal and vertical sides of this `AbstractRectangleBasedGeometry` with the values provided as input, and returns `this` for convenience.
`Arc`
`expand(double left, double top, double right, double bottom)`
Expands this `AbstractRectangleBasedGeometry` by the given amounts, and returns this for convenience.
`Angle`
`getAngularExtent()`
Returns the extension `Angle` of this `AbstractArcBasedGeometry`, i.e. the `Angle` defining the span of this `AbstractArcBasedGeometry`.
`Rectangle`
`getBounds()`
Returns the smallest `Rectangle` fully enclosing this `IGeometry`.
`Point`
`getCenter()`
Returns the center `Point` of this `AbstractRectangleBasedGeometry`.
`Arc`
`getCopy()`
Returns a new identical copy of this `IGeometry`.
`Arc`
`getExpanded(double h, double v)`
Returns a new expanded `AbstractRectangleBasedGeometry`, where the sides are incremented by the horizontal and vertical values provided.
`Arc`
`getExpanded(double left, double top, double right, double bottom)`
Creates and returns a new `AbstractRectangleBasedGeometry` with the bounds of this `AbstractRectangleBasedGeometry` expanded by the given insets.
`final double`
`getHeight()`
Returns the height of this `AbstractRectangleBasedGeometry`.
`Point[]`
`getIntersections(ICurve c)`
Returns the points of intersection between this `ICurve` and the given `ICurve`.
`Point`
`getLocation()`
Returns a `Point` specifying the x and y coordinates of this `AbstractRectangleBasedGeometry`.
`ICurve[]`
`getOverlaps(ICurve c)`
Returns the curve segments at which this `ICurve` and the given `ICurve` overlap.
`Point`
`getP1()`
Returns the start `Point` of this `AbstractArcBasedGeometry`.
`Point`
`getP2()`
Returns the end `Point` of this `AbstractArcBasedGeometry`.
`Point`
`getPoint(Angle angularExtent)`
Computes a `Point` on this `AbstractArcBasedGeometry`.
`Point`
`getProjection(Point reference)`
Returns a projection of the given reference `Point` onto this `ICurve`, i.e. a `Point` on this `ICurve` that is closest to the given reference `Point`.
`PolyBezier`
`getRotatedCCW(Angle angle)`
Rotates the calling object by specified `Angle` counter-clock-wise (CCW) around its center `Point`.
`PolyBezier`
`getRotatedCCW(Angle angle, double cx, double cy)`
Rotates the calling object by the specified `Angle` counter-clock-wise (CCW) around the specified center `Point` (cx, cy).
`PolyBezier`
`getRotatedCCW(Angle angle, Point center)`
Rotates the calling object by the specified `Angle` counter-clock-wise (CCW) around the specified center `Point`.
`PolyBezier`
`getRotatedCW(Angle angle)`
Rotates the calling object by specified `Angle` clock-wise (CW) around its center `Point`.
`PolyBezier`
`getRotatedCW(Angle angle, double cx, double cy)`
Rotates the calling object by the specified `Angle` clock-wise (CW) around the specified center `Point` (cx, cy).
`PolyBezier`
`getRotatedCW(Angle angle, Point center)`
Rotates the calling object by the specified `Angle` clock-wise (CW) around the specified center `Point`.
`Arc`
`getScaled(double factor)`
Scales a copy of the calling object by the given factor relative to its center `Point`.
`Arc`
`getScaled(double factorX, double factorY)`
Scales a copy of the calling object by the given factors relative to its center `Point`.
`Arc`
`getScaled(double factor, double centerX, double centerY)`
Scales a copy of the calling object by the given factor relative to the given center `Point` (cx, cy).
`Arc`
`getScaled(double factorX, double factorY, double centerX, double centerY)`
Scales a copy of the calling object by the given factors relative to the given center `Point` (cx, cy).
`Arc`
`getScaled(double factorX, double factorY, Point center)`
Scales a copy of the calling object by the given factors relative to the given center `Point`.
`Arc`
`getScaled(double factor, Point center)`
Scales a copy of the calling object by the given factor relative to the given center `Point`.
`Arc`
`getShrinked(double h, double v)`
Returns a new `AbstractRectangleBasedGeometry`, where the sides are shrinked by the horizontal and vertical values supplied.
`Arc`
`getShrinked(double left, double top, double right, double bottom)`
Returns a new `AbstractRectangleBasedGeometry` shrinked by the specified insets.
`final Dimension`
`getSize()`
Returns a `Dimension` that records the width and height of this `AbstractRectangleBasedGeometry`.
`Angle`
`getStartAngle()`
Returns this `AbstractArcBasedGeometry`'s start `Angle`.
`IGeometry`
`getTransformed(AffineTransform t)`
Default implementation returning a transformed `Path` representation of this `IGeometry`.
`Arc`
`getTranslated(double dx, double dy)`
Translates a copy of this object by the given values in x and y direction.
`Arc`
`getTranslated(Point pt)`
Translates a copy of this object by the given `Point`.
`final double`
`getWidth()`
Returns the width of this `AbstractRectangleBasedGeometry`.
`final double`
`getX()`
Returns the x coordinate this `AbstractRectangleBasedGeometry`.
`double`
`getX1()`
Returns the x coordinate of the start `Point` of this `AbstractArcBasedGeometry`.
`double`
`getX2()`
Returns the x coordinate of the end `Point` of this `AbstractArcBasedGeometry`.
`final double`
`getY()`
Returns the y coordinate of this `AbstractRectangleBasedGeometry`.
`double`
`getY1()`
Returns the y coordinate of the start `Point` of this `AbstractArcBasedGeometry`.
`double`
`getY2()`
Returns the y coordinate of the end `Point` of this `AbstractArcBasedGeometry`.
`final int`
`hashCode()`
`boolean`
`intersects(ICurve c)`
Tests if this `ICurve` and the given `ICurve` intersect, i.e.
`boolean`
`overlaps(ICurve c)`
Tests if this `ICurve` and the given `ICurve` overlap, i.e.
`Arc`
`scale(double factor)`
Scales the calling object by the given factor relative to its center `Point`.
`Arc`
`scale(double fx, double fy)`
Scales the calling object by the given factors relative to the given center `Point`.
`Arc`
`scale(double factor, double cx, double cy)`
Scales the calling object by the given factor relative to the given center `Point` (cx, cy).
`Arc`
`scale(double fx, double fy, double cx, double cy)`
Scales the calling object by the given factors relative to the given center `Point` (cx, cy).
`Arc`
`scale(double fx, double fy, Point center)`
Scales the calling object by the given factors relative to the given center `Point`.
`Arc`
`scale(double factor, Point center)`
Scales the calling object by the given factor relative to the given center `Point`.
`Arc`
`setAngularExtent(Angle angularExtent)`
Sets the extension `Angle` of this `AbstractArcBasedGeometry` .
`final Arc`
`setBounds(double x, double y, double w, double h)`
Sets the x, y, width, and height values of this `AbstractRectangleBasedGeometry` to the given values.
`final Arc`
`setBounds(Point loc, Dimension size)`
Sets the x, y, width, and height values of this `AbstractRectangleBasedGeometry` to the respective values specified by the passed-in `Point` and the passed-in `Dimension`.
`final Arc`
`setBounds(Rectangle r)`
Sets the x and y coordinates and the width and height of this `AbstractRectangleBasedGeometry` to the respective values of the given `Rectangle`.
`final Arc`
`setHeight(double height)`
Sets the height of this `AbstractRectangleBasedGeometry` to the given value.
`final Arc`
`setLocation(double x, double y)`
Sets the x and y coordinates of this `AbstractRectangleBasedGeometry` to the specified values.
`final Arc`
`setLocation(Point p)`
Sets the x and y coordinates of this `AbstractRectangleBasedGeometry` to the respective values of the given `Point`.
`final Arc`
`setSize(double w, double h)`
Sets the width and height of this `AbstractRectangleBasedGeometry` to the given values.
`final Arc`
`setSize(Dimension d)`
Sets the width and height of this `AbstractRectangleBasedGeometry` to the width and height of the given `Dimension`.
`Arc`
`setStartAngle(Angle startAngle)`
Sets the start `Angle` of this `AbstractArcBasedGeometry`.
`final Arc`
`setWidth(double width)`
Sets the width of this `AbstractRectangleBasedGeometry` to the passed-in value.
`final Arc`
`setX(double x)`
Sets the x-coordinate of this `AbstractRectangleBasedGeometry` to the given value.
`final Arc`
`setY(double y)`
Sets the y-coordinate of this `AbstractRectangleBasedGeometry` to the given value.
`Arc`
`shrink(double h, double v)`
Shrinks the sides of this `AbstractRectangleBasedGeometry` by the horizontal and vertical values provided as input, and returns this `AbstractRectangleBasedGeometry` for convenience.
`Arc`
`shrink(double left, double top, double right, double bottom)`
Shrinks this `AbstractRectangleBasedGeometry` by the specified amounts.
`CubicCurve[]`
`toBezier()`
Computes a list of `BezierCurve`s that approximate the `ICurve`.
`Path`
`toPath()`
Converts this `IGeometry` into a `Path` representation.
`String`
`toString()`
`boolean`
`touches(IGeometry g)`
Returns `true` if the input `IGeometry` touches this `IGeometry`, i.e. there is at least one common point.
`Arc`
`translate(double dx, double dy)`
Translates the object by the given values in x and y direction.
`Arc`
`translate(Point p)`
Translates the object by the given `Point`.

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

`finalize, getClass, notify, notifyAll, wait, wait, wait`

### Methods inherited from interface org.eclipse.gef.geometry.planar.ICurve

`getP1, getP2, getX1, getX2, getY1, getY2`

### Methods inherited from interface org.eclipse.gef.geometry.planar.IGeometry

`getTransformed, toPath, touches`

## Field Details

### startAngle

protected Angle startAngle
The counter-clockwise (CCW) `Angle` to the x-axis at which this `AbstractArcBasedGeometry` begins.

### angularExtent

protected Angle angularExtent
The counter-clockwise (CCW) `Angle` that spans this `AbstractArcBasedGeometry`.

## Constructor Details

### Arc

public Arc(org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?> r, Angle startAngle, Angle angularExtent)
Constructs a new `Arc` of the given values. An `Arc` is cut out of an `Ellipse`. The start `Angle` is the counter-clockwise (CCW) `Angle` to the x-axis at which the `Arc` begins. The angular extent is the CCW `Angle` that spans the `Arc`, i.e. the resulting end `Angle` of the `Arc` is the sum of the start `Angle` and the angular extent.

Parameters:
  `r` - the `AbstractRectangleBasedGeometry` describing the bounds of the `Ellipse` of which the `Arc` is cut out
  `startAngle` - the CCW `Angle` at which the `Arc` begins
  `angularExtent` - the CCW `Angle` that spans the `Arc`

### Arc

public Arc(double x, double y, double width, double height, Angle startAngle, Angle angularExtent)
Constructs a new `Arc` of the given values. An `Arc` is cut out of an `Ellipse`. The start `Angle` is the counter-clockwise (CCW) `Angle` to the x-axis at which the `Arc` begins. The angular extent is the CCW `Angle` that spans the `Arc`, i.e. the resulting end `Angle` of the `Arc` is the sum of the start `Angle` and the angular extent.

Parameters:
  `x` - the x coordinate of the bounds of the `Ellipse` of which the `Arc` is cut out
  `y` - the y coordinate of the bounds of the `Ellipse` of which the `Arc` is cut out
  `width` - the width of the bounds of the `Ellipse` of which the `Arc` is cut out
  `height` - the height of the bounds of the `Ellipse` of which the `Arc` is cut out
  `startAngle` - the CCW `Angle` at which the `Arc` begins
  `angularExtent` - the CCW `Angle` that spans the `Arc`

## Method Details

### contains

public boolean contains(Point p)
Description copied from interface: `IGeometry`
Returns whether the given `Point` is contained within this `IGeometry`. This includes the case that the `Point` lies on the border of this `IGeometry`.

Specified by:
  `contains` in interface `IGeometry`
Parameters:
  `p` - The `Point` being tested for containment
Returns:
  `true` if the `Point` is contained within this `IGeometry`, `false` otherwise.

### equals

public boolean equals(Object obj)

Overrides:
  `equals` in class `Object`

### getBounds

public Rectangle getBounds()
Description copied from interface: `IGeometry`
Returns the smallest `Rectangle` fully enclosing this `IGeometry`.

Specified by:
  `getBounds` in interface `IGeometry`
Returns:
  A new `Rectangle` object that fully encloses this `IGeometry`

### getCopy

public Arc getCopy()
Description copied from interface: `IGeometry`
Returns a new identical copy of this `IGeometry`.

Specified by:
  `getCopy` in interface `IGeometry`
Returns:
  a copy identical to this `IGeometry`

### getIntersections

public Point[] getIntersections(ICurve c)
Description copied from interface: `ICurve`
Returns the points of intersection between this `ICurve` and the given `ICurve`.

Specified by:
  `getIntersections` in interface `ICurve`
Parameters:
  `c` - The `ICurve` to compute intersection points with.
Returns:
  The points of intersection.

### getOverlaps

public ICurve[] getOverlaps(ICurve c)
Description copied from interface: `ICurve`
Returns the curve segments at which this `ICurve` and the given `ICurve` overlap.

Specified by:
  `getOverlaps` in interface `ICurve`
Parameters:
  `c` - The curve to compute overlaps with.
Returns:
  The segments where both curves overlap.

### getProjection

public Point getProjection(Point reference)
Description copied from interface: `ICurve`
Returns a projection of the given reference `Point` onto this `ICurve`, i.e. a `Point` on this `ICurve` that is closest to the given reference `Point`. Note, that

Specified by:
  `getProjection` in interface `ICurve`
Parameters:
  `reference` - The reference `Point` for which to return the projection.
Returns:
  The projection of the given reference `Point` onto this `ICurve`.

### getRotatedCCW

public PolyBezier getRotatedCCW(Angle angle)
Description copied from interface: `IRotatable`
Rotates the calling object by specified `Angle` counter-clock-wise (CCW) around its center `Point`. Does not necessarily return an object of the same type.

Specified by:
  `getRotatedCCW` in interface `IRotatable<PolyBezier>`
Parameters:
  `angle` - rotation `Angle`
Returns:
  an `IGeometry` representing the result of the rotation

### getRotatedCCW

public PolyBezier getRotatedCCW(Angle angle, double cx, double cy)
Description copied from interface: `IRotatable`
Rotates the calling object by the specified `Angle` counter-clock-wise (CCW) around the specified center `Point` (cx, cy). Does not necessarily return an object of the same type.

Specified by:
  `getRotatedCCW` in interface `IRotatable<PolyBezier>`
Parameters:
  `angle` - rotation `Angle`
  `cx` - x-coordinate of the relative `Point` for the rotation
  `cy` - y-coordinate of the relative `Point` for the rotation
Returns:
  an `IGeometry` representing the result of the rotation

### getRotatedCCW

public PolyBezier getRotatedCCW(Angle angle, Point center)
Description copied from interface: `IRotatable`
Rotates the calling object by the specified `Angle` counter-clock-wise (CCW) around the specified center `Point`. Does not necessarily return an object of the same type.

Specified by:
  `getRotatedCCW` in interface `IRotatable<PolyBezier>`
Parameters:
  `angle` - rotation `Angle`
  `center` - relative `Point` for the rotation
Returns:
  an `IGeometry` representing the result of the rotation

### getRotatedCW

public PolyBezier getRotatedCW(Angle angle)
Description copied from interface: `IRotatable`
Rotates the calling object by specified `Angle` clock-wise (CW) around its center `Point`. Does not necessarily return an object of the same type.

Specified by:
  `getRotatedCW` in interface `IRotatable<PolyBezier>`
Parameters:
  `angle` - rotation `Angle`
Returns:
  an `IGeometry` representing the result of the rotation

### getRotatedCW

public PolyBezier getRotatedCW(Angle angle, double cx, double cy)
Description copied from interface: `IRotatable`
Rotates the calling object by the specified `Angle` clock-wise (CW) around the specified center `Point` (cx, cy). Does not necessarily return an object of the same type.

Specified by:
  `getRotatedCW` in interface `IRotatable<PolyBezier>`
Parameters:
  `angle` - rotation `Angle`
  `cx` - x-coordinate of the relative `Point` for the rotation
  `cy` - y-coordinate of the relative `Point` for the rotation
Returns:
  an `IGeometry` representing the result of the rotation

### getRotatedCW

public PolyBezier getRotatedCW(Angle angle, Point center)
Description copied from interface: `IRotatable`
Rotates the calling object by the specified `Angle` clock-wise (CW) around the specified center `Point`. Does not necessarily return an object of the same type.

Specified by:
  `getRotatedCW` in interface `IRotatable<PolyBezier>`
Parameters:
  `angle` - rotation `Angle`
  `center` - relative `Point` for the rotation
Returns:
  an `IGeometry` representing the result of the rotation

### intersects

public boolean intersects(ICurve c)
Description copied from interface: `ICurve`
Tests if this `ICurve` and the given `ICurve` intersect, i.e. whether a final set of intersection points exists. Two curves intersect if they touch (see `IGeometry.touches(IGeometry)`) but do not overlap (see `ICurve.overlaps(ICurve)`).

Specified by:
  `intersects` in interface `ICurve`
Parameters:
  `c` - The `ICurve` to test for intersections.
Returns:
  `true` if they intersect, `false` otherwise

### overlaps

public boolean overlaps(ICurve c)
Description copied from interface: `ICurve`
Tests if this `ICurve` and the given `ICurve` overlap, i.e. whether an infinite set of intersection points exists. Two curves overlap if they touch (see `IGeometry.touches(IGeometry)`) but not intersect (see `ICurve.intersects(ICurve)`).

Specified by:
  `overlaps` in interface `ICurve`
Parameters:
  `c` - The `ICurve` to test for overlap.
Returns:
  `true` if they overlap, `false` otherwise

### toBezier

public CubicCurve[] toBezier()
Description copied from interface: `ICurve`
Computes a list of `BezierCurve`s that approximate the `ICurve`. For example, a `Line` or a `BezierCurve` in general could return a list with the curve itself as its only element. But an `Ellipse` or an `Arc` may return a list of consecutive `BezierCurve`s which approximate the `ICurve`.

Specified by:
  `toBezier` in interface `ICurve`
Returns:
  a list of `BezierCurve`s that approximate the `ICurve`

### toString

public String toString()

Overrides:
  `toString` in class `Object`

### computeBezierApproximation

protected CubicCurve[] computeBezierApproximation()
Computes a `CubicCurve` approximation for this `AbstractArcBasedGeometry`. It is approximated by a maximum of four `CubicCurve`s, each of which covers a maximum of 90 degrees.

Returns:
  a `CubicCurve` approximation for this `AbstractArcBasedGeometry`

### getAngularExtent

public Angle getAngularExtent()
Returns the extension `Angle` of this `AbstractArcBasedGeometry`, i.e. the `Angle` defining the span of this `AbstractArcBasedGeometry`.

Returns:
  the extension `Angle` of this `AbstractArcBasedGeometry`

### getP1

public Point getP1()
Returns the start `Point` of this `AbstractArcBasedGeometry`.

Returns:
  the start `Point` of this `AbstractArcBasedGeometry`

### getP2

public Point getP2()
Returns the end `Point` of this `AbstractArcBasedGeometry`.

Returns:
  the end `Point` of this `AbstractArcBasedGeometry`

### getPoint

public Point getPoint(Angle angularExtent)
Computes a `Point` on this `AbstractArcBasedGeometry`. The `Point`'s coordinates are calculated by moving the given `Angle` on this `AbstractArcBasedGeometry` starting at this `AbstractArcBasedGeometry`'s start `Point`.

Parameters:
  `angularExtent` - the `Angle` to move from the start `Point` of this `AbstractArcBasedGeometry`
Returns:
  the `Point` at the given extension `Angle`

### getStartAngle

public Angle getStartAngle()
Returns this `AbstractArcBasedGeometry`'s start `Angle`.

Returns:
  this `AbstractArcBasedGeometry`'s start `Angle`

### getX1

public double getX1()
Returns the x coordinate of the start `Point` of this `AbstractArcBasedGeometry`.

Returns:
  the x coordinate of the start `Point` of this `AbstractArcBasedGeometry`

### getX2

public double getX2()
Returns the x coordinate of the end `Point` of this `AbstractArcBasedGeometry`.

Returns:
  the x coordinate of the end `Point` of this `AbstractArcBasedGeometry`

### getY1

public double getY1()
Returns the y coordinate of the start `Point` of this `AbstractArcBasedGeometry`.

Returns:
  the y coordinate of the start `Point` of this `AbstractArcBasedGeometry`

### getY2

public double getY2()
Returns the y coordinate of the end `Point` of this `AbstractArcBasedGeometry`.

Returns:
  the y coordinate of the end `Point` of this `AbstractArcBasedGeometry`

### setAngularExtent

public Arc setAngularExtent(Angle angularExtent)
Sets the extension `Angle` of this `AbstractArcBasedGeometry` .

Parameters:
  `angularExtent` - the new extension `Angle` for this `AbstractArcBasedGeometry`
Returns:
  `this` for convenience

### setStartAngle

public Arc setStartAngle(Angle startAngle)
Sets the start `Angle` of this `AbstractArcBasedGeometry`.

Parameters:
  `startAngle` - the new start `Angle` for this `AbstractArcBasedGeometry`
Returns:
  `this` for convenience

### toPath

public Path toPath()
Description copied from interface: `IGeometry`
Converts this `IGeometry` into a `Path` representation.

Returns:
  A new `Path` representation for this `IGeometry`.
See Also:
  - `IGeometry.toPath()`

### expand

public Arc expand(double h, double v)
Expands the horizontal and vertical sides of this `AbstractRectangleBasedGeometry` with the values provided as input, and returns `this` for convenience. The location of its center is kept constant.

Parameters:
  `h` - the horizontal increment
  `v` - the vertical increment
Returns:
  `this` for convenience

### expand

public Arc expand(double left, double top, double right, double bottom)
Expands this `AbstractRectangleBasedGeometry` by the given amounts, and returns this for convenience.

Parameters:
  `left` - the amount to expand the left side
  `top` - the amount to expand the top side
  `right` - the amount to expand the right side
  `bottom` - the amount to expand the bottom side
Returns:
  `this` for convenience

### getCenter

public Point getCenter()
Returns the center `Point` of this `AbstractRectangleBasedGeometry`.

Returns:
  the center `Point` of this `AbstractRectangleBasedGeometry`

### getExpanded

public Arc getExpanded(double h, double v)
Returns a new expanded `AbstractRectangleBasedGeometry`, where the sides are incremented by the horizontal and vertical values provided. The center of the `AbstractRectangleBasedGeometry` is maintained constant.

Parameters:
  `h` - The horizontal increment
  `v` - The vertical increment
Returns:
  a new expanded `AbstractRectangleBasedGeometry`

### getExpanded

public Arc getExpanded(double left, double top, double right, double bottom)
Creates and returns a new `AbstractRectangleBasedGeometry` with the bounds of this `AbstractRectangleBasedGeometry` expanded by the given insets.

Parameters:
  `left` - the amount to expand the left side
  `top` - the amount to expand the top side
  `right` - the amount to expand the right side
  `bottom` - the amount to expand the bottom side
Returns:
  a new expanded `AbstractRectangleBasedGeometry`

### getHeight

public final double getHeight()
Returns the height of this `AbstractRectangleBasedGeometry`.

Returns:
  the height of this `AbstractRectangleBasedGeometry`

### getLocation

public Point getLocation()
Returns a `Point` specifying the x and y coordinates of this `AbstractRectangleBasedGeometry`.

Returns:
  a `Point` representing the x and y coordinates of this `AbstractRectangleBasedGeometry`

### getScaled

public Arc getScaled(double factor)
Description copied from interface: `IScalable`
Scales a copy of the calling object by the given factor relative to its center `Point`.

Specified by:
  `getScaled` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `factor` - scale-factor
Returns:
  the new, scaled object

### getScaled

public Arc getScaled(double factorX, double factorY)
Description copied from interface: `IScalable`
Scales a copy of the calling object by the given factors relative to its center `Point`.

Specified by:
  `getScaled` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `factorX` - x-scale-factor
  `factorY` - y-scale-factor
Returns:
  the new, scaled object

### getScaled

public Arc getScaled(double factor, double centerX, double centerY)
Description copied from interface: `IScalable`
Scales a copy of the calling object by the given factor relative to the given center `Point` (cx, cy).

Specified by:
  `getScaled` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `factor` - scale-factor
  `centerX` - x-coordinate of the relative `Point` for the scaling
  `centerY` - y-coordinate of the relative `Point` for the scaling
Returns:
  the new, scaled object

### getScaled

public Arc getScaled(double factorX, double factorY, double centerX, double centerY)
Description copied from interface: `IScalable`
Scales a copy of the calling object by the given factors relative to the given center `Point` (cx, cy).

Specified by:
  `getScaled` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `factorX` - x-scale-factor
  `factorY` - y-scale-factor
  `centerX` - x-coordinate of the relative `Point` for the scaling
  `centerY` - y-coordinate of the relative `Point` for the scaling
Returns:
  the new, scaled object

### getScaled

public Arc getScaled(double factorX, double factorY, Point center)
Description copied from interface: `IScalable`
Scales a copy of the calling object by the given factors relative to the given center `Point`.

Specified by:
  `getScaled` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `factorX` - x-scale-factor
  `factorY` - y-scale-factor
  `center` - relative `Point` for the scaling
Returns:
  the new, scaled object

### getScaled

public Arc getScaled(double factor, Point center)
Description copied from interface: `IScalable`
Scales a copy of the calling object by the given factor relative to the given center `Point`.

Specified by:
  `getScaled` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `factor` - scale-factor
  `center` - relative `Point` for the scaling
Returns:
  the new, scaled object

### getShrinked

public Arc getShrinked(double h, double v)
Returns a new `AbstractRectangleBasedGeometry`, where the sides are shrinked by the horizontal and vertical values supplied. The center of this `AbstractRectangleBasedGeometry` is kept constant.

Parameters:
  `h` - horizontal reduction amount
  `v` - vertical reduction amount
Returns:
  a new, shrinked `AbstractRectangleBasedGeometry`

### getShrinked

public Arc getShrinked(double left, double top, double right, double bottom)
Returns a new `AbstractRectangleBasedGeometry` shrinked by the specified insets.

Parameters:
  `left` - the amount to shrink the left side
  `top` - the amount to shrink the top side
  `right` - the amount to shrink the right side
  `bottom` - the amount to shrink the bottom side
Returns:
  a new, shrinked `AbstractRectangleBasedGeometry`

### getSize

public final Dimension getSize()
Returns a `Dimension` that records the width and height of this `AbstractRectangleBasedGeometry`.

Returns:
  a `Dimension` that records the width and height of this `AbstractRectangleBasedGeometry`

### getTranslated

public Arc getTranslated(double dx, double dy)
Description copied from interface: `ITranslatable`
Translates a copy of this object by the given values in x and y direction.

Specified by:
  `getTranslated` in interface `ITranslatable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `dx` - x-translation
  `dy` - y-translation
Returns:
  a new, translated object

### getTranslated

public Arc getTranslated(Point pt)
Description copied from interface: `ITranslatable`
Translates a copy of this object by the given `Point`.

Specified by:
  `getTranslated` in interface `ITranslatable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `pt` - translation `Point`
Returns:
  a new, translated object

### getWidth

public final double getWidth()
Returns the width of this `AbstractRectangleBasedGeometry`.

Returns:
  the width of this `AbstractRectangleBasedGeometry`

### getX

public final double getX()
Returns the x coordinate this `AbstractRectangleBasedGeometry`.

Returns:
  the x coordinate this `AbstractRectangleBasedGeometry`

### getY

public final double getY()
Returns the y coordinate of this `AbstractRectangleBasedGeometry`.

Returns:
  the y coordinate of this `AbstractRectangleBasedGeometry`

### scale

public Arc scale(double factor)
Description copied from interface: `IScalable`
Scales the calling object by the given factor relative to its center `Point`.

Specified by:
  `scale` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `factor` - scale-factor
Returns:
  `this` for convenience

### scale

public Arc scale(double fx, double fy)
Description copied from interface: `IScalable`
Scales the calling object by the given factors relative to the given center `Point`.

Specified by:
  `scale` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `fx` - x-scale-factor
  `fy` - y-scale-factor
Returns:
  `this` for convenience

### scale

public Arc scale(double factor, double cx, double cy)
Description copied from interface: `IScalable`
Scales the calling object by the given factor relative to the given center `Point` (cx, cy).

Specified by:
  `scale` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `factor` - scale-factor
  `cx` - x-coordinate of the relative `Point` for the scaling
  `cy` - y-coordinate of the relative `Point` for the scaling
Returns:
  `this` for convenience

### scale

public Arc scale(double fx, double fy, double cx, double cy)
Description copied from interface: `IScalable`
Scales the calling object by the given factors relative to the given center `Point` (cx, cy).

Specified by:
  `scale` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `fx` - x-scale-factor
  `fy` - y-scale-factor
  `cx` - x-coordinate of the relative `Point` for the scaling
  `cy` - y-coordinate of the relative `Point` for the scaling
Returns:
  `this` for convenience

### scale

public Arc scale(double fx, double fy, Point center)
Description copied from interface: `IScalable`
Scales the calling object by the given factors relative to the given center `Point`.

Specified by:
  `scale` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `fx` - x-scale-factor
  `fy` - y-scale-factor
  `center` - relative `Point` for the scaling
Returns:
  `this` for convenience

### scale

public Arc scale(double factor, Point center)
Description copied from interface: `IScalable`
Scales the calling object by the given factor relative to the given center `Point`.

Specified by:
  `scale` in interface `IScalable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `factor` - scale-factor
  `center` - relative `Point` for the scaling
Returns:
  `this` for convenience

### setBounds

public final Arc setBounds(double x, double y, double w, double h)
Sets the x, y, width, and height values of this `AbstractRectangleBasedGeometry` to the given values.

Parameters:
  `x` - the new x-coordinate
  `y` - the new y-coordinate
  `w` - the new width
  `h` - the new height
Returns:
  `this` for convenience

### setBounds

public final Arc setBounds(Point loc, Dimension size)
Sets the x, y, width, and height values of this `AbstractRectangleBasedGeometry` to the respective values specified by the passed-in `Point` and the passed-in `Dimension`.

Parameters:
  `loc` - the `Point` specifying the new x and y coordinates of this `AbstractRectangleBasedGeometry`
  `size` - the `Dimension` specifying the new width and height of this `AbstractRectangleBasedGeometry`
Returns:
  `this` for convenience

### setBounds

public final Arc setBounds(Rectangle r)
Sets the x and y coordinates and the width and height of this `AbstractRectangleBasedGeometry` to the respective values of the given `Rectangle`.

Parameters:
  `r` - the `Rectangle` specifying the new x, y, width, and height values of this `AbstractRectangleBasedGeometry`
Returns:
  `this` for convenience

### setHeight

public final Arc setHeight(double height)
Sets the height of this `AbstractRectangleBasedGeometry` to the given value.

Parameters:
  `height` - the new height
Returns:
  `this` for convenience

### setLocation

public final Arc setLocation(double x, double y)
Sets the x and y coordinates of this `AbstractRectangleBasedGeometry` to the specified values.

Parameters:
  `x` - the new x coordinate of this `AbstractRectangleBasedGeometry`
  `y` - the new y coordinate of this `AbstractRectangleBasedGeometry`
Returns:
  `this` for convenience

### setLocation

public final Arc setLocation(Point p)
Sets the x and y coordinates of this `AbstractRectangleBasedGeometry` to the respective values of the given `Point`.

Parameters:
  `p` - the `Point` specifying the new x and y coordinates of this `AbstractRectangleBasedGeometry`
Returns:
  `this` for convenience

### setSize

public final Arc setSize(Dimension d)
Sets the width and height of this `AbstractRectangleBasedGeometry` to the width and height of the given `Dimension`.

Parameters:
  `d` - the `Dimension` specifying the new width and height of this `AbstractRectangleBasedGeometry`
Returns:
  `this` for convenience

### setSize

public final Arc setSize(double w, double h)
Sets the width and height of this `AbstractRectangleBasedGeometry` to the given values.

Parameters:
  `w` - the new width of this `AbstractRectangleBasedGeometry`
  `h` - the new height of this `AbstractRectangleBasedGeometry`
Returns:
  `this` for convenience

### setWidth

public final Arc setWidth(double width)
Sets the width of this `AbstractRectangleBasedGeometry` to the passed-in value.

Parameters:
  `width` - the new width of this `AbstractRectangleBasedGeometry`
Returns:
  `this` for convenience

### setX

public final Arc setX(double x)
Sets the x-coordinate of this `AbstractRectangleBasedGeometry` to the given value.

Parameters:
  `x` - The new x-coordinate.
Returns:
  `this` for convenience.

### setY

public final Arc setY(double y)
Sets the y-coordinate of this `AbstractRectangleBasedGeometry` to the given value.

Parameters:
  `y` - The new y-coordinate.
Returns:
  `this` for convenience.

### shrink

public Arc shrink(double h, double v)
Shrinks the sides of this `AbstractRectangleBasedGeometry` by the horizontal and vertical values provided as input, and returns this `AbstractRectangleBasedGeometry` for convenience. The center of this `AbstractRectangleBasedGeometry` is kept constant.

Parameters:
  `h` - horizontal reduction amount
  `v` - vertical reduction amount
Returns:
  `this` for convenience

### shrink

public Arc shrink(double left, double top, double right, double bottom)
Shrinks this `AbstractRectangleBasedGeometry` by the specified amounts.

Parameters:
  `left` - the amount to shrink the left side
  `top` - the amount to shrink the top side
  `right` - the amount to shrink the right side
  `bottom` - the amount to shrink the bottom side
Returns:
  `this` for convenience

### translate

public Arc translate(double dx, double dy)
Description copied from interface: `ITranslatable`
Translates the object by the given values in x and y direction.

Specified by:
  `translate` in interface `ITranslatable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `dx` - x-translation
  `dy` - y-translation
Returns:
  `this` for convenience

### translate

public Arc translate(Point p)
Description copied from interface: `ITranslatable`
Translates the object by the given `Point`.

Specified by:
  `translate` in interface `ITranslatable<T extends org.eclipse.gef.geometry.planar.AbstractRectangleBasedGeometry<?,?>>`
Parameters:
  `p` - translation `Point`
Returns:
  `this` for convenience

### clone

public Object clone()
Overridden with public visibility as recommended within `Cloneable` .

Overrides:
  `clone` in class `Object`

### getTransformed

public IGeometry getTransformed(AffineTransform t)
Default implementation returning a transformed `Path` representation of this `IGeometry`. Subclasses may override this method to return a more specific representation.

Specified by:
  `getTransformed` in interface `IGeometry`
Parameters:
  `t` - The `AffineTransform` to be applied
Returns:
  a transformed `Path` representation of this `IGeometry`

### hashCode

public final int hashCode()

Overrides:
  `hashCode` in class `Object`
See Also:
  - `Object.hashCode()`

### touches

public boolean touches(IGeometry g)
Description copied from interface: `IGeometry`
Returns `true` if the input `IGeometry` touches this `IGeometry`, i.e. there is at least one common point.

Specified by:
  `touches` in interface `IGeometry`
Parameters:
  `g` - The `IGeometry` for the intersection test
Returns:
  `true` if the input `IGeometry` and this `IGeometry` have at least one common point.