-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathJavaApiVersionInfo.java
More file actions
42 lines (33 loc) · 1.14 KB
/
JavaApiVersionInfo.java
File metadata and controls
42 lines (33 loc) · 1.14 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
package org.utplsql.api;
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
/**
* This class is getting updated automatically by the build process.
* Please do not update its constants manually cause they will be overwritten.
*
* @author pesse
*/
public class JavaApiVersionInfo {
private static final String MAVEN_PROJECT_NAME = "utPLSQL-java-api";
private static String MAVEN_PROJECT_VERSION = "unknown";
static {
try {
try (InputStream in = JavaApiVersionInfo.class.getClassLoader().getResourceAsStream("utplsql-api.version");
BufferedReader reader = new BufferedReader(new InputStreamReader(in))) {
MAVEN_PROJECT_VERSION = reader.readLine();
}
} catch (IOException e) {
System.out.println("WARNING: Could not get Version information!");
}
}
private JavaApiVersionInfo() {
}
public static String getVersion() {
return MAVEN_PROJECT_VERSION;
}
public static String getInfo() {
return MAVEN_PROJECT_NAME + " " + getVersion();
}
}