3 ms·
> You can roll your own - if there is no code you do not control that takes a string. You can roll your own for the standard String too, through the bootstrap
by the8472 11y ago
> You can roll your own - if there is no code you do not control that takes a string.
You can roll your own for the standard String too, through the bootstrap class loader.
Although I don't know how many assumptions about the internals of the string class are baked into the JVM. But I think you could replace substring() relatively safely.