@Generated(value="jsii-pacmak/1.30.0 (build adae23f)", date="2021-06-30T10:00:42.405Z") @Stability(value=Experimental) public class Annotations extends software.amazon.jsii.JsiiObject
| Modifier | Constructor and Description |
|---|---|
protected |
Annotations(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
Annotations(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
void |
addDeprecation(String api,
String message)
(experimental) Adds a deprecation warning for a specific API.
|
void |
addError(String message)
(experimental) Adds an { "error":
|
void |
addInfo(String message)
(experimental) Adds an info metadata entry to this construct.
|
void |
addWarning(String message)
(experimental) Adds a warning metadata entry to this construct.
|
static Annotations |
of(software.constructs.IConstruct scope)
(experimental) Returns the annotations API for a construct scope.
|
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetprotected Annotations(software.amazon.jsii.JsiiObjectRef objRef)
protected Annotations(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Experimental) @NotNull public static Annotations of(@NotNull software.constructs.IConstruct scope)
scope - The scope. This parameter is required.@Stability(value=Experimental)
public void addDeprecation(@NotNull
String api,
@NotNull
String message)
Deprecations will be added only once per construct as a warning and will be
deduplicated based on the api.
If the environment variable CDK_BLOCK_DEPRECATIONS is set, this method
will throw an error instead with the deprecation message.
api - The API being deprecated in the format `module.Class.property` (e.g. `@aws-cdk/core.Construct.node`). This parameter is required.message - The deprecation message to display, with information about alternatives. This parameter is required.@Stability(value=Experimental)
public void addError(@NotNull
String message)
The toolkit will fail synthesis when errors are reported.
message - The error message. This parameter is required.@Stability(value=Experimental)
public void addInfo(@NotNull
String message)
The CLI will display the info message when apps are synthesized.
message - The info message. This parameter is required.@Stability(value=Experimental)
public void addWarning(@NotNull
String message)
The CLI will display the warning when an app is synthesized, or fail if run in --strict mode.
message - The warning message. This parameter is required.Copyright © 2021. All rights reserved.