The family of a Jordanian gunman who carried out a terrorist attack in Jerusalem this week has been told they cannot mourn his death in public.