How to get a sub array of array in Java, without copying data?

前端 未结 9 1904
执念已碎
执念已碎 2020-12-28 11:58

I have some library of classes, working with my data, which is being read into buffer. Is it possible somehow to avoid copying arrays again and again, passing parts of data

9条回答
  •  不知归路
    2020-12-28 12:35

    Google's Guava libraries support the slice concept in the form of a ByteSource.

    Google Guava is a readily available open-source package of functionality, written from the ground up to follow Google best practices, which depend on significant array slicing capabilities.

提交回复
热议问题