Remove name duplication
This commit is contained in:
parent
72df37d944
commit
90563b9545
@ -1,12 +0,0 @@
|
||||
// HelloDate.java
|
||||
// (c)2016 MindView LLC: see Copyright.txt
|
||||
// We make no guarantees that this code is fit for any purpose.
|
||||
// Visit http://OnJava8.com for more book information.
|
||||
import java.util.*;
|
||||
|
||||
public class HelloDate {
|
||||
public static void main(String[] args) {
|
||||
System.out.println("Hello, it's: ");
|
||||
System.out.println(new Date());
|
||||
}
|
||||
}
|
@ -1,4 +1,4 @@
|
||||
// arrays/IceCream.java
|
||||
// arrays/IceCreamFlavors.java
|
||||
// (c)2016 MindView LLC: see Copyright.txt
|
||||
// We make no guarantees that this code is fit for any purpose.
|
||||
// Visit http://OnJava8.com for more book information.
|
||||
@ -6,7 +6,7 @@
|
||||
import java.util.*;
|
||||
import static onjava.ArrayShow.*;
|
||||
|
||||
public class IceCream {
|
||||
public class IceCreamFlavors {
|
||||
private static SplittableRandom rand =
|
||||
new SplittableRandom(47);
|
||||
static final String[] FLAVORS = {
|
@ -1,10 +1,10 @@
|
||||
// collections/CollectionMethods.java
|
||||
// collections/CollectionDifferences.java
|
||||
// (c)2016 MindView LLC: see Copyright.txt
|
||||
// We make no guarantees that this code is fit for any purpose.
|
||||
// Visit http://OnJava8.com for more book information.
|
||||
import onjava.*;
|
||||
|
||||
public class CollectionMethods {
|
||||
public class CollectionDifferences {
|
||||
public static void main(String[] args) {
|
||||
CollectionMethodDifferences.main(args);
|
||||
}
|
@ -1,4 +1,4 @@
|
||||
// concurrent/CollectionToStream.java
|
||||
// concurrent/CollectionIntoStream.java
|
||||
// (c)2016 MindView LLC: see Copyright.txt
|
||||
// We make no guarantees that this code is fit for any purpose.
|
||||
// Visit http://OnJava8.com for more book information.
|
||||
@ -6,7 +6,7 @@ import onjava.*;
|
||||
import java.util.*;
|
||||
import java.util.stream.*;
|
||||
|
||||
public class CollectionToStream {
|
||||
public class CollectionIntoStream {
|
||||
public static void main(String[] args) {
|
||||
List<String> strings =
|
||||
Stream.generate(new Rand.String(5))
|
@ -13,7 +13,7 @@ public class ChatterTest {
|
||||
}
|
||||
@Test
|
||||
void chatterTest() throws Exception {
|
||||
// <* These need to be handed to an executor: *>
|
||||
// <* These must be handed to an executor: *>
|
||||
new ChatterServer();
|
||||
new ChatterClient(InetAddress.getLocalHost());
|
||||
// No exceptions means success
|
||||
|
@ -4,23 +4,9 @@
|
||||
// Visit http://OnJava8.com for more book information.
|
||||
import java.util.*;
|
||||
|
||||
/** The first On Java example program.
|
||||
* Displays a String and today's date.
|
||||
* @author Bruce Eckel
|
||||
* @author www.MindviewInc.com
|
||||
* @version 5.0
|
||||
*/
|
||||
public class HelloDate {
|
||||
/** Entry point to class & application.
|
||||
* @param args array of String arguments
|
||||
* @throws exceptions No exceptions thrown
|
||||
*/
|
||||
public static void main(String[] args) {
|
||||
System.out.println("Hello, it's: ");
|
||||
System.out.println(new Date());
|
||||
}
|
||||
}
|
||||
/* Output:
|
||||
Hello, it's:
|
||||
Wed Jul 27 10:50:45 MDT 2016
|
||||
*/
|
||||
|
26
objects/HelloDateDoc.java
Normal file
26
objects/HelloDateDoc.java
Normal file
@ -0,0 +1,26 @@
|
||||
// objects/HelloDateDoc.java
|
||||
// (c)2016 MindView LLC: see Copyright.txt
|
||||
// We make no guarantees that this code is fit for any purpose.
|
||||
// Visit http://OnJava8.com for more book information.
|
||||
import java.util.*;
|
||||
|
||||
/** The first On Java 8 example program.
|
||||
* Displays a String and today's date.
|
||||
* @author Bruce Eckel
|
||||
* @author www.MindviewInc.com
|
||||
* @version 5.0
|
||||
*/
|
||||
public class HelloDateDoc {
|
||||
/** Entry point to class & application.
|
||||
* @param args array of String arguments
|
||||
* @throws exceptions No exceptions thrown
|
||||
*/
|
||||
public static void main(String[] args) {
|
||||
System.out.println("Hello, it's: ");
|
||||
System.out.println(new Date());
|
||||
}
|
||||
}
|
||||
/* Output:
|
||||
Hello, it's:
|
||||
Wed Jul 27 10:50:45 MDT 2016
|
||||
*/
|
Loading…
x
Reference in New Issue
Block a user