I think Magsafe would be a good idea. As someone mentioned, you don't need to have the magnets on the iPhone itself so no worries about your phone collecting "junk". But here's a few other things to consider:
- The exposed pins on the iPhone would just be flush mounted flat contacts. There's no need for anything to stick out - the contacts on the connector end would have the actual "pins".
- Pins can have more than one function. There's no rule anywhere that says you need a 1:1 relationship between pins and features.
- A Hall effect sensor in the iPhone. When it detects the magnets in the Magsafe, all the pins become enabled. This way the exposed pins will never have any power or signals on them when the Magsafe isn't atached.
- A pattern recognition Magsafe. With multiple Hall sensors and magnets in different orientations the iPhone could recognize which adaptor is connected and configure the pins appropriately. So your USB cable would work differently than a video cable.
- Heck, why even bother with pattern recognition? It should be easy to scan the pins to see if there's any signals (like USB data) and configure accordingly.
- Electromagnets in the base of the iPhone. The Magsafe has a weak field that's just strong enough to attach the Magsafe, and when the iPhone realizes it's connected (and there's power available) the electromagnet comes on greatly increasing the strength of the field and keeping them held together firmly. Now this goes against the Magsafe idea of a cord coming off if you trip, but I'm thinking more of docks where you'd want you device firmly seated. You could have a 30 pin to Magsafe adaptor that you'd insert into your dock and it would allow you to easily keep using all your old accessories.
- One less way for water to get into the iPhone.
- Magsafe headphones? Why not? Easy to connect and yet another way to prevent water getting into your phone. To maintain compatibility, a small Magsafe to 1/8" adaptor would allow you to use other headphones.
It's really not that hard to come up with a bunch of things Apple may do, and I'm sure they've thought of these (and dozens more).