arcgis.realtime module¶
The arcgis.realtime module provides types and functions for receiving real-time data feeds and sensor data streamed from the GIS to perform continuous processing and analysis. It includes support for stream layers that allow Python scripts to subscribe to the streamed feature data or broadcast updates or alerts.
StreamLayer¶
-
class
arcgis.realtime.
StreamLayer
(url, gis=None)¶ Stream layers allow Python scripts to subscribe to the feature data streamed from the GIS using the GeoEvent Processor or broadcast updates or alerts. This class can be used to perform continuous processing and analysis of real-time data as it’s received.
-
filter
¶ Property used for filtering the streamed features so they meet spatial and SQL like criteria, and return the specified fields
-
out_sr
¶ The spatial reference of the streamed features
-
subscribe
(on_features, on_open=None, on_disconnect=None, on_error=None)¶ Allows Python scripts to subscribe to the feature data streamed from the GIS using the GeoEvent Processor. Subscribing to the streamed data can be used to perform continuous processing and analysis of real-time data as it’s received. :param on_features: callback function that is called every time features are streamed to the client :param on_open: callback function called when the connection to the streaming server is created :param on_disconnect: callback function called when the connection to the streaming server is closed :param on_error: callback function called if the connection recieves an error
-