using System; using System.Collections.Generic; using System.Threading.Tasks; using ArcGIS.Desktop.Core.Geoprocessing; using ArcGIS.Desktop.Framework.Dialogs; using ArcGIS.Desktop.Framework.Threading.Tasks; namespace LinkToolAddin.server; public class CallArcGISPro { private static readonly log4net.ILog log = log4net.LogManager.GetLogger(typeof(CallArcGISPro)); public async static Task CallArcGISProTool(string toolName, List toolParams) { var results = await Geoprocessing.ExecuteToolAsync(toolName, toolParams); log.Info($"CallArcGISProTool: {toolName} | {toolParams}"); return new JsonRpcSuccessEntity() { Id = 1, Result = results.ToString() }; } }