Class OriginRequestPolicy
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.core.Construct
software.amazon.awscdk.core.Resource
software.amazon.awscdk.services.cloudfront.OriginRequestPolicy
- All Implemented Interfaces:
IConstruct
,IDependable
,IResource
,IOriginRequestPolicy
,software.amazon.jsii.JsiiSerializable
,software.constructs.IConstruct
@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)",
date="2023-06-19T16:30:43.737Z")
@Stability(Stable)
public class OriginRequestPolicy
extends Resource
implements IOriginRequestPolicy
A Origin Request Policy configuration.
Example:
// Using an existing origin request policy for a Distribution S3Origin bucketOrigin; Distribution.Builder.create(this, "myDistManagedPolicy") .defaultBehavior(BehaviorOptions.builder() .origin(bucketOrigin) .originRequestPolicy(OriginRequestPolicy.CORS_S3_ORIGIN) .build()) .build();
-
Nested Class Summary
Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationMode
Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IConstruct
IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$Default
Nested classes/interfaces inherited from interface software.amazon.awscdk.services.cloudfront.IOriginRequestPolicy
IOriginRequestPolicy.Jsii$Default, IOriginRequestPolicy.Jsii$Proxy
Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IResource
IResource.Jsii$Default
-
Field Summary
Modifier and TypeFieldDescriptionstatic final IOriginRequestPolicy
This policy includes all values (query strings, headers, and cookies) in the viewer request.static final IOriginRequestPolicy
This policy includes the header that enables cross-origin resource sharing (CORS) requests when the origin is a custom origin.static final IOriginRequestPolicy
This policy includes the headers that enable cross-origin resource sharing (CORS) requests when the origin is an Amazon S3 bucket.static final IOriginRequestPolicy
This policy is designed for use with an origin that is an AWS Elemental MediaTailor endpoint.static final IOriginRequestPolicy
This policy includes only the User-Agent and Referer headers. -
Constructor Summary
ModifierConstructorDescriptionprotected
OriginRequestPolicy
(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protected
OriginRequestPolicy
(software.amazon.jsii.JsiiObjectRef objRef) OriginRequestPolicy
(software.constructs.Construct scope, String id) OriginRequestPolicy
(software.constructs.Construct scope, String id, OriginRequestPolicyProps props) -
Method Summary
Modifier and TypeMethodDescriptionstatic IOriginRequestPolicy
fromOriginRequestPolicyId
(software.constructs.Construct scope, String id, String originRequestPolicyId) Imports a Origin Request Policy from its id.The ID of the origin request policy.Methods inherited from class software.amazon.awscdk.core.Resource
applyRemovalPolicy, generatePhysicalName, getEnv, getPhysicalName, getResourceArnAttribute, getResourceNameAttribute, getStack, isResource
Methods inherited from class software.amazon.awscdk.core.Construct
getNode, isConstruct, onPrepare, onSynthesize, onValidate, prepare, synthesize, validate
Methods inherited from class software.constructs.Construct
toString
Methods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface software.amazon.awscdk.core.IConstruct
getNode
Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
ALL_VIEWER
This policy includes all values (query strings, headers, and cookies) in the viewer request. -
CORS_CUSTOM_ORIGIN
This policy includes the header that enables cross-origin resource sharing (CORS) requests when the origin is a custom origin. -
CORS_S3_ORIGIN
This policy includes the headers that enable cross-origin resource sharing (CORS) requests when the origin is an Amazon S3 bucket. -
ELEMENTAL_MEDIA_TAILOR
This policy is designed for use with an origin that is an AWS Elemental MediaTailor endpoint. -
USER_AGENT_REFERER_HEADERS
This policy includes only the User-Agent and Referer headers.It doesn’t include any query strings or cookies.
-
-
Constructor Details
-
OriginRequestPolicy
protected OriginRequestPolicy(software.amazon.jsii.JsiiObjectRef objRef) -
OriginRequestPolicy
protected OriginRequestPolicy(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
OriginRequestPolicy
@Stability(Stable) public OriginRequestPolicy(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable OriginRequestPolicyProps props) - Parameters:
scope
- This parameter is required.id
- This parameter is required.props
-
-
OriginRequestPolicy
@Stability(Stable) public OriginRequestPolicy(@NotNull software.constructs.Construct scope, @NotNull String id) - Parameters:
scope
- This parameter is required.id
- This parameter is required.
-
-
Method Details
-
fromOriginRequestPolicyId
@Stability(Stable) @NotNull public static IOriginRequestPolicy fromOriginRequestPolicyId(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull String originRequestPolicyId) Imports a Origin Request Policy from its id.- Parameters:
scope
- This parameter is required.id
- This parameter is required.originRequestPolicyId
- This parameter is required.
-
getOriginRequestPolicyId
The ID of the origin request policy.- Specified by:
getOriginRequestPolicyId
in interfaceIOriginRequestPolicy
-