import type { _NSCopying } from "../Foundation/NSCopying.js";
import type { _NSObject } from "../Foundation/NSObject.js";
import type { _NSSecureCoding } from "../Foundation/NSSecureCoding.js";
import type { _NWHostEndpoint } from "./NWHostEndpoint.js";
import type { NENetworkRuleProtocol } from "./NENetworkRuleProtocol.js";
import type { NETrafficDirection } from "./NETrafficDirection.js";
export declare class _NENetworkRule extends _NSObject {
    static alloc(): _NENetworkRule;
    static new(): _NENetworkRule;
    init(): _NENetworkRule;
    /**
     * @method initWithDestinationNetworkEndpoint:prefix:protocol: @discussion Initialize a newly-allocated NENetworkRule object that matches network traffic destined for a host within a specific network. @param networkEndpoint An endpoint object that contains the port and address or network that the rule matches. This endpoint must contain an address, not a hostname. If the address is a wildcard address (0.0.0.0 or ::) then the rule will match all destinations except for loopback (127.0.0.1 or ::1). To match loopback traffic set the address to the loopback address. If the port string of the endpoint is "0" or is the empty string, then the rule will match traffic on any port destined for the given address or network. @param destinationPrefix An integer that in combination with the address in the endpoint specifies the destination network that the rule matches. @param protocol A NENetworkRuleProtocol value indicating the protocol that the rule matches. @return The initialized NENetworkRule instance.
     */
    initWithDestinationNetworkEndpoint$prefix$protocol$(networkEndpoint: _NSObject, destinationPrefix: number, protocol: NENetworkRuleProtocol): _NENetworkRule;
    /**
     * @method initWithDestinationNetwork:prefix:protocol: @discussion Initialize a newly-allocated NENetworkRule object that matches network traffic destined for a host within a specific network. @param networkEndpoint An endpoint object that contains the port and address or network that the rule matches. This endpoint must contain an address, not a hostname. If the address is a wildcard address (0.0.0.0 or ::) then the rule will match all destinations except for loopback (127.0.0.1 or ::1). To match loopback traffic set the address to the loopback address. If the port string of the endpoint is "0" or is the empty string, then the rule will match traffic on any port destined for the given address or network. @param destinationPrefix An integer that in combination with the address in the endpoint specifies the destination network that the rule matches. @param protocol A NENetworkRuleProtocol value indicating the protocol that the rule matches. @return The initialized NENetworkRule instance.
     * @deprecated initWithDestinationNetworkEndpoint:prefix:protocol:
     */
    initWithDestinationNetwork$prefix$protocol$(networkEndpoint: _NWHostEndpoint, destinationPrefix: number, protocol: NENetworkRuleProtocol): _NENetworkRule;
    /**
     * @method initWithDestinationHostEndpoint:protocol: @discussion Initialize a newly-allocated NENetworkRule object that matches network traffic destined for a host within a specific DNS domain. @param hostEndpoint An endpoint object that contains the port and hostname or domain that the rule matches. This endpoint must contain a hostname, not an address. If the port string of the `nw_endpoint_t` is "0" or is the empty string, then the rule will match traffic on any port destined for the given hostname or domain. If the hostname string of the endpoint consists of a single label, then the rule will match traffic destined to the specific host with that single label as its name. If the hostname string of the endpoint consists of 2 or more labels, then the rule will match traffic destined to hosts within the domain specified by the hostname string. Examples: [[NENetworkRule alloc] initWithDestinationHost:nw_endpoint_create_host("com", "0") protocol:NENetworkRuleProtocolAny] - matches all TCP and UDP traffic to the host named "com". [[NENetworkRule alloc] initWithDestinationHost:nw_endpoint_create_host("example.com", "0") protocol:NENetworkRuleProtocolAny] - matches all TCP and UDP traffic to hosts in the "example.com" DNS domain, including all DNS queries for names in the example.com DNS domain. [[NENetworkRule alloc] initWithDestinationHost:nw_endpoint_create_host("example.com", "53") protocol:NENetworkRuleProtocolAny] - matches all DNS queries/responses for hosts in the "example.com" domain. [[NENetworkRule alloc] initWithDestinationHost:nw_endpoint_create_host("example.com", "443") protocol:NENetworkRuleProtocolTCP] - matches all TCP port 443 traffic to hosts in the "example.com" domain. @param protocol A NENetworkRuleProtocol value indicating the protocol that the rule matches. @return The initialized NENetworkRule instance.
     */
    initWithDestinationHostEndpoint$protocol$(hostEndpoint: _NSObject, protocol: NENetworkRuleProtocol): _NENetworkRule;
    /**
     * @method initWithDestinationHost:protocol: @discussion Initialize a newly-allocated NENetworkRule object that matches network traffic destined for a host within a specific DNS domain. @param hostEndpoint An endpoint object that contains the port and hostname or domain that the rule matches. This endpoint must contain a hostname, not an address. If the port string of the NWHostEndpoint is "0" or is the empty string, then the rule will match traffic on any port destined for the given hostname or domain. If the hostname string of the endpoint consists of a single label, then the rule will match traffic destined to the specific host with that single label as its name. If the hostname string of the endpoint consists of 2 or more labels, then the rule will match traffic destined to hosts within the domain specified by the hostname string. Examples: [[NENetworkRule alloc] initWithDestinationHost:[NWHostEndpoint endpointWithHostname:@"com" port:@"0"] protocol:NENetworkRuleProtocolAny] - matches all TCP and UDP traffic to the host named "com". [[NENetworkRule alloc] initWithDestinationHost:[NWHostEndpoint endpointWithHostname:@"example.com" port:@"0"] protocol:NENetworkRuleProtocolAny] - matches all TCP and UDP traffic to hosts in the "example.com" DNS domain, including all DNS queries for names in the example.com DNS domain. [[NENetworkRule alloc] initWithDestinationHost:[NWHostEndpoint endpointWithHostname:@"example.com" port:@"53"] protocol:NENetworkRuleProtocolAny] - matches all DNS queries/responses for hosts in the "example.com" domain. [[NENetworkRule alloc] initWithDestinationHost:[NWHostEndpoint endpointWithHostname:@"example.com" port:@"443"] protocol:NENetworkRuleProtocolTCP] - matches all TCP port 443 traffic to hosts in the "example.com" domain. @param protocol A NENetworkRuleProtocol value indicating the protocol that the rule matches. @return The initialized NENetworkRule instance.
     * @deprecated initWithDestinationHostEndpoint:protocol:
     */
    initWithDestinationHost$protocol$(hostEndpoint: _NWHostEndpoint, protocol: NENetworkRuleProtocol): _NENetworkRule;
    /**
     * @method initWithRemoteNetworkEndpoint:remotePrefix:localNetworkEndpoint:localPrefix:protocol:direction: @discussion Initialize a newly-allocated NENetworkRule object that matches traffic by remote network, local network, protocol, and direction. If both remoteNetwork and localNetwork are nil then the rule will match all traffic of the given protocol and direction, except for loopback traffic. To match loopback traffic create a NENetworkRule with remoteNetwork and/or localNetwork properties that explicitly match traffic to the loopback address (127.0.0.1 or ::1). @param remoteNetwork An endpoint object that contains the remote port and the remote address or network that the rule matches. This endpoint must contain an address, not a hostname. If the address is a wildcard address (0.0.0.0 or ::) then the rule will match all destinations except for loopback (127.0.0.1 or ::1). To match loopback traffic set the address to the loopback address. If the port string of the endpoint is "0" or is the empty string, then the rule will match traffic on any port coming from the remote network. Pass nil to cause the rule to match any remote network. @param remotePrefix An integer that in combination with the address in remoteNetwork specifies the remote network that the rule matches. @param localNetwork An endpoint object that contains the local port and the local address or network that the rule matches. This endpoint must contain an address, not a hostname. If the address is a wildcard address (0.0.0.0 or ::) then the rule will match all local networks except for loopback (127.0.0.1 or ::1). To match loopback traffic set the address to the loopback address. If the port string of the endpoint is "0" or is the empty string, then the rule will match traffic on any port coming from the local network. Pass nil to cause the rule to match any local network. @param localPrefix An integer that in combination with the address in localNetwork specifies the local network that the rule matches. This parameter is ignored if localNetwork is nil. @param protocol A NENetworkRuleProtocol value indicating the protocol that the rule matches. @param direction A NETrafficDirection value indicating the direction of network traffic that the rule matches. @return The initialized NENetworkRule instance.
     */
    initWithRemoteNetworkEndpoint$remotePrefix$localNetworkEndpoint$localPrefix$protocol$direction$(remoteNetwork: _NSObject | null, remotePrefix: number, localNetwork: _NSObject | null, localPrefix: number, protocol: NENetworkRuleProtocol, direction: NETrafficDirection): _NENetworkRule;
    /**
     * @method initWithRemoteNetwork:remotePrefix:localNetwork:localPrefix:protocol:direction: @discussion Initialize a newly-allocated NENetworkRule object that matches traffic by remote network, local network, protocol, and direction. If both remoteNetwork and localNetwork are nil then the rule will match all traffic of the given protocol and direction, except for loopback traffic. To match loopback traffic create a NENetworkRule with remoteNetwork and/or localNetwork properties that explicitly match traffic to the loopback address (127.0.0.1 or ::1). @param remoteNetwork An endpoint object that contains the remote port and the remote address or network that the rule matches. This endpoint must contain an address, not a hostname. If the address is a wildcard address (0.0.0.0 or ::) then the rule will match all destinations except for loopback (127.0.0.1 or ::1). To match loopback traffic set the address to the loopback address. If the port string of the endpoint is "0" or is the empty string, then the rule will match traffic on any port coming from the remote network. Pass nil to cause the rule to match any remote network. @param remotePrefix An integer that in combination with the address in remoteNetwork specifies the remote network that the rule matches. @param localNetwork An endpoint object that contains the local port and the local address or network that the rule matches. This endpoint must contain an address, not a hostname. If the address is a wildcard address (0.0.0.0 or ::) then the rule will match all local networks except for loopback (127.0.0.1 or ::1). To match loopback traffic set the address to the loopback address. If the port string of the endpoint is "0" or is the empty string, then the rule will match traffic on any port coming from the local network. Pass nil to cause the rule to match any local network. @param localPrefix An integer that in combination with the address in localNetwork specifies the local network that the rule matches. This parameter is ignored if localNetwork is nil. @param protocol A NENetworkRuleProtocol value indicating the protocol that the rule matches. @param direction A NETrafficDirection value indicating the direction of network traffic that the rule matches. @return The initialized NENetworkRule instance.
     * @deprecated initWithRemoteNetworkEndpoint:remotePrefix:localNetworkEndpoint:localPrefix:protocol:direction:
     */
    initWithRemoteNetwork$remotePrefix$localNetwork$localPrefix$protocol$direction$(remoteNetwork: _NWHostEndpoint | null, remotePrefix: number, localNetwork: _NWHostEndpoint | null, localPrefix: number, protocol: NENetworkRuleProtocol, direction: NETrafficDirection): _NENetworkRule;
    /**
     * @property matchRemoteHostOrNetworkEndpoint @discussion The remote endpoint that the rule matches.
     */
    matchRemoteHostOrNetworkEndpoint(): _NSObject;
    /**
     * @property matchRemoteEndpoint @discussion The remote endpoint that the rule matches.
     * @deprecated matchRemoteHostOrNetworkEndpoint
     */
    matchRemoteEndpoint(): _NWHostEndpoint;
    /**
     * @property matchRemotePrefix @discussion A number that specifies the remote sub-network that the rule matches. This property is set to NSNotFound for rules where matchRemoteEndpoint does not contain an IP address.
     */
    matchRemotePrefix(): number;
    /**
     * @property matchLocalNetworkEndpoint @discussion The local network that the rule matches.
     */
    matchLocalNetworkEndpoint(): _NSObject;
    /**
     * @property matchLocalNetwork @discussion The local network that the rule matches.
     * @deprecated matchLocalNetworkEndpoint
     */
    matchLocalNetwork(): _NWHostEndpoint;
    /**
     * @property matchLocalPrefix @discussion A number that specifies the local sub-network that the rule matches. This property is set to NSNotFound for rules with a nil matchLocalNetwork property.
     */
    matchLocalPrefix(): number;
    /**
     * @property matchProtocol @discussion A NENetworkRuleProtocol value containing the protocol that the rule matches.
     */
    matchProtocol(): NENetworkRuleProtocol;
    /**
     * @property matchDirection @discussion A NETrafficDirection value indicating the network traffic direction that the rule matches.
     */
    matchDirection(): NETrafficDirection;
}
export interface _NENetworkRule extends _NSSecureCoding, _NSCopying {
}
