Added static method check_mandatory_params to check mandatory params.