diff options
Diffstat (limited to 'src/main/java/io')
7 files changed, 98 insertions, 0 deletions
diff --git a/src/main/java/io/polyfrost/oneconfig/annotations/Button.java b/src/main/java/io/polyfrost/oneconfig/annotations/Button.java new file mode 100644 index 0000000..98b735f --- /dev/null +++ b/src/main/java/io/polyfrost/oneconfig/annotations/Button.java @@ -0,0 +1,14 @@ +package io.polyfrost.oneconfig.annotations; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Retention(RetentionPolicy.RUNTIME) +@Target(ElementType.FIELD) +public @interface Button { + String name(); + String description() default ""; + String text() default "Button"; +} diff --git a/src/main/java/io/polyfrost/oneconfig/annotations/Category.java b/src/main/java/io/polyfrost/oneconfig/annotations/Category.java new file mode 100644 index 0000000..05449dc --- /dev/null +++ b/src/main/java/io/polyfrost/oneconfig/annotations/Category.java @@ -0,0 +1,12 @@ +package io.polyfrost.oneconfig.annotations; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Retention(RetentionPolicy.RUNTIME) +@Target(ElementType.TYPE) +public @interface Category { + String name(); +} diff --git a/src/main/java/io/polyfrost/oneconfig/annotations/ColorPicker.java b/src/main/java/io/polyfrost/oneconfig/annotations/ColorPicker.java new file mode 100644 index 0000000..bf997a6 --- /dev/null +++ b/src/main/java/io/polyfrost/oneconfig/annotations/ColorPicker.java @@ -0,0 +1,14 @@ +package io.polyfrost.oneconfig.annotations; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Retention(RetentionPolicy.RUNTIME) +@Target(ElementType.FIELD) +public @interface ColorPicker { + String name(); + String description() default ""; + boolean allowAlpha() default true; +} diff --git a/src/main/java/io/polyfrost/oneconfig/annotations/Selector.java b/src/main/java/io/polyfrost/oneconfig/annotations/Selector.java new file mode 100644 index 0000000..39d238c --- /dev/null +++ b/src/main/java/io/polyfrost/oneconfig/annotations/Selector.java @@ -0,0 +1,15 @@ +package io.polyfrost.oneconfig.annotations; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Retention(RetentionPolicy.RUNTIME) +@Target(ElementType.FIELD) +public @interface Selector { + String name(); + String description() default ""; + String[] options(); + int defaultSelection() default 0; +} diff --git a/src/main/java/io/polyfrost/oneconfig/annotations/Slider.java b/src/main/java/io/polyfrost/oneconfig/annotations/Slider.java new file mode 100644 index 0000000..990c70b --- /dev/null +++ b/src/main/java/io/polyfrost/oneconfig/annotations/Slider.java @@ -0,0 +1,15 @@ +package io.polyfrost.oneconfig.annotations; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Retention(RetentionPolicy.RUNTIME) +@Target(ElementType.FIELD) +public @interface Slider { + String name(); + String description() default ""; + int min(); + int max(); +} diff --git a/src/main/java/io/polyfrost/oneconfig/annotations/Switch.java b/src/main/java/io/polyfrost/oneconfig/annotations/Switch.java new file mode 100644 index 0000000..fffb490 --- /dev/null +++ b/src/main/java/io/polyfrost/oneconfig/annotations/Switch.java @@ -0,0 +1,13 @@ +package io.polyfrost.oneconfig.annotations; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Retention(RetentionPolicy.RUNTIME) +@Target(ElementType.FIELD) +public @interface Switch { + String name(); + String description() default ""; +} diff --git a/src/main/java/io/polyfrost/oneconfig/annotations/TextField.java b/src/main/java/io/polyfrost/oneconfig/annotations/TextField.java new file mode 100644 index 0000000..5761dd6 --- /dev/null +++ b/src/main/java/io/polyfrost/oneconfig/annotations/TextField.java @@ -0,0 +1,15 @@ +package io.polyfrost.oneconfig.annotations; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Retention(RetentionPolicy.RUNTIME) +@Target(ElementType.FIELD) +public @interface TextField { + String name(); + String description() default ""; + String placeholder() default ""; + boolean hideText() default false; +} |