diff --git a/api/src/main/java/jakarta/config/ConfigDefault.java b/api/src/main/java/jakarta/config/ConfigDefault.java deleted file mode 100644 index f694305..0000000 --- a/api/src/main/java/jakarta/config/ConfigDefault.java +++ /dev/null @@ -1,22 +0,0 @@ -package jakarta.config; - -import java.lang.annotation.Documented; -import java.lang.annotation.ElementType; -import java.lang.annotation.Retention; -import java.lang.annotation.RetentionPolicy; -import java.lang.annotation.Target; - -/** - * Specify the default value of a configuration member. - */ -@Documented -@Retention(RetentionPolicy.RUNTIME) -@Target({ ElementType.METHOD }) -public @interface ConfigDefault { - /** - * The default value of the member. - * - * @return the default value as a string - */ - String value(); -} diff --git a/api/src/main/java/jakarta/config/ConfigMapping.java b/api/src/main/java/jakarta/config/ConfigMapping.java index 2befebc..23e844e 100644 --- a/api/src/main/java/jakarta/config/ConfigMapping.java +++ b/api/src/main/java/jakarta/config/ConfigMapping.java @@ -55,4 +55,34 @@ * @return a {@link String} representation of a configuration path. */ String path() default ""; + + /** + * Override the configuration member name. + */ + @Documented + @Retention(RetentionPolicy.RUNTIME) + @Target({ElementType.METHOD }) + @interface Name { + /** + * The name of the configuration member name. Must not be empty. + * + * @return the configuration member name + */ + String value(); + } + + /** + * Specify the default value of a configuration member. + */ + @Documented + @Retention(RetentionPolicy.RUNTIME) + @Target({ ElementType.METHOD }) + @interface Default { + /** + * The default value of the member. + * + * @return the default value as a string + */ + String value(); + } } diff --git a/api/src/main/java/jakarta/config/ConfigName.java b/api/src/main/java/jakarta/config/ConfigName.java deleted file mode 100644 index 04b7c39..0000000 --- a/api/src/main/java/jakarta/config/ConfigName.java +++ /dev/null @@ -1,22 +0,0 @@ -package jakarta.config; - -import java.lang.annotation.Documented; -import java.lang.annotation.ElementType; -import java.lang.annotation.Retention; -import java.lang.annotation.RetentionPolicy; -import java.lang.annotation.Target; - -/** - * Override the configuration member name. - */ -@Documented -@Retention(RetentionPolicy.RUNTIME) -@Target({ElementType.METHOD }) -public @interface ConfigName { - /** - * The name of the configuration member name. Must not be empty. - * - * @return the configuration member name - */ - String value(); -}