Of course it doesn't justify what China did (I wasn't making a "two wrongs make a right" argument) - but it might help explain the thought processes of the Chinese leadership in pulling a stunt like this - I would suspect that they are aware of US overflights over China.
Talk to a diplomat about "precedents". And to someone familiar with current politics in China about the policy of cultivating memories of past indignities, which were suffered at the hands of foreign powers.
If you're opening the can of European/Near Eastern History, the clear record of foreign power atrocities (vs. mere indignities) goes back quite a few millennia further than that.