<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">How can you switch a dictionary?<br class=""><div class="">
<div style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class=""><br class="Apple-interchange-newline">Regards,</div><div style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">Adrian Kashivskyy</div><div style="color: rgb(0, 0, 0); font-family: Helvetica; font-size: 12px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px;" class="">Senior iOS Developer at Netguru</div>
</div>

<br class=""><div><blockquote type="cite" class=""><div class="">Wiadomość napisana przez James Campbell via swift-evolution &lt;<a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a>&gt; w dniu 08.02.2016, o godz. 12:01:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">In Swift 2.1 its possible to do the following:<div class=""><br class=""></div><div class=""><p class=""><span class="">if</span><span class=""> </span><span class="">let</span><span class=""> </span><span class="">_</span><span class=""> = userInfo[</span><span class="">"msgIdenitifer"</span><span class="">] </span><span class="">where</span><span class=""> application.</span><span class="">applicationState</span><span class=""> == .</span><span class="">Active</span><span class=""> {</span></p><p class="">//Do something</p><p class=""><span class="">&nbsp;}</span></p><p class=""><span class=""><br class=""></span></p><p class=""><span class="">But not:</span></p><p class=""><span class=""><br class=""></span></p><p class=""><span class="">switch(userInfo)</span></p><p class=""><span class="">{</span></p><p class=""><span class="">case&nbsp;</span><span class="">let</span><span class=""> </span><span class="">_</span><span class=""> = userInfo[</span><span class="">"msgIdenitifer"</span><span class="">] </span><span class="">where</span><span class=""> application.</span><span class="">applicationState</span><span class=""> == .</span><span class="">Active:</span></p><p class=""><span class="">//do something</span></p><p class=""><span class="">break</span></p><p class=""><span class="">}</span></p><div class=""><div class="gmail_signature"><div dir="ltr" class=""><div class=""><div dir="ltr" class=""><p class=""><b class=""><font color="#cc0000" class="">___________________________________</font></b></p><p class=""><b class="">James⎥Lead Engineer</b></p><p class=""><b class=""><font color="#cc0000" class=""><a href="mailto:james@supmenow.com" target="_blank" class="">james@supmenow.com</a>⎥<a href="http://supmenow.com/" target="_blank" class="">supmenow.com</a></font></b></p><p class=""><b class=""><font size="2" class="">Sup</font></b></p><p class=""><b class=""><font size="2" class="">Runway East
</font></b></p><p class=""><b class=""><font size="2" class="">10 Finsbury Square</font></b></p><p class=""><b class=""><font size="2" class="">London</font></b></p><p class=""><b class=""><font size="2" class="">
EC2A 1AF&nbsp;</font></b></p></div></div></div></div></div>
</div></div>
_______________________________________________<br class="">swift-evolution mailing list<br class=""><a href="mailto:swift-evolution@swift.org" class="">swift-evolution@swift.org</a><br class="">https://lists.swift.org/mailman/listinfo/swift-evolution<br class=""></div></blockquote></div><br class=""></body></html>