--- a/hotspot/test/runtime/modules/ModuleStress/src/jdk.test/test/Main.java Thu Apr 06 17:01:01 2017 +0000
+++ b/hotspot/test/runtime/modules/ModuleStress/src/jdk.test/test/Main.java Fri Apr 07 08:04:46 2017 +0000
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2016, 2017, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -25,9 +25,7 @@
import java.lang.module.Configuration;
import java.lang.module.ModuleFinder;
-import java.lang.reflect.Layer;
import java.lang.reflect.Method;
-import java.lang.reflect.Module;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.util.*;
@@ -44,7 +42,7 @@
public static void main(String[] args) throws Exception {
ModuleFinder finder = ModuleFinder.of(MODS_DIR);
- Layer layerBoot = Layer.boot();
+ ModuleLayer layerBoot = ModuleLayer.boot();
Configuration cf = layerBoot
.configuration()
@@ -58,7 +56,7 @@
Callable<Void> task = new Callable<Void>() {
@Override
public Void call() throws Exception {
- Layer layer = Layer.boot().defineModulesWithOneLoader(cf, scl);
+ ModuleLayer layer = ModuleLayer.boot().defineModulesWithOneLoader(cf, scl);
Module transletModule = layer.findModule(MODULE_NAME).get();
testModule.addExports("test", transletModule);
Class<?> c = layer.findLoader(MODULE_NAME).loadClass("translet.Main");