Package com.azure.core.http.policy
Interface HttpPipelinePolicy
- All Known Implementing Classes:
AddDatePolicy
,AddHeadersFromContextPolicy
,AddHeadersPolicy
,AzureKeyCredentialPolicy
,AzureSasCredentialPolicy
,BearerTokenAuthenticationPolicy
,CookiePolicy
,HostPolicy
,HttpLoggingPolicy
,HttpPipelineSyncPolicy
,KeyCredentialPolicy
,PortPolicy
,ProtocolPolicy
,RedirectPolicy
,RequestIdPolicy
,RetryPolicy
,TimeoutPolicy
,UserAgentPolicy
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A policy within the
HttpPipeline
.- See Also:
-
Method Summary
Modifier and TypeMethodDescriptiondefault HttpPipelinePosition
Gets the position to place the policy.process
(HttpPipelineCallContext context, HttpPipelineNextPolicy next) Processes provided request context and invokes the next policy.default HttpResponse
processSync
(HttpPipelineCallContext context, HttpPipelineNextSyncPolicy next) Processes provided request context and invokes the next policy synchronously.
-
Method Details
-
process
Processes provided request context and invokes the next policy.- 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
Processes provided request context and invokes the next policy synchronously.- 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.
-
getPipelinePosition
Gets the position to place the policy.By default pipeline policies are positioned
HttpPipelinePosition.PER_RETRY
.- Returns:
- The position to place the policy.
-