Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
949e4ab
style: minor formatting and indentation changes
ApenasOLinco Nov 11, 2025
3848ef2
feat: create `ModInfoKeys.java`
ApenasOLinco Nov 14, 2025
6d7309e
feat: added a `modInfoKeys` parameter to the `Platform` constructor
ApenasOLinco Nov 14, 2025
722d2fc
feat: added `dependencyKeys` field to `ModInfoKeys.java`
ApenasOLinco Nov 14, 2025
81fff56
doc: added documentation to `ModInfoKeys.java`
ApenasOLinco Nov 14, 2025
c6f8923
feat: create functions `createModInfoFrom(JsonObject, Platform, BiFun…
ApenasOLinco Nov 15, 2025
a1567a4
feat: create `DataAdapter` and its implementations to make accessing …
ApenasOLinco Nov 15, 2025
68a7683
clean: remove unused method
ApenasOLinco Nov 19, 2025
670c1f5
refactor: Unify and improve version handling
ApenasOLinco Nov 19, 2025
c56ec55
Refactor: Convert DataAdapter to abstract class and add nested JSON a…
ApenasOLinco Nov 19, 2025
39ea4ab
fix: made bolder type checking inside the JsonAdapter.get* methods
ApenasOLinco Nov 20, 2025
5532a4f
feat: create individual parsers for mod dependencies
ApenasOLinco Nov 20, 2025
1fab742
refactor: remove type parameter from `ProvidedMod`
ApenasOLinco Nov 20, 2025
08f68c4
clean: remove method `fabricKeys()` from `ModInfoKeys`.
ApenasOLinco Nov 20, 2025
8a7d1a0
refactor: remove `BreaksList` interface
ApenasOLinco Nov 20, 2025
9d2fa91
fix: change MavenVersionRange to instantiate MavenVersion instead of …
ApenasOLinco Nov 20, 2025
9ed2176
fix: remove type parameter from interface `VersionRange`
ApenasOLinco Nov 20, 2025
434b336
fix: adapt more parts of the code to the Version Type parameter removal
ApenasOLinco Nov 20, 2025
ceb5a9b
fix: remove `breaks` references from `FabricModInfo`'s `toString`, `e…
ApenasOLinco Nov 20, 2025
6a4f4cf
feat: added `authors` field support to `BasicModInfo`s
ApenasOLinco Nov 20, 2025
6765a0b
fix: check for strings before getting versionRange as object inside `…
ApenasOLinco Nov 20, 2025
58c2ddf
fix: check for strings before getting object as an array inside `Toml…
ApenasOLinco Nov 20, 2025
c584f61
feat: full support to the new parsing system.
ApenasOLinco Nov 20, 2025
21846c9
feat: create `VersionFactory`
ApenasOLinco Nov 26, 2025
7d4d860
clean: remove `Version`'s default public constructor and its abstract…
ApenasOLinco Nov 26, 2025
9435fc5
refactor: move `MavenVersion`'s initializing logic to a proper `Maven…
ApenasOLinco Nov 26, 2025
f2d6828
refactor: move `LooseSemanticVersion`'s initializing logic to a prope…
ApenasOLinco Nov 26, 2025
13b86fa
clean: remove unnecessary imports
ApenasOLinco Nov 26, 2025
df6240f
refactor: make the platform enumerations pass their respective `Versi…
ApenasOLinco Nov 26, 2025
0631e11
refactor: use `VersionFactory` instead of `Version` inside `ParserUtils`
ApenasOLinco Nov 26, 2025
c54147c
chore: annotated `BasicModInfo#getAuthors` with @Nullable
ApenasOLinco Nov 26, 2025
ace1ef6
chore: remove redundant `private` modifier from the `JarInJarPlatform…
ApenasOLinco Nov 26, 2025
b7d5d94
chore: added final modifier to `DataAdapter`'s backingObject field
ApenasOLinco Nov 26, 2025
7de49ff
chore: imports inside `LooseSemanticVersion`
ApenasOLinco Nov 26, 2025
4df8ae9
refactor: make `DependencyChecker` use `VersionFactories` instead of …
ApenasOLinco Nov 26, 2025
2c5b693
refactor: make `authors` constructor parameter @Nullable inside `Fabr…
ApenasOLinco Nov 26, 2025
611f831
refactor: make `FabricVersionRange` use `VersionFactories` instead of…
ApenasOLinco Nov 26, 2025
550e423
chore: remove unnecessary import
ApenasOLinco Nov 26, 2025
aca7e2c
refactor: make `MavenVersionRange` use `VersionFactories` instead of …
ApenasOLinco Nov 26, 2025
6a5017e
fix: parsing Neoforge mods was throwing an exception
ApenasOLinco Nov 26, 2025
e486f26
refactor: make `LooseSemanticVersionParserTests.java` use `LooseSeman…
ApenasOLinco Nov 26, 2025
6a7237e
fix: add `!isJsonNull()` check before any operations with the element…
ApenasOLinco Nov 26, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ public enum JarInJarPlatform {

private final String[] metadataFiles;

private JarInJarPlatform(String... metadataFiles) {
JarInJarPlatform(String... metadataFiles) {
this.metadataFiles = metadataFiles;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@
import me.andreasmelone.basicmodinfoparser.platform.dependency.PresenceStatus;
import me.andreasmelone.basicmodinfoparser.platform.dependency.fabric.LooseSemanticVersion;
import me.andreasmelone.basicmodinfoparser.platform.dependency.forge.MavenVersion;
import me.andreasmelone.basicmodinfoparser.platform.dependency.version.LooseSemanticVersionFactory;
import me.andreasmelone.basicmodinfoparser.platform.dependency.version.MavenVersionFactory;
import me.andreasmelone.basicmodinfoparser.platform.modinfo.StandardBasicModInfo;
import me.andreasmelone.basicmodinfoparser.util.Pair;

Expand All @@ -54,15 +56,28 @@ public static Pair<Boolean, Map<Dependency, PresenceStatus>> checkDependencies(S
boolean isFabricBased = loaderInfo.getPlatform() == Platform.FABRIC || loaderInfo.getPlatform() == Platform.QUILT;
if (isFabricBased) {
javaInfo = new StandardBasicModInfo(
"java", "Java",
LooseSemanticVersion.parse(javaVersion).orElse(null),
"Java", new ArrayList<>(), null, Platform.FABRIC
"java",
"Java",
new LooseSemanticVersionFactory().parseVersion(javaVersion).orElse(null),
"Java",
new ArrayList<>(),
null,
Platform.FABRIC,
null
);
}
BasicModInfo gameInfo = new StandardBasicModInfo(
"minecraft", "Minecraft",
(isFabricBased ? LooseSemanticVersion.parse(gameVersion) : MavenVersion.parse(gameVersion)).orElse(null),
"Minecraft", new ArrayList<>(), null, loaderInfo.getPlatform()
"minecraft",
"Minecraft",
(isFabricBased
? new LooseSemanticVersionFactory().parseVersion(gameVersion)
: new MavenVersionFactory().parseVersion(gameVersion))
.orElse(null),
"Minecraft",
new ArrayList<>(),
null,
loaderInfo.getPlatform(),
null
);

Map<Dependency, PresenceStatus> dependencyMap = new HashMap<>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public interface BasicModInfo {
*
* @return the version of the mod
*/
@Nullable Version<?> getVersion();
@Nullable Version getVersion();

/**
* The mods description
Expand All @@ -76,4 +76,9 @@ public interface BasicModInfo {
* @return the platform that this mod is for
*/
@NotNull Platform getPlatform();

/**
* @return the authors of the mod
*/
@Nullable List<String> getAuthors();
}
Loading