I'm working with some data that is best stored as arrays, and I often have to work with sub-arrays and ranges. What I would like is something like this:
int[] src = new int[] {0, 1, 2, 3}
int[] sub = src+2;
'sub' would then not be a deep copy, but rather a reference to a specific offset into the 'src' array. Edit: Array safety, such as overflows, could be checked by the original array in this instance.
While this specific utility would be trivial for me to write, are there already standard solutions or third-party libraries that provide this functionality? I don't want to recreate the wheel and, if there are other such classes available, I'd rather build on their work (as they might provide much more functionality that I didn't even think I needed).