Annotation Type Index


@Documented @Retention(RUNTIME) @Target(METHOD) public @interface Index
Allows using method arguments to call operator[] in some circumstances. For example, a call like (*this)[i].foo(str) could be accomplished with @Index native void foo(int i, String str).
See Also:
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    The name of a function to call instead of operator[], for example, "at".
    int
    The number of indices spread over the parameters, for multidimensional access.
  • Element Details

    • value

      int value
      The number of indices spread over the parameters, for multidimensional access.
      Default:
      1
    • function

      String function
      The name of a function to call instead of operator[], for example, "at".
      Default:
      ""