-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from Aelysium-Group/development
Implement /tpa, /rc send, bstats, and more
- Loading branch information
Showing
70 changed files
with
3,283 additions
and
264 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
53 changes: 53 additions & 0 deletions
53
core/src/main/java/group/aelysium/rustyconnector/core/lib/Version.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
package group.aelysium.rustyconnector.core.lib; | ||
|
||
public class Version { | ||
protected int major; | ||
protected int minor; | ||
protected int fix; | ||
|
||
public Version(int major, int minor, int fix) { | ||
this.major = major; | ||
this.minor = minor; | ||
this.fix = fix; | ||
} | ||
public Version(String string) throws NumberFormatException{ | ||
String[] stringSplit = string.split("\\."); | ||
this.major = Integer.parseInt(stringSplit[0]); | ||
this.minor = Integer.parseInt(stringSplit[1]); | ||
this.fix = Integer.parseInt(stringSplit[2]); | ||
} | ||
public int getMajor() { | ||
return major; | ||
} | ||
|
||
public int getMinor() { | ||
return minor; | ||
} | ||
|
||
public int getFix() { | ||
return fix; | ||
} | ||
|
||
public boolean isGreaterThan(Version anotherVersion) { | ||
if(!(this.getMajor() == this.getMinor())) return this.getMajor() > this.getMinor(); | ||
if(!(this.getMinor() == this.getMinor())) return this.getMinor() > this.getMinor(); | ||
return this.getFix() > this.getFix(); | ||
} | ||
|
||
public boolean equals(Version anotherVersion) { | ||
return (this.getMajor() == anotherVersion.getMajor()) && | ||
(this.getMinor() == anotherVersion.getMinor()) && | ||
(this.getFix() == anotherVersion.getFix()); | ||
} | ||
|
||
public String toString() { | ||
return this.major +"."+ this.minor +"."+ this.fix; | ||
} | ||
|
||
public static Version create(int major, int minor, int fix) { | ||
return new Version(major, minor, fix); | ||
} | ||
public static Version create(String string) { | ||
return new Version(string); | ||
} | ||
} |
18 changes: 18 additions & 0 deletions
18
core/src/main/java/group/aelysium/rustyconnector/core/lib/config/MigrationDirections.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package group.aelysium.rustyconnector.core.lib.config; | ||
|
||
import java.util.HashMap; | ||
import java.util.Map; | ||
|
||
public class MigrationDirections { | ||
private static final Map<Integer, String> directions = new HashMap<>(); | ||
|
||
public static void init() { | ||
directions.put(1 + 2, "https://github.com/Aelysium-Group/rusty-connector/wiki/Update-from-Config-v1-to-v2"); | ||
} | ||
|
||
public static String findUpgradeDirections(int from, int to) { | ||
String url = directions.get(from + to); | ||
if(url == null) return "https://github.com/Aelysium-Group/rusty-connector/wiki/Config-Migration"; | ||
return url; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 0 additions & 2 deletions
2
core/src/main/java/group/aelysium/rustyconnector/core/lib/data_messaging/MessageHandler.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 0 additions & 1 deletion
1
...in/java/group/aelysium/rustyconnector/core/lib/data_messaging/cache/CacheableMessage.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 0 additions & 3 deletions
3
core/src/main/java/group/aelysium/rustyconnector/core/lib/database/Redis.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.