is there an API in blackberry that can validate URL ?
i’m using stupid method
startsWith(http://)
and read the Index of the string to make sure it contain “.com/” and other strings to ensure it look like a validate URL.
but i feel like it’s a stupid and long way to use.
is there any API that can make it easier ?
I’m looking for away to make it within blackberry APIs not external packages
In the API the only classes are:
URLTextFilter: Useful only to add it to a text field (CallEditField.setFilter). It will discard invalid chars.URI: It lets you to validate a URI by callingURI.create. Of course, not all URIs are URLs, but URLs should be URIs.