Tel Aviv is prepared to attack Syria if the government of Syrian President Bashar al-Assad collapses, An Israeli military commander has said.