I managed to find a private INT called stare timer, But so far the only references to it I can see is what to do with it if it reaches certain values. I'm more interested in hat actually sets the values for this integer. What code means
If a player is staring at the Entity add a point to that int every tick.
If you look just a little above where the stare timer increments, you can see it only increments if the Endermen 'shouldAttackPlayer' is true. Look at that method implementation and you should have your answer (it does some fancy math to see if the player and endermen are looking at each other's eyes).