Generate Events (Location Referencing)

Disponible con licencia de Location Referencing.

Resumen

Re-creates shapes for event features registered with an LRS Network.

Uso

  • An LRS dataset is required to run this tool. To create an LRS dataset, add the calibration point, centerline, and redline layers to a feature dataset; then run the Modify LRS tool with the geodatabase as the input.

  • Input the event whose features need to be regenerated based on the route and measure of the event.

  • When conflict prevention is enabled for the tool, any events being generated by the tool will be locked.

    • While working in the default version, the locks acquired are released automatically when the tool completes.
    • While working in a child version, the locks acquired will remain in On Post status when the tool completes. The lock owner must post or delete the version to release the locks.
    • While working in a child version, if the execution of the tool is canceled by interruption, the locks are acquired and will remain in releasable status when the tool completes.

Parámetros

EtiquetaExplicaciónTipo de datos
Event Layer

The event for which shapes will be regenerated.

Feature Layer

Salida derivada

EtiquetaExplicaciónTipo de datos
Output Event Layers

Updated events feature layer.

Nota:

Los resultados de la validación de esta herramienta se escriben en el directorio de ArcGIS Server. Este archivo se limpia automáticamente en 10 minutos por defecto, lo que puede no ser suficiente tiempo para procesar todas las validaciones y escribirlas en su estación de trabajo que se está ejecutando ArcGIS Pro. Para cargas de datos mayores, se recomienda ajustar la antigüedad máxima del archivo a una hora como mínimo.

Feature Layer

arcpy.locref.GenerateEvents(in_event_layer)
NombreExplicaciónTipo de datos
in_event_layer

The event for which shapes will be regenerated.

Feature Layer

Salida derivada

NombreExplicaciónTipo de datos
out_event_layers

Updated events feature layer.

Nota:

Los resultados de la validación de esta herramienta se escriben en el directorio de ArcGIS Server. Este archivo se limpia automáticamente en 10 minutos por defecto, lo que puede no ser suficiente tiempo para procesar todas las validaciones y escribirlas en su estación de trabajo que se está ejecutando ArcGIS Pro. Para cargas de datos mayores, se recomienda ajustar la antigüedad máxima del archivo a una hora como mínimo.

Feature Layer

Muestra de código

GenerateEvents example 1 (Python window)

The following Python script demonstrates how to use the GenerateEvents function in the Python window.

# Name: GenerateEvents_Ex1.py
# Description: Generate events in stand-alone mode using a feature service. It is recommended to work in  a version and post it into the default version.
# Requires: ArcGIS Location Referencing

# Check out license
arcpy.CheckOutExtension("LocationReferencing")

# Tool variables 
in_event_layer = "Event"

# Set current workspace 
arcpy.env.workspace = "C:/data/Outputs.gdb"

# Execute the tool 
arcpy.GenerateEvents_locref(in_event_layer)

# Check in license
arcpy.CheckInExtension('LocationReferencing')
GenerateEvents example 2 (stand-alone script)

The following Python script demonstrates how to use the GenerateEvents function in a stand-alone Python script.

# Name: GenerateEvents_Ex2.py 
# Description: Re-creates shapes for event features registered with an LRS Network 
# Requirements: ArcGIS Location Referencing

# Import arcpy module 
import arcpy

# Check out license 
arcpy.CheckOutExtension("LocationReferencing")

# Local variables 
# Input Network layer 
in_event_layer = "C:\\Data\Sample.gdb\\LRS\\SpeedLimit" 

# Process: Generate Events
arcpy.GenerateEvents_locref(in_event_layer)

# Check in license
arcpy.CheckInExtension('LocationReferencing')
GenerateEvents example 3 (stand-alone script)

The following Python script demonstrates how to use the GenerateEvents function in a stand-alone Python script in a feature service.

# Name: GenerateEvents_Ex3.py
# Description: Generate events in stand-alone mode using a feature service. It is recommended to work in  a version and post it into the default version.
# Requires: ArcGIS Location Referencing

# Import arcpy module.
import arcpy

# Check out license
arcpy.CheckOutExtension("LocationReferencing")

## Input event is in feature service.  Portal signin is required to access the feature service.
arcpy.SignInToPortal('https://yourdomain.com/portal', 'username', 'password')

## Map the input event from the feature service. Here, 3 corresponds to the input event
in_event_layer = r"https://yourdomain.com/server/rest/services/FeatureServiceName/FeatureServer/3"

# Process : Generate Events
arcpy.GenerateEvents_locref(in_event_layer)

# Check in license
arcpy.CheckInExtension('LocationReferencing')

Entornos

Casos especiales

Información de licenciamiento

  • Basic: Requiere ArcGIS Location Referencing
  • Standard: Requiere ArcGIS Location Referencing
  • Advanced: Requiere ArcGIS Location Referencing

Temas relacionados