When you turn on the switch, it activates the electrical system for it. When it senses the rear wheels slip, it sends an electrical charge to the front gearcase and activates an electromagnet which engages the rollers in the roller cage which then engage the front axles. It's a pretty neat system.
That's the quick and simple version of how it works.
blueline15 does a killer write up on how it all works. I'm sure he'll chime in sooner or later.
Here's a link to the diagram for the front gearcase so you might be able to get an idea of what the parts look like and how they work.
Parts Dealer: Authorized Powersports Dealer in Muskegon, MI