-
Notifications
You must be signed in to change notification settings - Fork 470
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
14 changed files
with
38 additions
and
34 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...ses/src/main/java/jvm/jls8/StringOut.java → ...classes/src/main/java/jls8/StringOut.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
package jvm.jls8; | ||
package jls8; | ||
|
||
import java.io.PrintWriter; | ||
import java.io.StringWriter; | ||
|
4 changes: 2 additions & 2 deletions
4
...c/main/java/jvm/jls8/ch12/Eg12_4_1_1.java → ...s/src/main/java/jls8/ch12/Eg12_4_1_1.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...c/main/java/jvm/jls8/ch12/Eg12_4_1_2.java → ...s/src/main/java/jls8/ch12/Eg12_4_1_2.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
package jvm.jls8.ch12; | ||
package jls8.ch12; | ||
|
||
import helper.UnitTestRunner; | ||
import org.junit.Test; | ||
|
4 changes: 2 additions & 2 deletions
4
...c/main/java/jvm/jls8/ch12/Eg12_4_1_3.java → ...s/src/main/java/jls8/ch12/Eg12_4_1_3.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
...src/main/java/jvm/jls8/ch12/Eg12_5_2.java → ...ses/src/main/java/jls8/ch12/Eg12_5_2.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
2 changes: 1 addition & 1 deletion
2
...java7/jsr292/MethodHandleNativesTest.java → .../jvm7/jsr292/MethodHandleNativesTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
package jvm.java7.jsr292; | ||
package jvm7.jsr292; | ||
|
||
import helper.ReflectionHelper; | ||
import helper.UnitTestRunner; | ||
|
2 changes: 1 addition & 1 deletion
2
...va/jvm/java7/jsr292/MethodHandleTest.java → ...in/java/jvm7/jsr292/MethodHandleTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
...java/jvm/java7/jsr292/MethodTypeTest.java → ...main/java/jvm7/jsr292/MethodTypeTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
package jvm.java7.jsr292; | ||
package jvm7.jsr292; | ||
|
||
import java.lang.invoke.MethodType; | ||
|
||
|
2 changes: 1 addition & 1 deletion
2
...jvm/java8/InterfaceDefaultMethodTest.java → ...java/jvm8/InterfaceDefaultMethodTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
package jvm.java8; | ||
package jvm8; | ||
|
||
import junit.framework.Assert; | ||
import helper.UnitTestRunner; | ||
|
2 changes: 1 addition & 1 deletion
2
...n/java/jvm/java8/InterfaceMethodTest.java → ...c/main/java/jvm8/InterfaceMethodTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
package jvm.java8; | ||
package jvm8; | ||
|
||
import helper.UnitTestRunner; | ||
import org.junit.Test; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
package jvm8; | ||
|
||
public class LambdaTest { | ||
|
||
public static void main(String[] args) { | ||
Runnable r = () -> System.out.println("Hello, World!"); | ||
r.run(); | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,18 @@ | ||
package stdlib.net; | ||
|
||
import java.io.InputStream; | ||
import java.net.URL; | ||
|
||
public class UrlTest { | ||
|
||
public static void main(String[] args) throws Exception { | ||
URL url = new URL("http://cn.bing.com"); | ||
url.openStream(); | ||
try (InputStream is = url.openStream()) { | ||
byte[] bytes = new byte[is.available()]; | ||
int n = is.read(bytes); | ||
System.out.println(new String(bytes)); | ||
} | ||
System.out.println("OK!"); | ||
} | ||
|
||
} |