Class CommonGrantOptions
Basic options for a grant operation.
Implements
Inherited Members
Namespace: Amazon.CDK.AWS.IAM
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class CommonGrantOptions : ICommonGrantOptions
Syntax (vb)
Public Class CommonGrantOptions Implements ICommonGrantOptions
Remarks
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.IAM;
var conditions;
IGrantable grantable;
var commonGrantOptions = new CommonGrantOptions {
Actions = new [] { "actions" },
Grantee = grantable,
ResourceArns = new [] { "resourceArns" },
// the properties below are optional
Conditions = new Dictionary<string, IDictionary<string, object>> {
{ "conditionsKey", new Dictionary<string, object> {
{ "conditionsKey", conditions }
} }
}
};
Synopsis
Constructors
| CommonGrantOptions() | Basic options for a grant operation. |
Properties
| Actions | The actions to grant. |
| Conditions | Any conditions to attach to the grant. |
| Grantee | The principal to grant to. |
| ResourceArns | The resource ARNs to grant to. |
Constructors
CommonGrantOptions()
Basic options for a grant operation.
public CommonGrantOptions()
Remarks
ExampleMetadata: fixture=_generated
Examples
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
using Amazon.CDK.AWS.IAM;
var conditions;
IGrantable grantable;
var commonGrantOptions = new CommonGrantOptions {
Actions = new [] { "actions" },
Grantee = grantable,
ResourceArns = new [] { "resourceArns" },
// the properties below are optional
Conditions = new Dictionary<string, IDictionary<string, object>> {
{ "conditionsKey", new Dictionary<string, object> {
{ "conditionsKey", conditions }
} }
}
};
Properties
Actions
The actions to grant.
public string[] Actions { get; set; }
Property Value
string[]
Remarks
ExampleMetadata: fixture=_generated
Conditions
Any conditions to attach to the grant.
public IDictionary<string, IDictionary<string, object>>? Conditions { get; set; }
Property Value
IDictionary<string, IDictionary<string, object>>
Remarks
Default: - No conditions
Grantee
The principal to grant to.
public IGrantable Grantee { get; set; }
Property Value
Remarks
Default: if principal is undefined, no work is done.
ResourceArns
The resource ARNs to grant to.
public string[] ResourceArns { get; set; }
Property Value
string[]
Remarks
ExampleMetadata: fixture=_generated