# coding=utf-8
# *** WARNING: this file was generated by the Pulumi Terraform Bridge (tfgen) Tool. ***
# *** Do not edit by hand unless you're certain you know what you are doing! ***

import builtins
import copy
import warnings
import sys
import pulumi
import pulumi.runtime
from typing import Any, Mapping, Optional, Sequence, Union, overload
if sys.version_info >= (3, 11):
    from typing import NotRequired, TypedDict, TypeAlias
else:
    from typing_extensions import NotRequired, TypedDict, TypeAlias
from .. import _utilities

__all__ = [
    'PolicyNetRedirectPolicy',
]

@pulumi.output_type
class PolicyNetRedirectPolicy(dict):
    @staticmethod
    def __key_warning(key: str):
        suggest = None
        if key == "customProxy":
            suggest = "custom_proxy"
        elif key == "hostAddr":
            suggest = "host_addr"
        elif key == "netRedirect":
            suggest = "net_redirect"
        elif key == "proxyPassword":
            suggest = "proxy_password"
        elif key == "proxyType":
            suggest = "proxy_type"
        elif key == "proxyUserName":
            suggest = "proxy_user_name"

        if suggest:
            pulumi.log.warn(f"Key '{key}' not found in PolicyNetRedirectPolicy. Access the value via the '{suggest}' property getter instead.")

    def __getitem__(self, key: str) -> Any:
        PolicyNetRedirectPolicy.__key_warning(key)
        return super().__getitem__(key)

    def get(self, key: str, default = None) -> Any:
        PolicyNetRedirectPolicy.__key_warning(key)
        return super().get(key, default)

    def __init__(__self__, *,
                 custom_proxy: Optional[builtins.str] = None,
                 host_addr: Optional[builtins.str] = None,
                 net_redirect: Optional[builtins.str] = None,
                 port: Optional[builtins.str] = None,
                 proxy_password: Optional[builtins.str] = None,
                 proxy_type: Optional[builtins.str] = None,
                 proxy_user_name: Optional[builtins.str] = None):
        """
        :param builtins.str custom_proxy: Whether to manually configure the transparent proxy.
        :param builtins.str host_addr: The transparent proxy IP address. The format is IPv4 address.
        :param builtins.str net_redirect: Whether to enable network redirection.
        :param builtins.str port: Transparent proxy port. The Port value range is 1\\~ 65535.
        :param builtins.str proxy_password: The proxy password. The length range is 1\\~ 256. Chinese characters and white space characters are not allowed.
        :param builtins.str proxy_type: Agent protocol type.
        :param builtins.str proxy_user_name: The proxy user name. The length range is 1\\~ 256. Chinese characters and white space characters are not allowed.
        """
        if custom_proxy is not None:
            pulumi.set(__self__, "custom_proxy", custom_proxy)
        if host_addr is not None:
            pulumi.set(__self__, "host_addr", host_addr)
        if net_redirect is not None:
            pulumi.set(__self__, "net_redirect", net_redirect)
        if port is not None:
            pulumi.set(__self__, "port", port)
        if proxy_password is not None:
            pulumi.set(__self__, "proxy_password", proxy_password)
        if proxy_type is not None:
            pulumi.set(__self__, "proxy_type", proxy_type)
        if proxy_user_name is not None:
            pulumi.set(__self__, "proxy_user_name", proxy_user_name)

    @property
    @pulumi.getter(name="customProxy")
    def custom_proxy(self) -> Optional[builtins.str]:
        """
        Whether to manually configure the transparent proxy.
        """
        return pulumi.get(self, "custom_proxy")

    @property
    @pulumi.getter(name="hostAddr")
    def host_addr(self) -> Optional[builtins.str]:
        """
        The transparent proxy IP address. The format is IPv4 address.
        """
        return pulumi.get(self, "host_addr")

    @property
    @pulumi.getter(name="netRedirect")
    def net_redirect(self) -> Optional[builtins.str]:
        """
        Whether to enable network redirection.
        """
        return pulumi.get(self, "net_redirect")

    @property
    @pulumi.getter
    def port(self) -> Optional[builtins.str]:
        """
        Transparent proxy port. The Port value range is 1\\~ 65535.
        """
        return pulumi.get(self, "port")

    @property
    @pulumi.getter(name="proxyPassword")
    def proxy_password(self) -> Optional[builtins.str]:
        """
        The proxy password. The length range is 1\\~ 256. Chinese characters and white space characters are not allowed.
        """
        return pulumi.get(self, "proxy_password")

    @property
    @pulumi.getter(name="proxyType")
    def proxy_type(self) -> Optional[builtins.str]:
        """
        Agent protocol type.
        """
        return pulumi.get(self, "proxy_type")

    @property
    @pulumi.getter(name="proxyUserName")
    def proxy_user_name(self) -> Optional[builtins.str]:
        """
        The proxy user name. The length range is 1\\~ 256. Chinese characters and white space characters are not allowed.
        """
        return pulumi.get(self, "proxy_user_name")


