Class RegexPatternSet


  • public class RegexPatternSet
    extends com.pulumi.resources.CustomResource
    Provides an AWS WAFv2 Regex Pattern Set Resource ## Example Usage
     
     package generated_program;
     
     import com.pulumi.Context;
     import com.pulumi.Pulumi;
     import com.pulumi.core.Output;
     import com.pulumi.aws.wafv2.RegexPatternSet;
     import com.pulumi.aws.wafv2.RegexPatternSetArgs;
     import com.pulumi.aws.wafv2.inputs.RegexPatternSetRegularExpressionArgs;
     import java.util.ArrayList;
     import java.util.Arrays;
     import java.util.Map;
     import java.io.File;
     import java.nio.file.Files;
     import java.nio.file.Paths;
     
     public class App {
         public static void main(String[] args) {
             Pulumi.run(App::stack);
         }
     
         public static void stack(Context ctx) {
             var example = new RegexPatternSet("example", RegexPatternSetArgs.builder()
                 .regularExpressions(            
                     RegexPatternSetRegularExpressionArgs.builder()
                         .regexString("one")
                         .build(),
                     RegexPatternSetRegularExpressionArgs.builder()
                         .regexString("two")
                         .build())
                 .name("example")
                 .description("Example regex pattern set")
                 .scope("REGIONAL")
                 .tags(Map.ofEntries(
                     Map.entry("Tag1", "Value1"),
                     Map.entry("Tag2", "Value2")
                 ))
                 .build());
     
         }
     }
     
     
    ## Import Using `pulumi import`, import WAFv2 Regex Pattern Sets using `ID/name/scope`. For example: ```sh $ pulumi import aws:wafv2/regexPatternSet:RegexPatternSet example a1b2c3d4-d5f6-7777-8888-9999aaaabbbbcccc/example/REGIONAL ```
    • Nested Class Summary

      • Nested classes/interfaces inherited from class com.pulumi.resources.CustomResource

        com.pulumi.resources.CustomResource.CustomResourceInternal
      • Nested classes/interfaces inherited from class com.pulumi.resources.Resource

        com.pulumi.resources.Resource.LazyField<T extends java.lang.Object>, com.pulumi.resources.Resource.LazyFields, com.pulumi.resources.Resource.ResourceInternal
    • Field Summary

      • Fields inherited from class com.pulumi.resources.Resource

        childResources, remote
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      com.pulumi.core.Output<java.lang.String> arn()  
      com.pulumi.core.Output<java.util.Optional<java.lang.String>> description()  
      static RegexPatternSet get​(java.lang.String name, com.pulumi.core.Output<java.lang.String> id, RegexPatternSetState state, com.pulumi.resources.CustomResourceOptions options)
      Get an existing Host resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
      com.pulumi.core.Output<java.lang.String> lockToken()  
      com.pulumi.core.Output<java.lang.String> name()  
      com.pulumi.core.Output<java.lang.String> namePrefix()  
      com.pulumi.core.Output<java.lang.String> region()  
      com.pulumi.core.Output<java.util.Optional<java.util.List<RegexPatternSetRegularExpression>>> regularExpressions()  
      com.pulumi.core.Output<java.lang.String> scope()  
      com.pulumi.core.Output<java.util.Optional<java.util.Map<java.lang.String,​java.lang.String>>> tags()  
      com.pulumi.core.Output<java.util.Map<java.lang.String,​java.lang.String>> tagsAll()  
      • Methods inherited from class com.pulumi.resources.CustomResource

        getId, id, idFuture
      • Methods inherited from class com.pulumi.resources.Resource

        getChildResources, getResourceName, getResourceType, getUrn, pulumiChildResources, pulumiResourceName, pulumiResourceType, urn
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • RegexPatternSet

        public RegexPatternSet​(java.lang.String name)
        Parameters:
        name - The _unique_ name of the resulting resource.
      • RegexPatternSet

        public RegexPatternSet​(java.lang.String name,
                               RegexPatternSetArgs args)
        Parameters:
        name - The _unique_ name of the resulting resource.
        args - The arguments to use to populate this resource's properties.
      • RegexPatternSet

        public RegexPatternSet​(java.lang.String name,
                               RegexPatternSetArgs args,
                               @Nullable
                               com.pulumi.resources.CustomResourceOptions options)
        Parameters:
        name - The _unique_ name of the resulting resource.
        args - The arguments to use to populate this resource's properties.
        options - A bag of options that control this resource's behavior.
    • Method Detail

      • arn

        public com.pulumi.core.Output<java.lang.String> arn()
        Returns:
        ARN that identifies the cluster.
      • description

        public com.pulumi.core.Output<java.util.Optional<java.lang.String>> description()
        Returns:
        A friendly description of the regular expression pattern set.
      • lockToken

        public com.pulumi.core.Output<java.lang.String> lockToken()
      • name

        public com.pulumi.core.Output<java.lang.String> name()
        Returns:
        A friendly name of the regular expression pattern set. If omitted, the provider will assign a random, unique name. Conflicts with `namePrefix`.
      • namePrefix

        public com.pulumi.core.Output<java.lang.String> namePrefix()
        Returns:
        Creates a unique name beginning with the specified prefix. Conflicts with `name`.
      • region

        public com.pulumi.core.Output<java.lang.String> region()
        Returns:
        Region where this resource will be [managed](https://docs.aws.amazon.com/general/latest/gr/rande.html#regional-endpoints). Defaults to the Region set in the provider configuration.
      • regularExpressions

        public com.pulumi.core.Output<java.util.Optional<java.util.List<RegexPatternSetRegularExpression>>> regularExpressions()
        Returns:
        One or more blocks of regular expression patterns that you want AWS WAF to search for, such as `B[a@]dB[o0]t`. See Regular Expression below for details.
      • scope

        public com.pulumi.core.Output<java.lang.String> scope()
        Returns:
        Specifies whether this is for an AWS CloudFront distribution or for a regional application. Valid values are `CLOUDFRONT` or `REGIONAL`. To work with CloudFront, you must also specify the region `us-east-1` (N. Virginia) on the AWS provider.
      • tags

        public com.pulumi.core.Output<java.util.Optional<java.util.Map<java.lang.String,​java.lang.String>>> tags()
        Returns:
        An array of key:value pairs to associate with the resource. If configured with a provider `defaultTags` configuration block present, tags with matching keys will overwrite those defined at the provider-level.
      • tagsAll

        public com.pulumi.core.Output<java.util.Map<java.lang.String,​java.lang.String>> tagsAll()
        Returns:
        A map of tags assigned to the resource, including those inherited from the provider `defaultTags` configuration block.
      • get

        public static RegexPatternSet get​(java.lang.String name,
                                          com.pulumi.core.Output<java.lang.String> id,
                                          @Nullable
                                          RegexPatternSetState state,
                                          @Nullable
                                          com.pulumi.resources.CustomResourceOptions options)
        Get an existing Host resource's state with the given name, ID, and optional extra properties used to qualify the lookup.
        Parameters:
        name - The _unique_ name of the resulting resource.
        id - The _unique_ provider ID of the resource to lookup.
        state -
        options - Optional settings to control the behavior of the CustomResource.