Added support for patternProperties.