It looks like the NCAA rules (which we use for NY high schools) are a little different here:
Section 4. Throw-in
Art. 1. The thrower-in shall not:
b. Fail to pass the ball directly into the playing court so that after it
crosses the boundary line, it touches or is touched by another
player (inbounds or out of bounds) on the playing court before
going out of bounds. A throw-in that lodges between the backboard
and the ring or comes to rest on the flange shall be a violation.
Art. 3. The opponents of the thrower-in shall not have any part of their person
beyond the vertical inside plane of any boundary line before the ball
has crossed that boundary line.
(I've deleted all the parts that don't seem to apply to this case.) From this, I conclude that if either A (based on 9.4.1b) or B (based on 9.4.3) touches the ball before it crosses the boundary line into the court, it's a violation.