Updated Swift example for Beta 3