Microsoft SDK for Java

addAddress

The addAddress of the NetIOPermission Class contains the following signatures:

addAddress(int flags, InetAddress addr)
addAddress(int flags, InetAddress addr, IntRanges ports)

addAddress(int flags, InetAddress addr)

Adds an InetAddress object to the permissions with no port rules. The permission will allow access to all ports, unless global rules have been previously specified.

Syntax

public void addAddress(int flags, InetAddress addr);

Parameters

flags The access flags, which consist of two separate flags combined with a logical OR operator (|). The first flag should be BIND, CONNECT, MULTICAST, or ALL_API_FLAGS to specify the connection type. The second flag should be either ALLOW or DENY to indicate whether the InetAddress object being added should use the include or exclude rules. For convenience, instead of using the logical OR operator with the two flags, you can use one of the combination flags: ALLOWALL, DENYALL, ALLOWCONNECT, DENYCONNECT, ALLOWBIND, DENYBIND, ALLOWMULTICAST, or DENYMULTICAST.
addr The Internet address that the access flags apply to.

addAddress(int flags, InetAddress addr, IntRanges ports)

Adds an InetAddress object to the permissions with the specified port rules.

Syntax

public void addAddress(int flags, InetAddress addr, IntRanges ports);

Parameters

flags The access flags, which consist of two separate flags combined with a logical OR operator (|). The first flag should be either BIND or CONNECT to specify the connection type. The second flag should be either ALLOW or DENY to indicate whether the InetAddress object being added should use the include or exclude rules. For convenience, instead of using the logical OR operator with the two flags, you can use one of the combination flags: ALLOWALL, DENYALL, ALLOWCONNECT, DENYCONNECT, ALLOWBIND, or DENYBIND.
addr The Internet address that the access flags apply to.
ports The ports that apply on the address.

© 1999 Microsoft Corporation. All rights reserved. Terms of use.