Factorize code in PatternPropertiesSyntaxChecker

Other keywords have the same shape. Prevent code duplication.

Signed-off-by: Francis Galiegue <fgaliegue@gmail.com>