I have a string that "may" be longer than any simple int boundaries.
Currently, the string.substring function takes only int parameters as index and length which is not enough for me since i need long for the parameter value types.
Do you know any implementation of long substring function?
Or what do you recommend I do to solve this possible finding substring problem with very long string?
Thank you.
I have a string that "may" be longer than any simple int boundaries.
No, in .NET you won't have that problem. The System.String
class itself uses Int32
indexing and Length properties everywhere.
Maybe you will have a (char) array that's over 2GB but that is taken care of, you can use 'long` indexing.
Related question: What is the maximum possible length of a .NET string?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With