The Shimano MTB standard for the drawing in your post has an L dimension of 28-30mm from axle center to mounting hole center and an X dimension of 6-10mm offset from axle center. As Unterhausen said, there is no special length for a 42t cassette. That capability will be built into the rear derailleur.