Мой шаблон NSString не работает.
NSString *pattern = @"/api/v1/news/([0-9]+)/\\?categoryId=([0-9]+)";
NSString *string = urlString;
NSRegularExpression *regex = [NSRegularExpression
regularExpressionWithPattern:pattern
options:NSRegularExpressionCaseInsensitive
error:nil];
Почему он соответствует и следующей строке?
/api/v1/news/123/?categoryId=22abc
Я хочу соответствовать только
/api/v1/news/123/?categoryId=22
где 123 и 22 могут быть переменными числами.
NSTextCheckingResult
. - person zaph   schedule 30.09.2015