All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.aws.ec2.inputs.GetSecurityGroupArgs Maven / Gradle / Ivy

Go to download

A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.

There is a newer version: 6.60.0-alpha.1731982519
Show newest version
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.aws.ec2.inputs;

import com.pulumi.aws.ec2.inputs.GetSecurityGroupFilterArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.String;
import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class GetSecurityGroupArgs extends com.pulumi.resources.InvokeArgs {

    public static final GetSecurityGroupArgs Empty = new GetSecurityGroupArgs();

    /**
     * Custom filter block as described below.
     * 
     */
    @Import(name="filters")
    private @Nullable Output> filters;

    /**
     * @return Custom filter block as described below.
     * 
     */
    public Optional>> filters() {
        return Optional.ofNullable(this.filters);
    }

    /**
     * Id of the specific security group to retrieve.
     * 
     */
    @Import(name="id")
    private @Nullable Output id;

    /**
     * @return Id of the specific security group to retrieve.
     * 
     */
    public Optional> id() {
        return Optional.ofNullable(this.id);
    }

    /**
     * Name of the field to filter by, as defined by
     * [the underlying AWS API](http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeSecurityGroups.html).
     * 
     */
    @Import(name="name")
    private @Nullable Output name;

    /**
     * @return Name of the field to filter by, as defined by
     * [the underlying AWS API](http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeSecurityGroups.html).
     * 
     */
    public Optional> name() {
        return Optional.ofNullable(this.name);
    }

    /**
     * Map of tags, each pair of which must exactly match
     * a pair on the desired security group.
     * 
     */
    @Import(name="tags")
    private @Nullable Output> tags;

    /**
     * @return Map of tags, each pair of which must exactly match
     * a pair on the desired security group.
     * 
     */
    public Optional>> tags() {
        return Optional.ofNullable(this.tags);
    }

    /**
     * Id of the VPC that the desired security group belongs to.
     * 
     * More complex filters can be expressed using one or more `filter` sub-blocks,
     * which take the following arguments:
     * 
     */
    @Import(name="vpcId")
    private @Nullable Output vpcId;

    /**
     * @return Id of the VPC that the desired security group belongs to.
     * 
     * More complex filters can be expressed using one or more `filter` sub-blocks,
     * which take the following arguments:
     * 
     */
    public Optional> vpcId() {
        return Optional.ofNullable(this.vpcId);
    }

    private GetSecurityGroupArgs() {}

    private GetSecurityGroupArgs(GetSecurityGroupArgs $) {
        this.filters = $.filters;
        this.id = $.id;
        this.name = $.name;
        this.tags = $.tags;
        this.vpcId = $.vpcId;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(GetSecurityGroupArgs defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private GetSecurityGroupArgs $;

        public Builder() {
            $ = new GetSecurityGroupArgs();
        }

        public Builder(GetSecurityGroupArgs defaults) {
            $ = new GetSecurityGroupArgs(Objects.requireNonNull(defaults));
        }

        /**
         * @param filters Custom filter block as described below.
         * 
         * @return builder
         * 
         */
        public Builder filters(@Nullable Output> filters) {
            $.filters = filters;
            return this;
        }

        /**
         * @param filters Custom filter block as described below.
         * 
         * @return builder
         * 
         */
        public Builder filters(List filters) {
            return filters(Output.of(filters));
        }

        /**
         * @param filters Custom filter block as described below.
         * 
         * @return builder
         * 
         */
        public Builder filters(GetSecurityGroupFilterArgs... filters) {
            return filters(List.of(filters));
        }

        /**
         * @param id Id of the specific security group to retrieve.
         * 
         * @return builder
         * 
         */
        public Builder id(@Nullable Output id) {
            $.id = id;
            return this;
        }

        /**
         * @param id Id of the specific security group to retrieve.
         * 
         * @return builder
         * 
         */
        public Builder id(String id) {
            return id(Output.of(id));
        }

        /**
         * @param name Name of the field to filter by, as defined by
         * [the underlying AWS API](http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeSecurityGroups.html).
         * 
         * @return builder
         * 
         */
        public Builder name(@Nullable Output name) {
            $.name = name;
            return this;
        }

        /**
         * @param name Name of the field to filter by, as defined by
         * [the underlying AWS API](http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeSecurityGroups.html).
         * 
         * @return builder
         * 
         */
        public Builder name(String name) {
            return name(Output.of(name));
        }

        /**
         * @param tags Map of tags, each pair of which must exactly match
         * a pair on the desired security group.
         * 
         * @return builder
         * 
         */
        public Builder tags(@Nullable Output> tags) {
            $.tags = tags;
            return this;
        }

        /**
         * @param tags Map of tags, each pair of which must exactly match
         * a pair on the desired security group.
         * 
         * @return builder
         * 
         */
        public Builder tags(Map tags) {
            return tags(Output.of(tags));
        }

        /**
         * @param vpcId Id of the VPC that the desired security group belongs to.
         * 
         * More complex filters can be expressed using one or more `filter` sub-blocks,
         * which take the following arguments:
         * 
         * @return builder
         * 
         */
        public Builder vpcId(@Nullable Output vpcId) {
            $.vpcId = vpcId;
            return this;
        }

        /**
         * @param vpcId Id of the VPC that the desired security group belongs to.
         * 
         * More complex filters can be expressed using one or more `filter` sub-blocks,
         * which take the following arguments:
         * 
         * @return builder
         * 
         */
        public Builder vpcId(String vpcId) {
            return vpcId(Output.of(vpcId));
        }

        public GetSecurityGroupArgs build() {
            return $;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy