EndpointExtensions.ExecuteMethod<TResponse> method

namespace: Serenity.Services   assemblySerenity.Net.Web

Executes an action method and converts any exception to a service response

public static Result<TResponse> ExecuteMethod<TResponse>(this ControllerBase controller, 
    Func<TResponse> handler)
    where TResponse : ServiceResponse, new()
parameter description
TResponse Response type
controller Controller
handler Handler callback

See Also