XML / JSON VALIDATOR IN YII2

Hi,

Is there any extension for XML/JSON Validator in Yii2. Or How to validate the XML/JSON file. Please assist me.