user940016 user940016 - 2 years ago 110
Android Question

Android TextUtils

I can see that the TextUtils class has many functions that are identical in their purpose to functions found in the standard Java String class, such as indexOf. I'm wondering if they are aimed to just add more options to the developer, without any relation to the Android environment, such as calling indexOf on a CharSequence and not only on a String, or if they are supposed to actually replace the original functions due to issues they have when being used on Android.
Can someone please answer this informative question?

Answer Source

I think that TextUtils is just a collection of useful methods and are not meant to replace methods from string class, just some methods from string and other methods which make your code smaller (see TextUtils.isEmpty() and TextUtils.concat())

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download