define<E, O> method

DynCallExecutor<E> define<E, O>(
  1. DynCall<E, O> call,
  2. HttpMethod method, {
  3. String? path,
  4. String? fullPath,
  5. Map<String, String>? parametersMap,
  6. Map<String, String>? parametersStatic,
  7. Map<String, ParameterProvider>? parametersProviders,
  8. String? queryString,
  9. dynamic noQueryString = false,
  10. Credential? authorization,
  11. List<String>? authorizationFields,
  12. Object? body,
  13. Object? bodyBuilder,
  14. String? bodyType,
  15. E? errorResponse,
  16. int errorMaxRetries = 3,
  17. HTTPOutputValidator? outputValidator,
  18. HTTPOutputFilter? outputFilter,
  19. HTTPJSONOutputFilter? jsonOutputFilter,
  20. String? outputFilterPattern,
  21. HTTPOutputInterceptor? outputInterceptor,
  22. ExecutorWrapper? executorWrapper,
})

Implementation

DynCallExecutor<E> define<E, O>(DynCall<E, O> call, HttpMethod method,
    {String? path,
    String? fullPath,
    Map<String, String>? parametersMap,
    Map<String, String>? parametersStatic,
    Map<String, ParameterProvider>? parametersProviders,
    String? queryString,
    noQueryString = false,
    Credential? authorization,
    List<String>? authorizationFields,
    Object? body,
    Object? bodyBuilder,
    String? bodyType,
    E? errorResponse,
    int errorMaxRetries = 3,
    HTTPOutputValidator? outputValidator,
    HTTPOutputFilter? outputFilter,
    HTTPJSONOutputFilter? jsonOutputFilter,
    String? outputFilterPattern,
    HTTPOutputInterceptor? outputInterceptor,
    ExecutorWrapper? executorWrapper}) {
  // ignore: omit_local_variable_types
  DynCallExecutor<E> executor = create(method,
      path: path,
      fullPath: fullPath,
      parametersMap: parametersMap,
      parametersStatic: parametersStatic,
      parametersProviders: parametersProviders,
      queryString: queryString,
      noQueryString: noQueryString,
      authorization: authorization,
      authorizationFields: authorizationFields,
      body: body,
      bodyBuilder: bodyBuilder,
      bodyType: bodyType,
      errorResponse: errorResponse,
      errorMaxRetries: errorMaxRetries,
      outputValidator: outputValidator,
      outputFilter: outputFilter,
      jsonOutputFilter: jsonOutputFilter,
      outputFilterPattern: outputFilterPattern,
      outputInterceptor: outputInterceptor);

  if (executorWrapper != null) {
    var executor2 = executorWrapper(executor) as DynCallExecutor<E>;
    executor = executor2;
  }

  call.executor = executor;
  return executor;
}