What happened here is that the torque rod let go. This is the arm that connects the brake plate to the swingarm to transfer braking torque to the frame. When it released, the brake plate rotated from brake torque, in the process putting the brake on stronger and stronger since the brake actuating rod tightens as the plate rotates. With the brake locked up and the wheel torque pulling on the brake actuating rod, the brake cam snapped. It may actually be designed to do that to avoid a locked rear wheel situation at speed, usually that's followed by a crash.
The brake torque rod is held at the ends by a stud on the brake plate and a bolt on the swingarm. Both have locking devices, and should not come loose ever. Did you install the locking devices when you installed the wheel? Did you use a non-stock bolt at the swingarm- that is a special fastener and a normal bolt is not acceptable.