patterns.add(new PatternRulePair<UriRule>(
UriPattern.EMPTY, r));
}
// The terminating rule when the path is not fully consumed and accepted
patterns.add(new PatternRulePair<UriRule>(
new UriPattern(".*"), new TerminatingRule()));
// The terminating rule when the path is fully consumed and accepted
patterns.add(new PatternRulePair<UriRule>(
UriPattern.EMPTY, new TerminatingRule()));
// Create the sequential rules
final UriRules<UriRule> sequentialRules =
new SequentialMatchingPatterns<UriRule>(patterns);
// Combined the atomic and sequential rules, the former will be matched