@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:36.930Z") @Stability(value=Stable) public class CfnBudget extends CfnResource implements IInspectable
The AWS::Budgets::Budget resource allows customers to take pre-defined actions that will trigger once a budget threshold has been exceeded. creates, replaces, or deletes budgets for Billing and Cost Management. For more information, see Managing Your Costs with Budgets in the AWS Billing and Cost Management User Guide .
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.budgets.*;
Object costFilters;
Object plannedBudgetLimits;
CfnBudget cfnBudget = CfnBudget.Builder.create(this, "MyCfnBudget")
.budget(BudgetDataProperty.builder()
.budgetType("budgetType")
.timeUnit("timeUnit")
// the properties below are optional
.budgetLimit(SpendProperty.builder()
.amount(123)
.unit("unit")
.build())
.budgetName("budgetName")
.costFilters(costFilters)
.costTypes(CostTypesProperty.builder()
.includeCredit(false)
.includeDiscount(false)
.includeOtherSubscription(false)
.includeRecurring(false)
.includeRefund(false)
.includeSubscription(false)
.includeSupport(false)
.includeTax(false)
.includeUpfront(false)
.useAmortized(false)
.useBlended(false)
.build())
.plannedBudgetLimits(plannedBudgetLimits)
.timePeriod(TimePeriodProperty.builder()
.end("end")
.start("start")
.build())
.build())
// the properties below are optional
.notificationsWithSubscribers(List.of(NotificationWithSubscribersProperty.builder()
.notification(NotificationProperty.builder()
.comparisonOperator("comparisonOperator")
.notificationType("notificationType")
.threshold(123)
// the properties below are optional
.thresholdType("thresholdType")
.build())
.subscribers(List.of(SubscriberProperty.builder()
.address("address")
.subscriptionType("subscriptionType")
.build()))
.build()))
.build();
| Modifier and Type | Class and Description |
|---|---|
static interface |
CfnBudget.BudgetDataProperty
Represents the output of the `CreateBudget` operation.
|
static class |
CfnBudget.Builder
A fluent builder for
CfnBudget. |
static interface |
CfnBudget.CostTypesProperty
The types of cost that are included in a `COST` budget, such as tax and subscriptions.
|
static interface |
CfnBudget.NotificationProperty
A notification that's associated with a budget.
|
static interface |
CfnBudget.NotificationWithSubscribersProperty
A notification with subscribers.
|
static interface |
CfnBudget.SpendProperty
The amount of cost or usage that's measured for a budget.
|
static interface |
CfnBudget.SubscriberProperty
The `Subscriber` property type specifies who to notify for a Billing and Cost Management budget notification.
|
static interface |
CfnBudget.TimePeriodProperty
The period of time that is covered by a budget.
|
software.amazon.jsii.JsiiObject.InitializationModeIInspectable.Jsii$Default, IInspectable.Jsii$Proxy| Modifier and Type | Field and Description |
|---|---|
static String |
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
|
| Modifier | Constructor and Description |
|---|---|
|
CfnBudget(software.constructs.Construct scope,
String id,
CfnBudgetProps props)
Create a new `AWS::Budgets::Budget`.
|
protected |
CfnBudget(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
CfnBudget(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
Object |
getBudget()
The budget object that you want to create.
|
protected Map<String,Object> |
getCfnProperties() |
Object |
getNotificationsWithSubscribers()
A notification that you want to associate with a budget.
|
void |
inspect(TreeInspector inspector)
Examines the CloudFormation resource and discloses attributes.
|
protected Map<String,Object> |
renderProperties(Map<String,Object> props) |
void |
setBudget(CfnBudget.BudgetDataProperty value)
The budget object that you want to create.
|
void |
setBudget(IResolvable value)
The budget object that you want to create.
|
void |
setNotificationsWithSubscribers(IResolvable value)
A notification that you want to associate with a budget.
|
void |
setNotificationsWithSubscribers(List<Object> value)
A notification that you want to associate with a budget.
|
addDeletionOverride, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getCfnOptions, getCfnResourceType, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, shouldSynthesize, toString, validatePropertiesgetRefgetCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdjsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet@Stability(value=Stable) public static final String CFN_RESOURCE_TYPE_NAME
protected CfnBudget(software.amazon.jsii.JsiiObjectRef objRef)
protected CfnBudget(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable)
public CfnBudget(@NotNull
software.constructs.Construct scope,
@NotNull
String id,
@NotNull
CfnBudgetProps props)
scope - - scope in which this resource is defined. This parameter is required.id - - scoped id of the resource. This parameter is required.props - - resource properties. This parameter is required.@Stability(value=Stable)
public void inspect(@NotNull
TreeInspector inspector)
inspect in interface IInspectableinspector - - tree inspector to collect and process attributes. This parameter is required.@Stability(value=Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String,Object> props)
renderProperties in class CfnResourceprops - This parameter is required.@Stability(value=Stable) @NotNull protected Map<String,Object> getCfnProperties()
getCfnProperties in class CfnResource@Stability(value=Stable) @NotNull public Object getBudget()
@Stability(value=Stable)
public void setBudget(@NotNull
CfnBudget.BudgetDataProperty value)
@Stability(value=Stable)
public void setBudget(@NotNull
IResolvable value)
@Stability(value=Stable) @Nullable public Object getNotificationsWithSubscribers()
A budget can have up to five notifications, and each notification can have one SNS subscriber and up to 10 email subscribers. If you include notifications and subscribers in your CreateBudget call, AWS creates the notifications and subscribers for you.
@Stability(value=Stable)
public void setNotificationsWithSubscribers(@Nullable
IResolvable value)
A budget can have up to five notifications, and each notification can have one SNS subscriber and up to 10 email subscribers. If you include notifications and subscribers in your CreateBudget call, AWS creates the notifications and subscribers for you.
@Stability(value=Stable)
public void setNotificationsWithSubscribers(@Nullable
List<Object> value)
A budget can have up to five notifications, and each notification can have one SNS subscriber and up to 10 email subscribers. If you include notifications and subscribers in your CreateBudget call, AWS creates the notifications and subscribers for you.
Copyright © 2022. All rights reserved.