Class GeoElementLineOfSight
GeoElement
objects.
GeoElementLineOfSight renders a line between an observer GeoElement
and a target GeoElement
(each using Point geometry).
Visible and obstructed portions of the line are displayed with unique colors (green and red by default).
The observer and/or target GeoElements may be moving, in which case visibility will be dynamically updated.
Supported GeoElement
types are Graphic
,
Feature
, and DynamicEntity
.
- Since:
- 10.2.0
-
Property Summary
Properties inherited from class com.esri.arcgisruntime.geoanalysis.LineOfSight
obstructedColor, visibleColor
-
Nested Class Summary
Nested classes/interfaces inherited from class com.esri.arcgisruntime.geoanalysis.LineOfSight
LineOfSight.TargetVisibility, LineOfSight.TargetVisibilityChangedEvent, LineOfSight.TargetVisibilityChangedListener
-
Constructor Summary
ConstructorDescriptionGeoElementLineOfSight
(GeoElement observerGeoElement, GeoElement targetGeoElement) Creates a LineOfSight analysis object that defines an observer and a target using pointGeoElement
objects. -
Method Summary
Modifier and TypeMethodDescriptionGets the observerGeoElement
of the GeoElementLineOfSight.double
Gets the location offset applied to the observerGeoElement
in the X direction.double
Gets the location offset applied to the observerGeoElement
in the Y direction.double
Gets the location offset applied to the observerGeoElement
in the Z direction.The targetGeoElement
of the GeoElementLineOfSight.double
Get the location offset applied to the targetGeoElement
in the X direction.double
Gets the location offset applied to the targetGeoElement
in the Y direction.double
Gets the location offset applied to the targetGeoElement
in the Z direction.void
setObserverOffsetX
(double observerOffsetX) Sets the location offset applied to the observerGeoElement
in the X direction.void
setObserverOffsetY
(double observerOffsetY) Sets the location offset applied to the observerGeoElement
in the Y direction.void
setObserverOffsetZ
(double observerOffsetZ) Sets the location offset applied to the observerGeoElement
in the Z direction.void
setTargetOffsetX
(double targetOffsetX) Sets the location offset applied to the targetGeoElement
in the X direction.void
setTargetOffsetY
(double targetOffsetY) Sets the location offset applied to the targetGeoElement
in the Y direction.void
setTargetOffsetZ
(double targetOffsetZ) Sets the location offset applied to the targetGeoElement
in the Z direction.Methods inherited from class com.esri.arcgisruntime.geoanalysis.LineOfSight
addTargetVisibilityChangedListener, getLineWidth, getObstructedColor, getTargetVisibility, getVisibleColor, obstructedColorProperty, removeTargetVisibilityChangedListener, setLineWidth, setObstructedColor, setObstructedColor, setVisibleColor, setVisibleColor, visibleColorProperty
Methods inherited from class com.esri.arcgisruntime.geoanalysis.Analysis
isVisible, setVisible
-
Constructor Details
-
GeoElementLineOfSight
Creates a LineOfSight analysis object that defines an observer and a target using pointGeoElement
objects.The LineOfSight analysis result is a line rendered between the observer and target elements with distinct colors representing visible and obstructed segments. Supported
GeoElement
types areGraphic
,Feature
, andDynamicEntity
.- Parameters:
observerGeoElement
- aGeoElement
that defines the observertargetGeoElement
- aGeoElement
that defines the target- Throws:
IllegalArgumentException
- if observerGeoElement is nullIllegalArgumentException
- if targetGeoElement is null- Since:
- 10.2.0
-
-
Method Details
-
getObserverGeoElement
Gets the observerGeoElement
of the GeoElementLineOfSight.The observer
GeoElement
must have point geometry. SupportedGeoElement
types areGraphic
,Feature
, andDynamicEntity
.- Returns:
- the observer GeoElement
- Since:
- 10.2.0
-
getObserverOffsetX
public double getObserverOffsetX()Gets the location offset applied to the observerGeoElement
in the X direction.The observer location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the observer relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Returns:
- the observer's location offset from the GeoElement's location along the x-axis
- Since:
- 100.2.0
-
setObserverOffsetX
public void setObserverOffsetX(double observerOffsetX) Sets the location offset applied to the observerGeoElement
in the X direction.The observer location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the observer relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Parameters:
observerOffsetX
- the observer's offset from the from GeoElement's location along the x-axis- Since:
- 100.2.0
-
getObserverOffsetY
public double getObserverOffsetY()Gets the location offset applied to the observerGeoElement
in the Y direction.The observer location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the observer relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Returns:
- the observer's offset from the GeoElement's location along the y-axis
- Since:
- 100.2.0
-
setObserverOffsetY
public void setObserverOffsetY(double observerOffsetY) Sets the location offset applied to the observerGeoElement
in the Y direction.The observer location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the observer relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Parameters:
observerOffsetY
- the observer's offset from the from GeoElement's location along the y-axis- Since:
- 100.2.0
-
getObserverOffsetZ
public double getObserverOffsetZ()Gets the location offset applied to the observerGeoElement
in the Z direction.The observer location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the observer relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Returns:
- the observer's offset from the GeoElement's location along the z-axis
- Since:
- 100.2.0
-
setObserverOffsetZ
public void setObserverOffsetZ(double observerOffsetZ) Sets the location offset applied to the observerGeoElement
in the Z direction.The observer location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the observer relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Parameters:
observerOffsetZ
- the observer's offset from the from GeoElement's location along the z-axis- Since:
- 100.2.0
-
getTargetGeoElement
The targetGeoElement
of the GeoElementLineOfSight.The target
GeoElement
must have point geometry. SupportedGeoElement
types areGraphic
,Feature
, andDynamicEntity
.- Returns:
- the target GeoElement
- Since:
- 10.2.0
-
getTargetOffsetX
public double getTargetOffsetX()Get the location offset applied to the targetGeoElement
in the X direction.The target location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the target relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Returns:
- the target's offset from the GeoElement's location along the x-axis
- Since:
- 100.2.0
-
setTargetOffsetX
public void setTargetOffsetX(double targetOffsetX) Sets the location offset applied to the targetGeoElement
in the X direction.The target location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the target relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Parameters:
targetOffsetX
- the target's offset from the GeoElement's location along the x-axis- Since:
- 100.2.0
-
getTargetOffsetY
public double getTargetOffsetY()Gets the location offset applied to the targetGeoElement
in the Y direction.The target location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the target relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Returns:
- the target's offset from the GeoElement's location along the y-axis
- Since:
- 100.2.0
-
setTargetOffsetY
public void setTargetOffsetY(double targetOffsetY) Sets the location offset applied to the targetGeoElement
in the Y direction.The target location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the target relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Parameters:
targetOffsetY
- the target's offset from the GeoElement's location along the y-axis- Since:
- 100.2.0
-
getTargetOffsetZ
public double getTargetOffsetZ()Gets the location offset applied to the targetGeoElement
in the Z direction.The target location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the target relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Returns:
- the target's offset from the GeoElement's location along the z-axis
- Since:
- 100.2.0
-
setTargetOffsetZ
public void setTargetOffsetZ(double targetOffsetZ) Sets the location offset applied to the targetGeoElement
in the Z direction.The target location is determined by the location of the
GeoElement
plus any defined offsets (in X, Y, or Z). The offset position of the target relative to theGeoElement
is always maintained, even when theGeoElement
moves.- Parameters:
targetOffsetZ
- the target's offset from the GeoElement's location along the z-axis- Since:
- 100.2.0
-