mirror of
https://github.com/HMCore/Core.git
synced 2025-12-12 13:56:19 +00:00
basic code for ObjectInfo configs
This commit is contained in:
@@ -17,6 +17,8 @@ repositories {
|
||||
|
||||
dependencies {
|
||||
implementation "org.jetbrains.kotlin:kotlin-stdlib"
|
||||
implementation 'com.google.code.gson:gson:2.8.6'
|
||||
|
||||
testImplementation 'org.junit.jupiter:junit-jupiter-api:5.6.0'
|
||||
testRuntimeOnly 'org.junit.jupiter:junit-jupiter-engine'
|
||||
}
|
||||
|
||||
12
src/main/java/org/hmcore/registration/config/ModuleInfo.java
Normal file
12
src/main/java/org/hmcore/registration/config/ModuleInfo.java
Normal file
@@ -0,0 +1,12 @@
|
||||
package org.hmcore.registration.config;
|
||||
|
||||
public class ModuleInfo {
|
||||
|
||||
public final String moduleName;
|
||||
public final ObjectInfoData[] objects;
|
||||
|
||||
public ModuleInfo(String moduleName, ObjectInfoData[] objects) {
|
||||
this.moduleName = moduleName;
|
||||
this.objects = objects;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,10 @@
|
||||
package org.hmcore.registration.config;
|
||||
|
||||
public class ObjectInfoConfig {
|
||||
|
||||
public final ModuleInfo[] modules;
|
||||
|
||||
public ObjectInfoConfig(ModuleInfo[] modules) {
|
||||
this.modules = modules;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
package org.hmcore.registration.config;
|
||||
|
||||
import org.hmcore.modules.Module;
|
||||
|
||||
public class ObjectInfoConfigHandler {
|
||||
|
||||
public static String generateFreshJSON(Module<?,?>[] modules) {
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -0,0 +1,14 @@
|
||||
package org.hmcore.registration.config;
|
||||
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
public class ObjectInfoData {
|
||||
|
||||
public final String objectName;
|
||||
public final String objectInfoChoosen;
|
||||
|
||||
public ObjectInfoData(String objectName, @Nullable String objectInfoChoosen) {
|
||||
this.objectName = objectName;
|
||||
this.objectInfoChoosen = objectInfoChoosen == null ? "default" : objectInfoChoosen;
|
||||
}
|
||||
}
|
||||
4
src/main/java/org/hmcore/registration/package-info.java
Normal file
4
src/main/java/org/hmcore/registration/package-info.java
Normal file
@@ -0,0 +1,4 @@
|
||||
/**
|
||||
* Classes used for registration purposes. Internal stuff!
|
||||
*/
|
||||
package org.hmcore.registration;
|
||||
Reference in New Issue
Block a user