Class ImmutableLongArray.Builder

    • Method Detail

      • addAll

        public <> values)
        Appends values, in order, to the end of the values the built ImmutableLongArray will contain.
      • addAll

        public <> values)
        Appends values, in order, to the end of the values the built ImmutableLongArray will contain.
      • addAll

        public  stream)
        Appends all values from stream, in order, to the end of the values the built ImmutableLongArray will contain.
      • build

        public ImmutableLongArray build()
        Returns a new immutable array. The builder can continue to be used after this call, to append more values and build again.

        Performance note: the returned array is backed by the same array as the builder, so no data is copied as part of this step, but this may occupy more memory than strictly necessary. To copy the data to a right-sized backing array, use .build().trimmed().