Annotation Type Weight


  • @Documented
    @Target({METHOD,TYPE,CONSTRUCTOR})
    @Retention(CLASS)
    @Inherited
    public @interface Weight
    Allows to define computational weight of an entity, in fuzzy human-subjective relative units. Also it can mark interface methods as their desired weight. For instance it makes easier to understand should implementation process something in the same thread or in another thread.
    Since:
    1.0
    • Required Element Summary

      Required Elements 
      Modifier and Type Required Element Description
      Weight.Unit value
      Contains weight value for marked entity.
    • Optional Element Summary

      Optional Elements 
      Modifier and Type Optional Element Description
      java.lang.String comment
      May contain some description or comment.
    • Element Detail

      • value

        Weight.Unit value
        Contains weight value for marked entity.
        Returns:
        weight value for marked entity.
        Since:
        1.0
      • comment

        java.lang.String comment
        May contain some description or comment.
        Returns:
        comment or note as string
        Since:
        1.0
        Default:
        ""