Package org.eclipse.birt.chart.model.attribute.impl

# Class BoundsImpl

java.lang.Object
org.eclipse.emf.common.notify.impl.BasicNotifierImpl
org.eclipse.emf.ecore.impl.BasicEObjectImpl
org.eclipse.emf.ecore.impl.EObjectImpl
org.eclipse.birt.chart.model.attribute.impl.BoundsImpl

All Implemented Interfaces:
  `Bounds`, `IChartObject`, `org.eclipse.emf.common.notify.Notifier`, `org.eclipse.emf.ecore.EObject`, `org.eclipse.emf.ecore.InternalEObject`

public class BoundsImpl extends org.eclipse.emf.ecore.impl.EObjectImpl implements Bounds
An implementation of the model object ' Bounds'.

The following features are implemented:

- `Left`
- `Top`
- `Width`
- `Height`

## Nested Class Summary

## Nested classes/interfaces inherited from class org.eclipse.emf.common.notify.impl.BasicNotifierImpl

`org.eclipse.emf.common.notify.impl.BasicNotifierImpl.EAdapterList<E extends Object & org.eclipse.emf.common.notify.Adapter>, org.eclipse.emf.common.notify.impl.BasicNotifierImpl.EObservableAdapterList, org.eclipse.emf.common.notify.impl.BasicNotifierImpl.EScannableAdapterList`

## Nested classes/interfaces inherited from interface org.eclipse.emf.ecore.InternalEObject

`org.eclipse.emf.ecore.InternalEObject.EStore`

## Field Summary

### Fields inherited from class org.eclipse.emf.ecore.impl.EObjectImpl

`ELAST_EOBJECT_FLAG`

### Fields inherited from interface org.eclipse.emf.ecore.InternalEObject

`EOPPOSITE_FEATURE_BASE`

## Method Summary

Modifier and Type
Method
Description
`void`
`adjust(Insets ins)`
Causes the internal (left,right,width,height) values to be scaled by a the specified Insets
`final Bounds`
`adjustedInstance(Insets ins)`
Creates a new 'Bounds' instance by adjusting the existing 'Bounds' instance using the given 'Insets' NOTE: Manually written
`boolean`
`contains(Location lo)`
Returns if the given point is within this bounds.
`Bounds`
`copyInstance()`
A convenient method to get an instance copy.
`static final Bounds`
`create(double dLeft, double dTop, double dWidth, double dHeight)`
Convenient creation of a Bounds object and instantiates member variables NOTE: Manually written
`static final Bounds`
`createDefault(double dLeft, double dTop, double dWidth, double dHeight)`
Convenient creation of a Bounds object and instantiates member variables NOTE: Manually written
`final void`
`delta(double dLeft, double dTop, double dWidth, double dHeight)`
Adds a 'delta' value to the existing member variables and applies it to the current instance
`Object`
`eGet(int featureID, boolean resolve, boolean coreType)`
`boolean`
`eIsSet(int featureID)`
`void`
`eSet(int featureID, Object newValue)`
`void`
`eUnset(int featureID)`
`double`
`getHeight()`
`double`
`getLeft()`
`double`
`getTop()`
`double`
`getWidth()`
`boolean`
`isSetHeight()`
`boolean`
`isSetLeft()`
`boolean`
`isSetTop()`
`boolean`
`isSetWidth()`
`final void`
`max(Bounds bo)`
`final void`
`scale(double dScale)`
Causes the internal (left,right,width,height) values to be scaled by a relative (dScale) value
`final Bounds`
`scaledInstance(double dScale)`
Returns a new Bounds instance with scaled members
`void`
`set(double dLeft, double dTop, double dWidth, double dHeight)`
A convenient method that allows initializing member variables.
`void`
`setHeight(double newHeight)`
`void`
`setLeft(double newLeft)`
`void`
`setTop(double newTop)`
`void`
`setWidth(double newWidth)`
`String`
`toString()`
`final void`
`translate(double dTranslateX, double dTranslateY)`
Causes the internal (left,right) location to be translated by a relative value of (dTranslateX, dTranslateY)
`final Bounds`
`translateInstance(double dTranslateX, double dTranslateY)`
Creates a new 'Bounds' instance by translate the existing 'Bounds' instance using given offsets.
`void`
`unsetHeight()`
`void`
`unsetLeft()`
`void`
`unsetTop()`
`void`
`unsetWidth()`
`void`
`updateFrom(Location[] loa)`
Updates an existing Bounds instance to encompass the polygon specified by a given set of points

