mirror of
https://github.com/PolyhedralDev/Terra.git
synced 2026-04-07 16:26:13 +00:00
addon dependency sorting
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package com.dfsek.terra.api.addon;
|
||||
|
||||
|
||||
import ca.solostudios.strata.Versions;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
|
||||
import com.dfsek.terra.api.addon.annotations.Addon;
|
||||
@@ -11,6 +12,8 @@ import com.dfsek.terra.api.addon.annotations.Version;
|
||||
/**
|
||||
* Represents an entry point for an com.dfsek.terra.addon. Implementations must be annotated with {@link Addon}.
|
||||
*/
|
||||
|
||||
//todo delete this
|
||||
public abstract class TerraAddon implements BaseAddon {
|
||||
/**
|
||||
* Invoked immediately after an com.dfsek.terra.addon is loaded.
|
||||
@@ -22,9 +25,9 @@ public abstract class TerraAddon implements BaseAddon {
|
||||
*
|
||||
* @return Addon version.
|
||||
*/
|
||||
public final @NotNull String getVersion() {
|
||||
public final @NotNull ca.solostudios.strata.version.Version getVersion() {
|
||||
Version version = getClass().getAnnotation(Version.class);
|
||||
return version == null ? "0.1.0" : version.value();
|
||||
return Versions.getVersion(1, 2, 3);
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user