The Israeli prime minister has said he doesn't see a path to a post-war plan for Gaza as long as Hamas is in control.