Class IAwsApiCall.Jsii$Proxy

java.lang.Object
software.amazon.jsii.JsiiObject
software.amazon.awscdk.integtests.IAwsApiCall.Jsii$Proxy
All Implemented Interfaces:
IConstruct, IConstruct.Jsii$Default, IDependable, IDependable.Jsii$Default, IAwsApiCall, IAwsApiCall.Jsii$Default, software.amazon.jsii.JsiiSerializable, software.constructs.IConstruct, software.constructs.IConstruct.Jsii$Default
Enclosing interface:
IAwsApiCall

@Internal public static final class IAwsApiCall.Jsii$Proxy extends software.amazon.jsii.JsiiObject implements IAwsApiCall.Jsii$Default
A proxy class which represents a concrete javascript instance of this type.
  • Nested Class Summary

    Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject

    software.amazon.jsii.JsiiObject.InitializationMode

    Nested classes/interfaces inherited from interface software.amazon.awscdk.integtests.IAwsApiCall

    IAwsApiCall.Jsii$Default, IAwsApiCall.Jsii$Proxy

    Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IConstruct

    IConstruct.Jsii$Default, IConstruct.Jsii$Proxy

    Nested classes/interfaces inherited from interface software.constructs.IConstruct

    software.constructs.IConstruct.Jsii$Default, software.constructs.IConstruct.Jsii$Proxy

    Nested classes/interfaces inherited from interface software.amazon.awscdk.core.IDependable

    IDependable.Jsii$Default, IDependable.Jsii$Proxy
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    protected
    Jsii$Proxy(software.amazon.jsii.JsiiObjectRef objRef)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    final void
    (experimental) Assert that the ExpectedResult is equal to the result of the AwsApiCall at the given path.
    final void
    (experimental) Assert that the ExpectedResult is equal to the result of the AwsApiCall.
    final Reference
    getAtt(String attributeName)
    (experimental) Returns the value of an attribute of the custom resource of an arbitrary type.
    final String
    getAttString(String attributeName)
    (experimental) Returns the value of an attribute of the custom resource of type string.
    The construct tree node for this construct.

    Methods inherited from class software.amazon.jsii.JsiiObject

    jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSet

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface software.amazon.jsii.JsiiSerializable

    $jsii$toJson
  • Constructor Details

    • Jsii$Proxy

      protected Jsii$Proxy(software.amazon.jsii.JsiiObjectRef objRef)
  • Method Details

    • getNode

      @Stability(Stable) @NotNull public final ConstructNode getNode()
      The construct tree node for this construct.
      Specified by:
      getNode in interface IAwsApiCall.Jsii$Default
      Specified by:
      getNode in interface IConstruct
      Specified by:
      getNode in interface IConstruct.Jsii$Default
    • assertAtPath

      @Stability(Experimental) public final void assertAtPath(@NotNull String path, @NotNull ExpectedResult expected)
      (experimental) Assert that the ExpectedResult is equal to the result of the AwsApiCall at the given path.

      For example the SQS.receiveMessage api response would look like:

      If you wanted to assert the value of Body you could do

      Example:

       IntegTest integ;
       Map<String, Map<String, Object>[]> actual = Map.of(
               "Messages", List.of(Map.of(
                       "MessageId", "",
                       "ReceiptHandle", "",
                       "MD5OfBody", "",
                       "Body", "hello",
                       "Attributes", Map.of(),
                       "MD5OfMessageAttributes", Map.of(),
                       "MessageAttributes", Map.of())));
       IAwsApiCall message = integ.assertions.awsApiCall("SQS", "receiveMessage");
       message.assertAtPath("Messages.0.Body", ExpectedResult.stringLikeRegexp("hello"));
       

      Specified by:
      assertAtPath in interface IAwsApiCall
      Specified by:
      assertAtPath in interface IAwsApiCall.Jsii$Default
      Parameters:
      path - This parameter is required.
      expected - This parameter is required.
    • expect

      @Stability(Experimental) public final void expect(@NotNull ExpectedResult expected)
      (experimental) Assert that the ExpectedResult is equal to the result of the AwsApiCall.

      Example:

       IntegTest integ;
       IAwsApiCall invoke = integ.assertions.invokeFunction(LambdaInvokeFunctionProps.builder()
               .functionName("my-func")
               .build());
       invoke.expect(ExpectedResult.objectLike(Map.of("Payload", "OK")));
       

      Specified by:
      expect in interface IAwsApiCall
      Specified by:
      expect in interface IAwsApiCall.Jsii$Default
      Parameters:
      expected - This parameter is required.
    • getAtt

      @Stability(Experimental) @NotNull public final Reference getAtt(@NotNull String attributeName)
      (experimental) Returns the value of an attribute of the custom resource of an arbitrary type.

      Attributes are returned from the custom resource provider through the Data map where the key is the attribute name.

      Specified by:
      getAtt in interface IAwsApiCall
      Specified by:
      getAtt in interface IAwsApiCall.Jsii$Default
      Parameters:
      attributeName - the name of the attribute. This parameter is required.
      Returns:
      a token for Fn::GetAtt. Use Token.asXxx to encode the returned Reference as a specific type or use the convenience getAttString for string attributes.
    • getAttString

      @Stability(Experimental) @NotNull public final String getAttString(@NotNull String attributeName)
      (experimental) Returns the value of an attribute of the custom resource of type string.

      Attributes are returned from the custom resource provider through the Data map where the key is the attribute name.

      Specified by:
      getAttString in interface IAwsApiCall
      Specified by:
      getAttString in interface IAwsApiCall.Jsii$Default
      Parameters:
      attributeName - the name of the attribute. This parameter is required.
      Returns:
      a token for Fn::GetAtt encoded as a string.