MarkersConfig Struct
A configuration for markers substitution strategy.
| Source | aws-s3-deployment/lib/source.ts |
|---|---|
| Type last changed |
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_s3_deployment as s3_deployment } from 'aws-cdk-lib';
const markersConfig: s3_deployment.MarkersConfig = {
jsonEscape: false,
markerEncodings: {
markerEncodingsKey: s3_deployment.MarkerEncoding.LITERAL,
},
};
python
# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk import aws_s3_deployment as s3_deployment
markers_config = s3_deployment.MarkersConfig(
json_escape=False,
marker_encodings={
"marker_encodings_key": s3_deployment.MarkerEncoding.LITERAL
}
)
java
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.s3.deployment.*;
MarkersConfig markersConfig = MarkersConfig.builder()
.jsonEscape(false)
.markerEncodings(Map.of(
"markerEncodingsKey", MarkerEncoding.LITERAL))
.build();
csharp
// Install: dotnet add package Amazon.CDK.Lib
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.S3.Deployment;
var markersConfig = new MarkersConfig {
JsonEscape = false,
MarkerEncodings = new Dictionary<string, MarkerEncoding> {
{ "markerEncodingsKey", MarkerEncoding.LITERAL }
}
};
go
// Install: go get github.com/aws/aws-cdk-go/awscdk/v2
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import "github.com/aws/aws-cdk-go/awscdk"
markersConfig := &MarkersConfig{
JsonEscape: jsii.Boolean(false),
MarkerEncodings: map[string]MarkerEncoding{
"markerEncodingsKey": awscdk.aws_s3_deployment.MarkerEncoding_LITERAL,
},
}
Properties
jsonEscapeoptionalbooleanjson_escapeoptionalbooljsonEscapeoptionalBooleanJsonEscapeoptionalboolJsonEscapeoptional*bool = false #Default marker encoding for markers that don't have a `markerEncodings` entry.
notes
- If
false(default), the default marker encoding isMarkerEncoding.LITERAL. - If
true, the default marker encoding isMarkerEncoding.UNQUOTED_JSON_VALUE.
See Source.data() for a full description of the effect of this setting.
Unless you need fine-grained control over marker encoding, you should use Source.jsonData() or Source.yamlData().
markerEncodingsoptional{ [key: string]: MarkerEncoding }marker_encodingsoptionaltyping.Mapping[str, MarkerEncoding]markerEncodingsoptionalMap<String, MarkerEncoding>MarkerEncodingsoptionalIDictionary<string, MarkerEncoding>MarkerEncodingsoptional*map[string]MarkerEncoding #For every marker specified in the `markers` property, this defines how the marker value should be encoded.
Default: markers with no entry use the default encoding derived from jsonEscape
The key is the marker name and the value is the encoding to use for that marker.