generateKey abstract method

String generateKey({
  1. required REQUEST_METHODS method,
  2. required Uri url,
  3. Object? body,
})

Generates a unique cache key for a specific HTTP request.

  • method: The HTTP method (GET, POST, PUT, DELETE)
  • url: The complete request URL including query parameters
  • body: The request body (for POST and PUT requests)

Returns a string that uniquely identifies this request for caching purposes.

Implementation

String generateKey({
  required REQUEST_METHODS method,
  required Uri url,
  Object? body,
});