< prev index next >

test/com/sun/jdi/ListenAddress.java

Print this page
rev 16783 : 8176176: fix @modules in jdk_svc tests
Reviewed-by: duke


   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  */
  23 
  24 /* @test
  25  * @bug 4932074
  26  * @summary Test that startListening(Map) method of the com.sun.jdi.SocketListen
  27  *          Connector returns an address that is usable for the address option on
  28  *          remove debuggees.
  29  * @modules jdk.jdi
  30  */
  31 import java.net.InetAddress;
  32 import java.net.Inet4Address;
  33 import java.net.NetworkInterface;
  34 import java.io.IOException;
  35 import java.util.*;
  36 import com.sun.jdi.*;
  37 import com.sun.jdi.connect.*;
  38 
  39 public class ListenAddress {
  40 
  41     /*
  42      * Find Connector by name
  43      */
  44     private static Connector findConnector(String name) {
  45         List connectors = Bootstrap.virtualMachineManager().allConnectors();
  46         Iterator iter = connectors.iterator();
  47         while (iter.hasNext()) {
  48             Connector connector = (Connector)iter.next();
  49             if (connector.name().equals(name)) {




   9  * This code is distributed in the hope that it will be useful, but WITHOUT
  10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  12  * version 2 for more details (a copy is included in the LICENSE file that
  13  * accompanied this code).
  14  *
  15  * You should have received a copy of the GNU General Public License version
  16  * 2 along with this work; if not, write to the Free Software Foundation,
  17  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  18  *
  19  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  20  * or visit www.oracle.com if you need additional information or have any
  21  * questions.
  22  */
  23 
  24 /* @test
  25  * @bug 4932074
  26  * @summary Test that startListening(Map) method of the com.sun.jdi.SocketListen
  27  *          Connector returns an address that is usable for the address option on
  28  *          remove debuggees.

  29  */
  30 import java.net.InetAddress;
  31 import java.net.Inet4Address;
  32 import java.net.NetworkInterface;
  33 import java.io.IOException;
  34 import java.util.*;
  35 import com.sun.jdi.*;
  36 import com.sun.jdi.connect.*;
  37 
  38 public class ListenAddress {
  39 
  40     /*
  41      * Find Connector by name
  42      */
  43     private static Connector findConnector(String name) {
  44         List connectors = Bootstrap.virtualMachineManager().allConnectors();
  45         Iterator iter = connectors.iterator();
  46         while (iter.hasNext()) {
  47             Connector connector = (Connector)iter.next();
  48             if (connector.name().equals(name)) {


< prev index next >