|
GeoAPI 1.0 Build 2004-05-18 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Defines a common abstraction for general implementations of aggregated Graphics.
The abstraction assumes that each of the Graphics are each topologically open
and the ordered aggregation is piecewise continuous in the zeroith degree, i.e. piecewise,
the endpoint of one Graphic is the same location as the startpoint of the next
Graphic in the order.
If the endpoint of the last Graphic in the aggregation
is in the same location as the startpoint of the first Graphic,
then the GraphicCompositeCurve is closed, and the
isClosed() method returns true. Otherwise this method returns
false.
The abstraction makes no assumptions as to thread safety. If the implementations of
Graphic are to be used in a multi-threaded environment, the implementation
will have to address thread safety by synchronizing methods or by invoking all methods
from a single thread.
| Method Summary | |
|---|---|
void |
addAggregationListener(AggregationListener listener)
Adds the given AggregationListener to this
GraphicCompositeCurve's list of listeners. |
Graphic |
addSegment(Graphic segment)
Adds the given segment to this GraphicCompositeCurve. |
void |
aggregationChanged(AggregationChangeEvent event)
Calls the aggregationChanged() method of all AggregationListeners
in this GraphicCompositeCurve's list of listeners. |
CompositeCurve |
getCompositeCurve()
Returns the ISO 19107 CompositeCurve geometry for this Graphic |
Graphic |
getSegment(int index)
Retrieves the segment Graphic at the given index. |
int |
getSegmentCount()
Returns the number of segments currently assigned to this GraphicCompositeCurve. |
Graphic[] |
getSegments()
Returns the segments of this GraphicCompositeCurve. |
Graphic |
insertSegment(int index,
Graphic segment)
Adds a segment into this composite curve, inserting it before the segment at the given index. |
boolean |
isClosed()
Returns whether this composite curve is topologically closed. |
boolean |
isValid()
Returns whether the GraphicCompositeCurve is continuous. |
void |
removeAggregationListener(AggregationListener listener)
Removes the given AggregationListener from this
GraphicCompositeCurve's list of listeners. |
Graphic |
removeSegment(Graphic segment)
Removes the given segment from this GraphicCompositeCurve. |
Graphic |
removeSegment(int index)
Removes the segment at the given index. |
void |
removeSegments()
Removes all of the segments from this GraphicCompositeCurve. |
Graphic |
replaceSegment(Graphic oldSegment,
Graphic newSegment)
Replaces the oldSegment with the newSegment. |
void |
setCompositeCurve(CompositeCurve compositeCurve)
Sets the geometry based on ISO 19107 CompositeCurve geometry for this Graphic. |
void |
setSegments(Graphic[] segments)
Sets the segments of this GraphicCompositeCurve to the given
set of Graphics. |
| Method Detail |
|---|
void setCompositeCurve(CompositeCurve compositeCurve)
throws GeometryNotSupportedException
CompositeCurve geometry for this Graphic.
compositeCurve - the CompositeCurve for this Graphic.
GeometryNotSupportedExceptionCompositeCurve getCompositeCurve()
CompositeCurve geometry for this Graphic
boolean isClosed()
Graphic in the aggregation
is in the same location as the startpoint of the first Graphic,
then the GraphicCompositeCurve is closed, and the
isClosed() method returns true. Otherwise this method returns
false.
void setSegments(Graphic[] segments)
GraphicCompositeCurve to the given
set of Graphics. If there are already segments assigned,
then those segments will be removed and their parent will be set to
null.
segments - the new segments of the GraphicCompositeCurve.
Graphic replaceSegment(Graphic oldSegment,
Graphic newSegment)
oldSegment - the segment to be replaced.newSegment - the segment to be added in its place.
void removeSegments()
GraphicCompositeCurve.
Graphic removeSegment(Graphic segment)
GraphicCompositeCurve.
segment - the Graphic segment to remove from the
composite curve.
Graphic, or null if it is not found.Graphic removeSegment(int index)
index -
boolean isValid()
GraphicCompositeCurve is continuous.
If all Graphics in the aggregation are each topologically
open and the ordered aggregation is piecewise continuous in degree zero,
then the GraphicCompositeCurve is valid, and this method returns
true. Otherwise this method returns false.
GraphicCompositeCurve is continuous.
Graphic insertSegment(int index,
Graphic segment)
index - Index where the new segment will be added.segment - New segment Graphic to add.
Graphic[] getSegments()
GraphicCompositeCurve. If no
segments are assigned, the method returns an empty array.
Graphics of the GraphicCompositeCurve.int getSegmentCount()
GraphicCompositeCurve.
Graphic getSegment(int index)
index - the index of the segment of interest.
Graphic addSegment(Graphic segment)
GraphicCompositeCurve.
segment - Graphic segment to add to the composite curve.
Graphic.void addAggregationListener(AggregationListener listener)
AggregationListener to this
GraphicCompositeCurve's list of listeners. The listeners will
be notified if this GraphicCompositeCurve adds or removes any elements.
listener - the AggregationListener to be added.void removeAggregationListener(AggregationListener listener)
AggregationListener from this
GraphicCompositeCurve's list of listeners.
listener - the AggregationListener to be removed.void aggregationChanged(AggregationChangeEvent event)
aggregationChanged() method of all AggregationListeners
in this GraphicCompositeCurve's list of listeners. This method is called when any
elements are added, removed, or reorderd in this GraphicCompositeCurve.
event - the AggregationChangedEvent to give to the listeners.
|
GeoAPI 1.0 Build 2004-05-18 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
|
Symbols, terms and definitions | Copyright OpenGIS® Consortium |