@staticmethod<EOL><INDENT>def _is_valid_templates_dict(policy_templates_dict, schema=None):<DEDENT>
if not schema:<EOL><INDENT>schema = PolicyTemplatesProcessor._read_schema()<EOL><DEDENT>try:<EOL><INDENT>jsonschema.validate(policy_templates_dict, schema)<EOL><DEDENT>except ValidationError as ex:<EOL><INDENT>raise ValueError(str(ex))<EOL><DEDENT>return True<EOL>
Is this a valid policy template dictionary

:param dict policy_templates_dict: Data to be validated
:param dict schema: Optional, dictionary containing JSON Schema representing policy template
:return: True, if it is valid.
:raises ValueError: If the template dictionary doesn't match up with the schema