Interface IntArrayBinaryTag

    • Method Detail

      • of

        @NotNull
        static @NotNull IntArrayBinaryTag of​(int @NotNull ... value)
        Creates a binary tag holding an int-array value.
        Parameters:
        value - the value
        Returns:
        a binary tag
        Since:
        4.0.0
      • value

        int @NotNull [] value()
        Gets the value.

        The returned array is a copy.

        Returns:
        the value
        Since:
        4.0.0
      • size

        int size()
        Get the length of the array.
        Returns:
        value size
        Since:
        4.2.0
      • get

        int get​(int index)
        Gets the value at index in this tag.
        Parameters:
        index - the index in the array
        Returns:
        the int at the index in the array
        Throws:
        IndexOutOfBoundsException - if idx < 0 or ≥ size()
        Since:
        4.2.0
      • stream

        @NotNull
        @NotNull IntStream stream()
        Create a stream whose elements are the elements of this array tag.
        Returns:
        a new stream
        Since:
        4.2.0
      • forEachInt

        void forEachInt​(@NotNull
                        @NotNull IntConsumer action)
        Perform an action for every int in the backing array.
        Parameters:
        action - the action to perform
        Since:
        4.2.0