I have an UISearchBar
, and I want my data to be sorted by pinYin if the user inputs English, and sorted by the characters themselves when the user inputs Chinese characters.
Is there something like
if (searchText isKindofClass: UTF-8String)
to detect if an NSString
contains Chinese characters?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…