<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Introducing the Swiz [URLMapping] Metadata Processor</title>
	<atom:link href="http://www.ryancampbell.com/2010/03/26/introducing-the-swiz-urlmapping-metadata-processor/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.ryancampbell.com/2010/03/26/introducing-the-swiz-urlmapping-metadata-processor/</link>
	<description>Flex/Flash Developer Blog</description>
	<lastBuildDate>Tue, 22 Feb 2011 20:14:03 -0800</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1.1</generator>
	<item>
		<title>By: João Saleiro</title>
		<link>http://www.ryancampbell.com/2010/03/26/introducing-the-swiz-urlmapping-metadata-processor/comment-page-1/#comment-5083</link>
		<dc:creator>João Saleiro</dc:creator>
		<pubDate>Fri, 18 Feb 2011 11:24:41 +0000</pubDate>
		<guid isPermaLink="false">http://www.ryancampbell.com/?p=53#comment-5083</guid>
		<description>Ryan,

URLMapping is excellent, and simplifies most of the use cases.
There is one use case where using the URLMapping tag can be a bit tricky.

Imagine you have a business method that you are sure that is only called internally by your application if a certain condition is applied (example: the user is logged in). 
You want that the call to that method (via [EventHandler]) changes the URL, but you don&#039;t want the reverse: if the user fills up the url, you want the method to be only called if a condition applies (i.e. The user is Logged In). 

For solving this case, I would recommend adding a new argument to URLMapping: &quot;direction = [fromBrowser; toBrowser; both]&quot;. It would indicate if that tag 1- Listens ONLY to URL changes calling the method; 2- Updates ONLY the URL 3- Does both things. This way, the following would be possible:

