Class ParameterMapping
Represents a Parameter Mapping.
Inheritance
Namespace: Amazon.CDK.AWS.Apigatewayv2
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class ParameterMapping : DeputyBase
Syntax (vb)
Public Class ParameterMapping
Inherits DeputyBase
Remarks
ExampleMetadata: infused
Examples
using Amazon.CDK.HttpAlbIntegration;
ApplicationLoadBalancer lb;
var listener = lb.AddListener("listener", new BaseApplicationListenerProps { Port = 80 });
listener.AddTargets("target", new AddApplicationTargetsProps {
Port = 80
});
var httpEndpoint = new HttpApi(this, "HttpProxyPrivateApi", new HttpApiProps {
DefaultIntegration = new HttpAlbIntegration("DefaultIntegration", listener, new HttpAlbIntegrationProps {
ParameterMapping = new ParameterMapping().AppendHeader("header2", MappingValue.RequestHeader("header1")).RemoveHeader("header1")
})
});
Synopsis
Constructors
ParameterMapping() | |
ParameterMapping(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
ParameterMapping(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
Properties
Mappings | Represents all created parameter mappings. |
Methods
AppendHeader(String, MappingValue) | Creates a mapping to append a header. |
AppendQueryString(String, MappingValue) | Creates a mapping to append a query string. |
Custom(String, String) | Creates a custom mapping. |
FromObject(IDictionary<String, MappingValue>) | Creates a mapping from an object. |
OverwriteHeader(String, MappingValue) | Creates a mapping to overwrite a header. |
OverwritePath(MappingValue) | Creates a mapping to overwrite a path. |
OverwriteQueryString(String, MappingValue) | Creates a mapping to overwrite a querystring. |
RemoveHeader(String) | Creates a mapping to remove a header. |
RemoveQueryString(String) | Creates a mapping to remove a querystring. |
Constructors
ParameterMapping()
public ParameterMapping()
ParameterMapping(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected ParameterMapping(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
ParameterMapping(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected ParameterMapping(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
Properties
Mappings
Represents all created parameter mappings.
public virtual IDictionary<string, string> Mappings { get; }
Property Value
System.Collections.Generic.IDictionary<System.String, System.String>
Methods
AppendHeader(String, MappingValue)
Creates a mapping to append a header.
public virtual ParameterMapping AppendHeader(string name, MappingValue value)
Parameters
- name System.String
- value MappingValue
Returns
AppendQueryString(String, MappingValue)
Creates a mapping to append a query string.
public virtual ParameterMapping AppendQueryString(string name, MappingValue value)
Parameters
- name System.String
- value MappingValue
Returns
Custom(String, String)
Creates a custom mapping.
public virtual ParameterMapping Custom(string key, string value)
Parameters
- key System.String
- value System.String
Returns
FromObject(IDictionary<String, MappingValue>)
Creates a mapping from an object.
public static ParameterMapping FromObject(IDictionary<string, MappingValue> obj)
Parameters
- obj System.Collections.Generic.IDictionary<System.String, MappingValue>
Returns
OverwriteHeader(String, MappingValue)
Creates a mapping to overwrite a header.
public virtual ParameterMapping OverwriteHeader(string name, MappingValue value)
Parameters
- name System.String
- value MappingValue
Returns
OverwritePath(MappingValue)
Creates a mapping to overwrite a path.
public virtual ParameterMapping OverwritePath(MappingValue value)
Parameters
- value MappingValue
Returns
OverwriteQueryString(String, MappingValue)
Creates a mapping to overwrite a querystring.
public virtual ParameterMapping OverwriteQueryString(string name, MappingValue value)
Parameters
- name System.String
- value MappingValue
Returns
RemoveHeader(String)
Creates a mapping to remove a header.
public virtual ParameterMapping RemoveHeader(string name)
Parameters
- name System.String
Returns
RemoveQueryString(String)
Creates a mapping to remove a querystring.
public virtual ParameterMapping RemoveQueryString(string name)
Parameters
- name System.String
Returns