public final class PaperBuilder extends Object
| Modifier and Type | Field and Description |
|---|---|
private static String |
API_PROJECT_VERSION_URL |
private static String |
apiProjectUrl |
private static String |
apiProjectVersionDownload |
private static Process |
exec |
private static com.google.gson.Gson |
gson |
| Constructor and Description |
|---|
PaperBuilder() |
| Modifier and Type | Method and Description |
|---|---|
private static boolean |
buildPaperVersion(String version,
Path outputPath)
Build or copy the paper spigot
|
static Process |
getExec() |
(package private) static void |
printProcessOutputToConsole(Process exec)
Print the process output to wrapper console
|
private static void |
runPaperClip(URLConnection connection,
File buildFolder,
File paperclip,
Path outputPath)
Run paperclip if the jar not exists
|
static boolean |
start(jline.console.ConsoleReader reader,
Path outputPath)
Start the process of choice the paper version And build after choice
|
private static com.google.gson.Gson gson
private static Process exec
private static String apiProjectUrl
private static String apiProjectVersionDownload
private static String API_PROJECT_VERSION_URL
public static boolean start(jline.console.ConsoleReader reader,
Path outputPath)
reader - Read the answer from consoleprivate static boolean buildPaperVersion(String version, Path outputPath) throws Exception
version - the version of the paper jarException - If a connection error or somethingprivate static void runPaperClip(URLConnection connection, File buildFolder, File paperclip, Path outputPath) throws IOException
connection - the connection of the jarbuildFolder - the build folder of the jarpaperclip - the jar file pathIOException - Throws if input stream nullstatic void printProcessOutputToConsole(Process exec) throws IOException
exec - the running processIOException - throws if readline nullpublic static Process getExec()
Copyright © 2020. All rights reserved.