ArcGIS Desktop

  • ArcGIS Pro
  • ArcMap

  • My Profile
  • Ayuda
  • Sign Out
ArcGIS Desktop

ArcGIS Online

La plataforma de representación cartográfica para tu organización

ArcGIS Desktop

Un completo SIG profesional

ArcGIS Enterprise

SIG en tu empresa

ArcGIS Developers

Herramientas para crear aplicaciones basadas en la ubicación

ArcGIS Solutions

Plantillas de aplicaciones y mapas gratuitas para tu sector

ArcGIS Marketplace

Obtén aplicaciones y datos para tu organización.

  • Documentación
  • Soporte
Esri
  • Iniciar sesión
user
  • Mi perfil
  • Cerrar sesión

ArcMap

  • Inicio
  • Introducción
  • Cartografiar
  • Analizar
  • Administrar datos
  • Herramientas
  • Extensiones

IsSynchronous

  • Resumen
  • Sintaxis
  • Muestra de código

Resumen

Determines if a tool is running synchronous or asynchronous. When a tool is synchronous, the results are automatically returned, but no other action may be taken until the tool has completed. All non-server tools are synchronous. Server tools may be asynchronous, meaning that once the tool has been submitted to the server, other functionality can be run without waiting, and the results must be explicitly requested from the server.

Sintaxis

IsSynchronous (tool_name)
ParámetroExplicaciónTipo de datos
tool_name

The name of the tool to determine if it is synchronous.

String

Valor de retorno

Tipo de datosExplicación
Boolean

A return Boolean value of True indicates the tool is synchronous.

Muestra de código

IsSynchronous example

Determine if a server tool is running synchronous.

import time
import arcpy

# Add server toolbox from a local ArcGIS Server
arcpy.ImportToolbox("pondermatic;buffertools")

# Create and load a recordset object for the tool's input
record_set = arcpy.RecordSet()
record_set.load("c:/temp/lines.shp")

# Run the server tool
results = arcpy.BufferLines_mytools(record_set, "100")

# If the tool is asynchronous, wait until the task is finished (status = 4)
if not arcpy.IsSynchronous("BufferLines"):
    while results.status < 4:
        time.sleep(0.1)

# Get output from task and export to a feature class on disk
result = results.getOutput(0)
result.save("c:/temp/bufferlines.shp")

Temas relacionados

  • ListToolboxes
  • ListTools
  • Cómo enumerar herramientas, cajas de herramientas y configuraciones de entorno

ArcGIS Desktop

  • Inicio
  • Documentación
  • Soporte

ArcGIS

  • ArcGIS Online
  • ArcGIS Desktop
  • ArcGIS Enterprise
  • ArcGIS
  • ArcGIS Developer
  • ArcGIS Solutions
  • ArcGIS Marketplace

Acerca de Esri

  • Quiénes somos
  • Empleo
  • Blog de Esri
  • Conferencia de usuarios
  • Cumbre de desarrolladores
Esri
Díganos su opinión.
Copyright © 2021 Esri. | Privacidad | Legal