Added support for parent matching