The Hurewicz dichotomy for generalized Baire spaces