There may be other ways to do it, but the ones that I have disassembled are all similar, comprising a guided plunger solenoid with several ramps embossed in the plunger flange and the housing, and bearing balls trapped in the ramps. When the plunger is drawn into the body, the gap between flange and body closes, and the ball ramps force the plunger and its shaft to rotate as they are traversing. The plunger motion is neither pure translation nor pure rotation.
I think Ledex is the original manufacturer, but copies have been made elsewhere for decades.