Added the core for path pattern matching