[EventHandler(&quot;BusinessEvent.DO_OPERATION&quot;)]
[URLMapping(&quot;/myOperation&quot;, direction=&quot;toBrowser&quot;)
public function doBusinessOperation():void {  }

[URLMapping(&quot;/myOperation&quot;, direction=&quot;fromBrowser&quot;)
public function tryToDoBusinessOperation():void 
{  
     if (condition) dispatchEvent(new BusinessEvent(BusinessEvent.DO_OPERATION))
}


Want we could use URLMapping like before, by using the direction=&quot;both&quot;, which would be default argument.

What do you think? :)</description>
		<content:encoded><![CDATA[<p>Ryan,</p>
<p>URLMapping is excellent, and simplifies most of the use cases.<br />
There is one use case where using the URLMapping tag can be a bit tricky.</p>
<p>Imagine you have a business method that you are sure that is only called internally by your application if a certain condition is applied (example: the user is logged in).<br />
You want that the call to that method (via [EventHandler]) changes the URL, but you don&#8217;t want the reverse: if the user fills up the url, you want the method to be only called if a condition applies (i.e. The user is Logged In). </p>
<p>For solving this case, I would recommend adding a new argument to URLMapping: &#8220;direction = [fromBrowser; toBrowser; both]&#8220;. It would indicate if that tag 1- Listens ONLY to URL changes calling the method; 2- Updates ONLY the URL 3- Does both things. This way, the following would be possible:</p>
<p>[EventHandler("BusinessEvent.DO_OPERATION")]<br />
[URLMapping(&#8220;/myOperation&#8221;, direction=&#8221;toBrowser&#8221;)<br />
public function doBusinessOperation():void {  }</p>
<p>[URLMapping(&#8220;/myOperation&#8221;, direction=&#8221;fromBrowser&#8221;)<br />
public function tryToDoBusinessOperation():void<br />
{<br />
     if (condition) dispatchEvent(new BusinessEvent(BusinessEvent.DO_OPERATION))<br />
}</p>
<p>Want we could use URLMapping like before, by using the direction=&#8221;both&#8221;, which would be default argument.</p>
<p>What do you think? <img src='http://www.ryancampbell.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Thomas Burleson</title>
		<link>http://www.ryancampbell.com/2010/03/26/introducing-the-swiz-urlmapping-metadata-processor/comment-page-1/#comment-2737</link>
		<dc:creator>Thomas Burleson</dc:creator>
		<pubDate>Fri, 14 May 2010 18:46:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.ryancampbell.com/?p=53#comment-2737</guid>
		<description>After manually dealing with DeepLinks on several projects, this is really excellent. What a useful processor! 

Thank you,
THomasB</description>
		<content:encoded><![CDATA[<p>After manually dealing with DeepLinks on several projects, this is really excellent. What a useful processor! </p>
<p>Thank you,<br />
THomasB</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Derrick Grigg</title>
		<link>http://www.ryancampbell.com/2010/03/26/introducing-the-swiz-urlmapping-metadata-processor/comment-page-1/#comment-2391</link>
		<dc:creator>Derrick Grigg</dc:creator>
		<pubDate>Mon, 29 Mar 2010 18:56:57 +0000</pubDate>
		<guid isPermaLink="false">http://www.ryancampbell.com/?p=53#comment-2391</guid>
		<description>Nice work Ryan, I have used Swiz for some projects (pre version 1) but have been using Robotlegs lately. With metadata tags like [urlmapping] added to the mix Swiz is certainly on my radar for upcoming projects.</description>
		<content:encoded><![CDATA[<p>Nice work Ryan, I have used Swiz for some projects (pre version 1) but have been using Robotlegs lately. With metadata tags like [urlmapping] added to the mix Swiz is certainly on my radar for upcoming projects.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ryan Campbell</title>
		<link>http://www.ryancampbell.com/2010/03/26/introducing-the-swiz-urlmapping-metadata-processor/comment-page-1/#comment-2389</link>
		<dc:creator>Ryan Campbell</dc:creator>
		<pubDate>Mon, 29 Mar 2010 12:54:59 +0000</pubDate>
		<guid isPermaLink="false">http://www.ryancampbell.com/?p=53#comment-2389</guid>
		<description>Mico: Yeah, I&#039;ve been using Swiz on all my projects lately. It&#039;s a great framework that is definitely suitable for large-scale Flex applications.</description>
		<content:encoded><![CDATA[<p>Mico: Yeah, I&#8217;ve been using Swiz on all my projects lately. It&#8217;s a great framework that is definitely suitable for large-scale Flex applications.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: mico</title>
		<link>http://www.ryancampbell.com/2010/03/26/introducing-the-swiz-urlmapping-metadata-processor/comment-page-1/#comment-2387</link>
		<dc:creator>mico</dc:creator>
		<pubDate>Mon, 29 Mar 2010 09:23:26 +0000</pubDate>
		<guid isPermaLink="false">http://www.ryancampbell.com/?p=53#comment-2387</guid>
		<description>Ryan, what do you think about Swiz in general ? Is this a good platform for building a large-scale Flex applications ? Or it is suitable for small to medium sized better? Currently, I&#039;m using PureMVC and it works well for large apps.</description>
		<content:encoded><![CDATA[<p>Ryan, what do you think about Swiz in general ? Is this a good platform for building a large-scale Flex applications ? Or it is suitable for small to medium sized better? Currently, I&#8217;m using PureMVC and it works well for large apps.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: E Brent Nelson</title>
		<link>http://www.ryancampbell.com/2010/03/26/introducing-the-swiz-urlmapping-metadata-processor/comment-page-1/#comment-2377</link>
		<dc:creator>E Brent Nelson</dc:creator>
		<pubDate>Sat, 27 Mar 2010 14:52:11 +0000</pubDate>
		<guid isPermaLink="false">http://www.ryancampbell.com/?p=53#comment-2377</guid>
		<description>AWESOME!!! Can&#039;t wait to use this!</description>
		<content:encoded><![CDATA[<p>AWESOME!!! Can&#8217;t wait to use this!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Marvin Froeder</title>
		<link>http://www.ryancampbell.com/2010/03/26/introducing-the-swiz-urlmapping-metadata-processor/comment-page-1/#comment-2374</link>
		<dc:creator>Marvin Froeder</dc:creator>
		<pubDate>Sat, 27 Mar 2010 03:11:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.ryancampbell.com/?p=53#comment-2374</guid>
		<description>Fan-tas-tic!!!

VELO</description>
		<content:encoded><![CDATA[<p>Fan-tas-tic!!!</p>
<p>VELO</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: codeculture</title>
		<link>http://www.ryancampbell.com/2010/03/26/introducing-the-swiz-urlmapping-metadata-processor/comment-page-1/#comment-2370</link>
		<dc:creator>codeculture</dc:creator>
		<pubDate>Fri, 26 Mar 2010 19:50:58 +0000</pubDate>
		<guid isPermaLink="false">http://www.ryancampbell.com/?p=53#comment-2370</guid>
		<description>That&#039;s a great one. I don&#039;t want to start the &#039;which framework is the right one&#039;-discussion here, but I&#039;m still thinking about which one fits my needs best: swiz or robotlegs. The &#039;processor thing&#039; is a point for swiz.</description>
		<content:encoded><![CDATA[<p>That&#8217;s a great one. I don&#8217;t want to start the &#8216;which framework is the right one&#8217;-discussion here, but I&#8217;m still thinking about which one fits my needs best: swiz or robotlegs. The &#8216;processor thing&#8217; is a point for swiz.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John C. Bland II</title>
		<link>http://www.ryancampbell.com/2010/03/26/introducing-the-swiz-urlmapping-metadata-processor/comment-page-1/#comment-2369</link>
		<dc:creator>John C. Bland II</dc:creator>
		<pubDate>Fri, 26 Mar 2010 18:31:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.ryancampbell.com/?p=53#comment-2369</guid>
		<description>Looks sweet dude! Great work.</description>
		<content:encoded><![CDATA[<p>Looks sweet dude! Great work.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

