urlToCat static method
Implementation
static String urlToCat(String url) {
String result = "";
Iterable<RegExpMatch> matches = new RegExp(r"[a-z\-]")
.allMatches(new RegExp(r"\/[a-z\-]+\/-?[0-9]+\/$").stringMatch(url)!);
for (Match m in matches) {
result += m.group(0)!;
}
return result;
}