Package com.luciad.view.lightspeed.query
Class TLspPaintedObjectsBoundsQuery
java.lang.Object
com.luciad.view.lightspeed.query.ALspPaintQuery<Collection<ALspBoundsInfo>>
com.luciad.view.lightspeed.query.TLspPaintedObjectsBoundsQuery
Query to retrieve the bounds of all objects that are painted and overlap with a specified view
region.
This query only takes the objects that are currently painted into account.
The
bounds(com.luciad.view.lightspeed.layer.ALspWorldBoundsInfo)
methods may be called multiple times for the same object if it has multiple
bounds. This implementation collects all bounds.- Since:
- 2012.0
- See Also:
-
Constructor Summary
ConstructorDescriptionTLspPaintedObjectsBoundsQuery
(TLspPaintRepresentationState aPaintRepresentationState, ILcdBounds aViewBounds, double aSensitivity) Creates a new objects bounds query.TLspPaintedObjectsBoundsQuery
(TLspPaintRepresentationState aPaintRepresentationState, ILcdPoint aViewPoint, double aSensitivity) Creates a new objects bounds query. -
Method Summary
Modifier and TypeMethodDescriptionboolean
bounds
(ALspViewBoundsInfo aBoundsInfo) Called for all objects with view bounds.boolean
bounds
(ALspWorldBoundsInfo aBoundsInfo) Called for all objects with world bounds.Returns the paint representation state that should be queried.Returns the bounds infos of all objects.double
Returns the sensitivity in pixels.Returns the view bounds that should be queried ornull
if unrestricted.
-
Constructor Details
-
TLspPaintedObjectsBoundsQuery
public TLspPaintedObjectsBoundsQuery(TLspPaintRepresentationState aPaintRepresentationState, ILcdPoint aViewPoint, double aSensitivity) Creates a new objects bounds query.- Parameters:
aPaintRepresentationState
- the paint representation stateaViewPoint
- the view pointaSensitivity
- the sensitivity
-
TLspPaintedObjectsBoundsQuery
public TLspPaintedObjectsBoundsQuery(TLspPaintRepresentationState aPaintRepresentationState, ILcdBounds aViewBounds, double aSensitivity) Creates a new objects bounds query.- Parameters:
aPaintRepresentationState
- the paint representation stateaViewBounds
- the view bounds ornull
if unrestrictedaSensitivity
- the sensitivity
-
-
Method Details
-
getPaintRepresentationState
Returns the paint representation state that should be queried.- Returns:
- the paint representation state
-
getViewBounds
Returns the view bounds that should be queried ornull
if unrestricted.- Returns:
- the view bounds or
null
-
getSensitivity
public double getSensitivity()Returns the sensitivity in pixels.- Returns:
- the sensitivity
-
getResult
Returns the bounds infos of all objects.- Specified by:
getResult
in classALspPaintQuery<Collection<ALspBoundsInfo>>
- Returns:
- the bounds infos, never
null
.
-
bounds
Called for all objects with world bounds. Note that theaBoundsInfo
may change after this method call returns. The implementation can create aALspBoundsInfo.clone()
if it still needs it after the method call returns.- Parameters:
aBoundsInfo
- the bounds info- Returns:
true
if the query should continue,false
if it should stop
-
bounds
Called for all objects with view bounds. Note that theaBoundsInfo
may change after this method call returns. The implementation can create aALspBoundsInfo.clone()
if it still needs it after the method call returns.- Parameters:
aBoundsInfo
- the bounds info- Returns:
true
if the query should continue,false
if it should stop
-