### Methods inherited from class org.eclipse.emf.ecore.impl.EObjectImpl

`eAdapters, eClass, eContainerFeatureID, eDeliver, eInternalContainer, eInvoke, eIsProxy, eSetClass, eSetDeliver, eSetProxyURI`

### Methods inherited from class org.eclipse.emf.ecore.impl.BasicEObjectImpl

`eAllContents, eBaseStructuralFeatureID, eBasicRemoveFromContainer, eBasicRemoveFromContainerFeature, eBasicSetContainer, eContainer, eContainingFeature, eContainmentFeature, eContains, eContents, eCrossReferences, eDerivedOperationID, eDerivedOperationID, eDerivedStructuralFeatureID, eDerivedStructuralFeatureID, eDirectResource, eDynamicBasicRemoveFromContainer, eDynamicGet, eDynamicGet, eDynamicInverseAdd, eDynamicInverseRemove, eDynamicInvoke, eDynamicIsSet, eDynamicIsSet, eDynamicSet, eDynamicSet, eDynamicUnset, eDynamicUnset, eGet, eGet, eGet, eInternalResource, eInverseAdd, eInverseAdd, eInverseRemove, eInverseRemove, eInvoke, eIsSet, eObjectForURIFragmentSegment, eOpenGet, eOpenIsSet, eOpenSet, eOpenUnset, eProxyURI, eResolveProxy, eResource, eSet, eSetResource, eSetStore, eSetting, eStore, eUnset, eURIFragmentSegment, eVirtualGet, eVirtualGet, eVirtualIsSet, eVirtualSet, eVirtualUnset`

### Methods inherited from class org.eclipse.emf.common.notify.impl.BasicNotifierImpl

`eNotificationRequired, eNotify`

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

`equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Methods inherited from interface org.eclipse.emf.ecore.EObject

`eAllContents, eClass, eContainer, eContainingFeature, eContainmentFeature, eContents, eCrossReferences, eGet, eGet, eInvoke, eIsProxy, eIsSet, eResource, eSet, eUnset`

### Methods inherited from interface org.eclipse.emf.ecore.InternalEObject

`eNotificationRequired`

### Methods inherited from interface org.eclipse.emf.common.notify.Notifier

`eAdapters, eDeliver, eNotify, eSetDeliver`

## Method Details

### getLeft

public double getLeft()

Specified by:
  `getLeft` in interface `Bounds`
Returns:
  the value of the 'Left' attribute.
See Also:
  - `Bounds.isSetLeft()`
  - `Bounds.unsetLeft()`
  - `Bounds.setLeft(double)`
  - `AttributePackage.getBounds_Left()`

### setLeft

public void setLeft(double newLeft)

Specified by:
  `setLeft` in interface `Bounds`
Parameters:
  `newLeft` - the new value of the 'Left' attribute.
See Also:
  - `Bounds.isSetLeft()`
  - `Bounds.unsetLeft()`
  - `Bounds.getLeft()`

### unsetLeft

public void unsetLeft()

Specified by:
  `unsetLeft` in interface `Bounds`
See Also:
  - `Bounds.isSetLeft()`
  - `Bounds.getLeft()`
  - `Bounds.setLeft(double)`

### isSetLeft

public boolean isSetLeft()

Specified by:
  `isSetLeft` in interface `Bounds`
Returns:
  whether the value of the 'Left' attribute is set.
See Also:
  - `Bounds.unsetLeft()`
  - `Bounds.getLeft()`
  - `Bounds.setLeft(double)`

### getTop

public double getTop()

Specified by:
  `getTop` in interface `Bounds`
Returns:
  the value of the 'Top' attribute.
See Also:
  - `Bounds.isSetTop()`
  - `Bounds.unsetTop()`
  - `Bounds.setTop(double)`
  - `AttributePackage.getBounds_Top()`

### setTop

public void setTop(double newTop)

Specified by:
  `setTop` in interface `Bounds`
Parameters:
  `newTop` - the new value of the 'Top' attribute.
See Also:
  - `Bounds.isSetTop()`
  - `Bounds.unsetTop()`
  - `Bounds.getTop()`

### unsetTop

public void unsetTop()

Specified by:
  `unsetTop` in interface `Bounds`
See Also:
  - `Bounds.isSetTop()`
  - `Bounds.getTop()`
  - `Bounds.setTop(double)`

### isSetTop

public boolean isSetTop()

Specified by:
  `isSetTop` in interface `Bounds`
Returns:
  whether the value of the 'Top' attribute is set.
See Also:
  - `Bounds.unsetTop()`
  - `Bounds.getTop()`
  - `Bounds.setTop(double)`

### getWidth

public double getWidth()

Specified by:
  `getWidth` in interface `Bounds`
Returns:
  the value of the 'Width' attribute.
See Also:
  - `Bounds.isSetWidth()`
  - `Bounds.unsetWidth()`
  - `Bounds.setWidth(double)`
  - `AttributePackage.getBounds_Width()`

### setWidth

public void setWidth(double newWidth)

Specified by:
  `setWidth` in interface `Bounds`
Parameters:
  `newWidth` - the new value of the 'Width' attribute.
See Also:
  - `Bounds.isSetWidth()`
  - `Bounds.unsetWidth()`
  - `Bounds.getWidth()`

### unsetWidth

public void unsetWidth()

Specified by:
  `unsetWidth` in interface `Bounds`
See Also:
  - `Bounds.isSetWidth()`
  - `Bounds.getWidth()`
  - `Bounds.setWidth(double)`

### isSetWidth

public boolean isSetWidth()

Specified by:
  `isSetWidth` in interface `Bounds`
Returns:
  whether the value of the 'Width' attribute is set.
See Also:
  - `Bounds.unsetWidth()`
  - `Bounds.getWidth()`
  - `Bounds.setWidth(double)`

### getHeight

public double getHeight()

Specified by:
  `getHeight` in interface `Bounds`
Returns:
  the value of the 'Height' attribute.
See Also:
  - `Bounds.isSetHeight()`
  - `Bounds.unsetHeight()`
  - `Bounds.setHeight(double)`
  - `AttributePackage.getBounds_Height()`

### setHeight

public void setHeight(double newHeight)

Specified by:
  `setHeight` in interface `Bounds`
Parameters:
  `newHeight` - the new value of the 'Height' attribute.
See Also:
  - `Bounds.isSetHeight()`
  - `Bounds.unsetHeight()`
  - `Bounds.getHeight()`

### unsetHeight

public void unsetHeight()

Specified by:
  `unsetHeight` in interface `Bounds`
See Also:
  - `Bounds.isSetHeight()`
  - `Bounds.getHeight()`
  - `Bounds.setHeight(double)`

### isSetHeight

public boolean isSetHeight()

Specified by:
  `isSetHeight` in interface `Bounds`
Returns:
  whether the value of the 'Height' attribute is set.
See Also:
  - `Bounds.unsetHeight()`
  - `Bounds.getHeight()`
  - `Bounds.setHeight(double)`

### eGet

public Object eGet(int featureID, boolean resolve, boolean coreType)

Specified by:
  `eGet` in interface `org.eclipse.emf.ecore.InternalEObject`
Overrides:
  `eGet` in class `org.eclipse.emf.ecore.impl.BasicEObjectImpl`

### eSet

public void eSet(int featureID, Object newValue)

Specified by:
  `eSet` in interface `org.eclipse.emf.ecore.InternalEObject`
Overrides:
  `eSet` in class `org.eclipse.emf.ecore.impl.BasicEObjectImpl`

### eUnset

public void eUnset(int featureID)

Specified by:
  `eUnset` in interface `org.eclipse.emf.ecore.InternalEObject`
Overrides:
  `eUnset` in class `org.eclipse.emf.ecore.impl.BasicEObjectImpl`

### eIsSet

public boolean eIsSet(int featureID)

Specified by:
  `eIsSet` in interface `org.eclipse.emf.ecore.InternalEObject`
Overrides:
  `eIsSet` in class `org.eclipse.emf.ecore.impl.BasicEObjectImpl`

### toString

public String toString()

Overrides:
  `toString` in class `org.eclipse.emf.ecore.impl.BasicEObjectImpl`

### set

public void set(double dLeft, double dTop, double dWidth, double dHeight)
A convenient method that allows initializing member variables. Note: Manually written, no EMF notifying!

Specified by:
  `set` in interface `Bounds`
Parameters:
  `dLeft` -
  `dTop` -
  `dWidth` -
  `dHeight` -

### create

public static final Bounds create(double dLeft, double dTop, double dWidth, double dHeight)
Convenient creation of a Bounds object and instantiates member variables NOTE: Manually written

Parameters:
  `dLeft` -
  `dTop` -
  `dWidth` -
  `dHeight` -
Returns:

### createDefault

public static final Bounds createDefault(double dLeft, double dTop, double dWidth, double dHeight)
Convenient creation of a Bounds object and instantiates member variables NOTE: Manually written

Parameters:
  `dLeft` -
  `dTop` -
  `dWidth` -
  `dHeight` -
Returns:

### adjustedInstance

public final Bounds adjustedInstance(Insets ins)
Creates a new 'Bounds' instance by adjusting the existing 'Bounds' instance using the given 'Insets' NOTE: Manually written

Specified by:
  `adjustedInstance` in interface `Bounds`
Parameters:
  `ins` -
Returns:

### translateInstance

public final Bounds translateInstance(double dTranslateX, double dTranslateY)
Creates a new 'Bounds' instance by translate the existing 'Bounds' instance using given offsets.

Specified by:
  `translateInstance` in interface `Bounds`
Parameters:
  `dTranslateX` -
  `dTranslateY` -
Returns:

### delta

public final void delta(double dLeft, double dTop, double dWidth, double dHeight)
Description copied from interface: `Bounds`
Adds a 'delta' value to the existing member variables and applies it to the current instance

Specified by:
  `delta` in interface `Bounds`

### translate

public final void translate(double dTranslateX, double dTranslateY)
Description copied from interface: `Bounds`
Causes the internal (left,right) location to be translated by a relative value of (dTranslateX, dTranslateY)

Specified by:
  `translate` in interface `Bounds`

### scale

public final void scale(double dScale)
Description copied from interface: `Bounds`
Causes the internal (left,right,width,height) values to be scaled by a relative (dScale) value

Specified by:
  `scale` in interface `Bounds`

### scaledInstance

public final Bounds scaledInstance(double dScale)
Description copied from interface: `Bounds`
Returns a new Bounds instance with scaled members

Specified by:
  `scaledInstance` in interface `Bounds`
Parameters:
  `dScale` - The scaling factor
Returns:
  A new scaled instance

### adjust

public void adjust(Insets ins)
Description copied from interface: `Bounds`
Causes the internal (left,right,width,height) values to be scaled by a the specified Insets

Specified by:
  `adjust` in interface `Bounds`

### updateFrom

public void updateFrom(Location[] loa)
Description copied from interface: `Bounds`
Updates an existing Bounds instance to encompass the polygon specified by a given set of points

Specified by:
  `updateFrom` in interface `Bounds`

### max

public final void max(Bounds bo)

Specified by:
  `max` in interface `Bounds`
Parameters:
  `bo` -

### contains

public boolean contains(Location lo)
Description copied from interface: `Bounds`
Returns if the given point is within this bounds.

Specified by:
  `contains` in interface `Bounds`
Returns:

### copyInstance

public Bounds copyInstance()
A convenient method to get an instance copy. This is much faster than the ECoreUtil.copy().

Specified by:
  `copyInstance` in interface `Bounds`
Specified by:
  `copyInstance` in interface `IChartObject`