Annotation Type Property


  • @Retention(RUNTIME)
    @Documented
    @Repeatable(PropertySource.class)
    public @interface Property
    A property that can be contained within a PropertySource or used generally throughout the system.
    Since:
    1.0
    • Required Element Summary

      Required Elements 
      Modifier and Type Required Element Description
      java.lang.String name
      The name of the property in kebab case.
    • Optional Element Summary

      Optional Elements 
      Modifier and Type Optional Element Description
      java.lang.String defaultValue  
      java.lang.String value  
    • Element Detail

      • name

        java.lang.String name
        The name of the property in kebab case. Example: my-app.bar.
        Returns:
        The name of the property
      • value

        java.lang.String value
        Returns:
        The value of the property
        Default:
        ""
      • defaultValue

        @AliasFor(annotation=io.micronaut.core.bind.annotation.Bindable.class,
                  member="defaultValue")
        java.lang.String defaultValue
        Returns:
        The default value if none is specified
        Default:
        ""