Initial commit for BAEL-1500
This commit is contained in:
parent
2332bc1a14
commit
be90e9870c
|
@ -0,0 +1,28 @@
|
|||
package com.baeldung.javac;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
public class Data implements Serializable {
|
||||
static List<String> textList = new ArrayList();
|
||||
|
||||
private static void addText() {
|
||||
textList.add("baeldung");
|
||||
textList.add(".");
|
||||
textList.add("com");
|
||||
}
|
||||
|
||||
public List getTextList() {
|
||||
this.addText();
|
||||
List<String> result = new ArrayList<String>();
|
||||
String firstElement = (String) textList.get(0);
|
||||
switch (firstElement) {
|
||||
case "baeldung":
|
||||
result.add("baeldung");
|
||||
case "com":
|
||||
result.add("com");
|
||||
}
|
||||
return result;
|
||||
}
|
||||
}
|
|
@ -0,0 +1,2 @@
|
|||
-d javac-target -verbose
|
||||
com/baeldung/javac/Data.java
|
|
@ -0,0 +1,2 @@
|
|||
-d javac-target
|
||||
-verbose
|
|
@ -0,0 +1 @@
|
|||
com/baeldung/javac/Data.java
|
|
@ -0,0 +1,3 @@
|
|||
-d javac-target
|
||||
-Xlint:rawtypes,unchecked,static,cast,serial,fallthrough
|
||||
com/baeldung/javac/Data.java
|
Loading…
Reference in New Issue