Locale-Sensitive Objective-C Method
Foundation NSString
NSString stringByAppendingString:
Internationalization (I18n) Method Overview
Click here
for additional Apple Developer Documentation details.
I18n Issues
This method is indicative of concatenation of fragment strings to construct a sentence or paragraph.
It's a step better than appending, but still wrong unless you are constructing a complete sentence or
equivalent.
Resolution: Construct a more comprehensive sentence level string including punctuation and incorporating
variables
to be substituted using one of the following: initWithFormat ,
initWithFormat:arguments ,
initWithFormat:locale , initWithFormat:locale:arguments ,
stringWithFormat ,
or localizedStringWithFormat .
Generally one needs to pass in locale , encoding or language to ensure
that any culture-dependent conversion is done properly.
If you determine that the call is i18n-safe, you can use Globalyzer's
Ignore Comment functionality to ensure that it isn't
picked up in a subsequent scan.
For information about Objective-C Internationalization, click here.
|