hamas fighters are not "soldiers", they are considered "militants" or "terrorists", thus, no need for them to follow the law. Israeli military on the other hand is part of a democratic state that should set an example on how NOT act like a group of terrorists. something the IDF has failed to do, which explains the accusations of human rights abuses and war crimes.
More than 2,000 migrants threaten to break out of Hungarian camp (Reuters)
from the article: IDF soldier charged with killing woman during Gaza war