Class HttpPipelineSyncPolicy

java.lang.Object
com.azure.core.http.policy.HttpPipelineSyncPolicy
All Implemented Interfaces:
HttpPipelinePolicy

public class HttpPipelineSyncPolicy extends Object implements HttpPipelinePolicy
Represents a HttpPipelinePolicy that doesn't do any asynchronous or synchronously blocking operations.
  • Constructor Details

    • HttpPipelineSyncPolicy

      public HttpPipelineSyncPolicy()
  • Method Details

    • process

      public final Mono<HttpResponse> process(HttpPipelineCallContext context, HttpPipelineNextPolicy next)
      Processes provided request context and invokes the next policy.
      Specified by:
      process in interface HttpPipelinePolicy
      Parameters:
      context - The request context.
      next - The next policy to invoke.
      Returns:
      A publisher that initiates the request upon subscription and emits a response on completion.
    • processSync

      public final HttpResponse processSync(HttpPipelineCallContext context, HttpPipelineNextSyncPolicy next)
      Processes provided request context and invokes the next policy synchronously.
      Specified by:
      processSync in interface HttpPipelinePolicy
      Parameters:
      context - The request context.
      next - The next policy to invoke.
      Returns:
      A publisher that initiates the request upon subscription and emits a response on completion.
    • beforeSendingRequest

      protected void beforeSendingRequest(HttpPipelineCallContext context)
      Method is invoked before the request is sent.
      Parameters:
      context - The request context.
    • afterReceivedResponse

      protected HttpResponse afterReceivedResponse(HttpPipelineCallContext context, HttpResponse response)
      Method is invoked after the response is received.
      Parameters:
      context - The request context.
      response - The response received.
      Returns:
      The transformed response.