From 162f75423dbf870a88776913759f32dae92f7a0c Mon Sep 17 00:00:00 2001 From: md_5 Date: Thu, 10 Jan 2013 17:56:09 +1100 Subject: [PATCH] Add stub api class. --- .gitignore | 26 +++++----- api/pom.xml | 28 ++++++++++ .../java/net/md_5/bungee/api/ProxyServer.java | 16 ++++++ pom.xml | 43 ++------------- proxy/pom.xml | 52 ++++++++++++++----- 5 files changed, 101 insertions(+), 64 deletions(-) create mode 100644 api/pom.xml create mode 100644 api/src/main/java/net/md_5/bungee/api/ProxyServer.java diff --git a/.gitignore b/.gitignore index fb9eb761..fa02ff80 100644 --- a/.gitignore +++ b/.gitignore @@ -1,31 +1,31 @@ # Eclipse stuff -/.classpath -/.project -/.settings +.classpath/ +.project/ +.settings/ # netbeans -/nbproject +nbproject/ nbactions.xml nb-configuration.xml # we use maven! -/build.xml +build.xml # maven -/target -/dependency-reduced-pom.xml +target/ +dependency-reduced-pom.xml # vim .*.sw[a-p] # various other potential build files -/build -/bin -/dist -/manifest.mf +build/ +bin/ +dist/ +manifest.mf # Mac filesystem dust -/.DS_Store +.DS_Store/ # intellij *.iml @@ -34,5 +34,5 @@ nb-configuration.xml .idea/ # other files -/*log* +*.log* *.yml diff --git a/api/pom.xml b/api/pom.xml new file mode 100644 index 00000000..d3431afb --- /dev/null +++ b/api/pom.xml @@ -0,0 +1,28 @@ + + + 4.0.0 + + + net.md-5 + bungeecord-parent + 1.0-SNAPSHOT + ../pom.xml + + + net.md-5 + bungeecord-api + 1.0-SNAPSHOT + jar + + BungeeCord-API + API implemented by the Elastic Portal Suite + + + + com.google.guava + guava + 13.0.1 + + + diff --git a/api/src/main/java/net/md_5/bungee/api/ProxyServer.java b/api/src/main/java/net/md_5/bungee/api/ProxyServer.java new file mode 100644 index 00000000..1de8da1a --- /dev/null +++ b/api/src/main/java/net/md_5/bungee/api/ProxyServer.java @@ -0,0 +1,16 @@ +package net.md_5.bungee.api; + +import com.google.common.base.Preconditions; +import lombok.Getter; + +public abstract class ProxyServer { + + @Getter + private static ProxyServer instance; + + public static void setInstance(ProxyServer instance) { + Preconditions.checkNotNull(instance, "Instance null"); + Preconditions.checkArgument(instance == null, "Instance already set"); + ProxyServer.instance = instance; + } +} diff --git a/pom.xml b/pom.xml index 8463a12c..194e9cba 100644 --- a/pom.xml +++ b/pom.xml @@ -1,6 +1,5 @@ - - + + 4.0.0 @@ -15,7 +14,7 @@ pom BungeeCord - Proxy component of the Elastic Portal Suite + Parent project for all BungeeCord modules. https://github.com/ElasticPortalSuite/BungeeCord 2012 @@ -38,6 +37,7 @@ proxy + api @@ -57,7 +57,6 @@ UTF-8 unknown - net.md_5.bungee.BungeeCord @@ -70,7 +69,6 @@ - ${project.name} com.lukegb.mojo @@ -98,39 +96,6 @@ 1.7 - - com.github.wvengen - proguard-maven-plugin - 2.0.6 - - - package - - proguard - - - - - true - false - - ${java.home}/lib/rt.jar - ${java.home}/lib/jce.jar - - false - - - - - - - - net.sf.proguard - proguard-base - 4.8 - - - diff --git a/proxy/pom.xml b/proxy/pom.xml index d36cbbb3..b059709c 100644 --- a/proxy/pom.xml +++ b/proxy/pom.xml @@ -15,7 +15,7 @@ 1.0-SNAPSHOT jar - BungeeCord + BungeeCord-Proxy Proxy component of the Elastic Portal Suite @@ -24,16 +24,16 @@ jsr305 2.0.1 - - com.google.guava - guava - 13.0.1 - net.md-5 mendax 1.4.6-SNAPSHOT + + net.md-5 + bungeecord-api + ${project.version} + org.bouncycastle bcprov-ext-jdk15on @@ -44,15 +44,10 @@ snakeyaml 1.11 - - org.projectlombok - lombok - 0.11.6 - provided - + BungeeCord org.apache.maven.plugins @@ -93,6 +88,39 @@ + + com.github.wvengen + proguard-maven-plugin + 2.0.6 + + + package + + proguard + + + + + true + false + + ${java.home}/lib/rt.jar + ${java.home}/lib/jce.jar + + false + + + + + + + + net.sf.proguard + proguard-base + 4.8 + + +