using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using System.Threading.Tasks;
using System.Net.Http;
using Microsoft.AspNetCore.Components;

using CommonHelpers.WASM;
using AFXUI;

namespace BookRegistry.Client {

//**************************************************************************************************
partial class XServiceBase {
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

/// <exception cref="UEscapeException" />
protected Task<ServiceInvocationResult<R>> ESC_InvokeAction_A<R>( string methodName )
where R: GeneralApiResponse =>
   ESC_InvokeImplementation_A<R>( true, methodName, null );

/// <exception cref="UEscapeException" />
protected Task<ServiceInvocationResult<R>> ESC_InvokeAction_A<R>( bool alterActionName,
                                                                  string methodName )
where R: GeneralApiResponse =>
   ESC_InvokeImplementation_A<R>( alterActionName, methodName, null );

//--------------------------------------------------------------------------------------------------

/// <exception cref="UEscapeException" />
protected Task<ServiceInvocationResult<R>> ESC_InvokeAction_A<R>( string methodName,
                                                                  [HOptional]
                                                                  object? argumentsObj )
where R: GeneralApiResponse =>
   ESC_InvokeImplementation_A<R>( true, methodName, argumentsObj );

/// <exception cref="UEscapeException" />
protected Task<ServiceInvocationResult<R>> ESC_InvokeAction_A<R>( bool alterActionName,
                                                                  string methodName,
                                                                  [HOptional]
                                                                  object? argumentsObj )
where R: GeneralApiResponse =>
   ESC_InvokeImplementation_A<R>( alterActionName, methodName, argumentsObj );

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
} // XServiceBase
//**************************************************************************************************

} // BookRegistry.Client
