Class TestAuthorizationRequest

    • Method Detail

      • principal

        public final String principal()

        The principal. Valid principals are CertificateArn (arn:aws:iot:region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup/groupName) and CognitoId (region:id).

        Returns:
        The principal. Valid principals are CertificateArn (arn:aws:iot:region:accountId:cert/certificateId), thingGroupArn (arn:aws:iot:region:accountId:thinggroup/groupName) and CognitoId (region:id).
      • cognitoIdentityPoolId

        public final String cognitoIdentityPoolId()

        The Cognito identity pool ID.

        Returns:
        The Cognito identity pool ID.
      • hasAuthInfos

        public final boolean hasAuthInfos()
        For responses, this returns true if the service returned a value for the AuthInfos property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
      • authInfos

        public final List<AuthInfo> authInfos()

        A list of authorization info objects. Simulating authorization will create a response for each authInfo object in the list.

        Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

        This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasAuthInfos() method.

        Returns:
        A list of authorization info objects. Simulating authorization will create a response for each authInfo object in the list.
      • clientId

        public final String clientId()

        The MQTT client ID.

        Returns:
        The MQTT client ID.
      • hasPolicyNamesToAdd

        public final boolean hasPolicyNamesToAdd()
        For responses, this returns true if the service returned a value for the PolicyNamesToAdd property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
      • policyNamesToAdd

        public final List<String> policyNamesToAdd()

        When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.

        Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

        This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasPolicyNamesToAdd() method.

        Returns:
        When testing custom authorization, the policies specified here are treated as if they are attached to the principal being authorized.
      • hasPolicyNamesToSkip

        public final boolean hasPolicyNamesToSkip()
        For responses, this returns true if the service returned a value for the PolicyNamesToSkip property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
      • policyNamesToSkip

        public final List<String> policyNamesToSkip()

        When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.

        Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

        This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasPolicyNamesToSkip() method.

        Returns:
        When testing custom authorization, the policies specified here are treated as if they are not attached to the principal being authorized.
      • toString

        public final String toString()
        Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
        Overrides:
        toString in class Object