
com.github.fashionbrot.properties.annotation.MarsConfigurationProperties Maven / Gradle / Ivy
package com.github.fashionbrot.properties.annotation;
import org.springframework.stereotype.Component;
import java.lang.annotation.*;
/**
* @author fashionbrot
* @date 2021/07/28 22:45
*
* An annotation for mars configuration Properties for binding POJO as Properties Object.
*
*/
@Target({ElementType.TYPE})
@Retention(RetentionPolicy.RUNTIME)
@Documented
@Component
public @interface MarsConfigurationProperties {
/**
* mars fileName
*/
String fileName();
/**
* config prefix name
*
* @return default value is ""
*/
String prefix() default "";
/**
* It indicates the properties of current doBind bean is auto-refreshed when configuration is changed.
*
* @return default value is false
*/
boolean autoRefreshed() default false;
/**
* 是否自动增加嵌套路径,默认值:true
* @return the flag value (default false)
*/
boolean autoGrowNestedPaths() default true;
/**
* Flag to indicate that when binding to this object invalid fields should be ignored.
* Invalid means invalid according to the binder that is used, and usually this means
* fields of the wrong type (or that cannot be coerced into the correct type).
* @return the flag value (default false)
*/
boolean ignoreInvalidFields() default false;
/**
* Flag to indicate that when binding to this object unknown fields should be ignored.
* An unknown field could be a sign of a mistake in the Properties.
* @return the flag value (default true)
*/
boolean ignoreUnknownFields() default true;
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy