Interface AnnotationUsage

    • Method Detail

      • put

        AnnotationUsage put​(String key,
                            Value<?> val)
        Use the specified key-value pair when referencing the annotation. If you only want to show a single value without any key, consider using the HasValue.set(Value) method.
        Parameters:
        key - the key
        val - the value
        Returns:
        a reference to this model
      • put

        default AnnotationUsage put​(String key,
                                    String textValue)
        Use the specified key-value pair when referencing the annotation. If you only want to show a single value without any key, consider using the HasValue.set(Value) method.

        This method works like put(String, Value) except that the type of the value is automatically determined as a TextValue.

        Parameters:
        key - the key
        textValue - the value
        Returns:
        a reference to this model
        Since:
        2.5
      • put

        default AnnotationUsage put​(String key,
                                    Number numberValue)
        Use the specified key-value pair when referencing the annotation. If you only want to show a single value without any key, consider using the HasValue.set(Value) method.

        This method works like put(String, Value) except that the type of the value is automatically determined as a NumberValue.

        Parameters:
        key - the key
        numberValue - the value
        Returns:
        a reference to this model
        Since:
        2.5
      • getValues

        List<Map.Entry<String,​Value<?>>> getValues()
        Returns a list of all the key-value pairs in this model.
        Returns:
        all key-value pairs
      • of

        static AnnotationUsage of​(Type type)
        Creates a new instance implementing this interface by using the default implementation.
        Parameters:
        type - the type
        Returns:
        the new instance