<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>nothing yet &#124; jason madsen &#187; ASDoc</title>
	<atom:link href="http://knomedia.com/blog/tag/asdoc/feed/" rel="self" type="application/rss+xml" />
	<link>http://knomedia.com/blog</link>
	<description>ActionScript, Flex, Flash thoughts</description>
	<lastBuildDate>Thu, 22 Dec 2011 16:02:51 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
		<item>
		<title>Creating ASDocs in Flash Builder</title>
		<link>http://knomedia.com/blog/2009/11/05/creating-asdocs-in-flash-builder/</link>
		<comments>http://knomedia.com/blog/2009/11/05/creating-asdocs-in-flash-builder/#comments</comments>
		<pubDate>Fri, 06 Nov 2009 01:23:44 +0000</pubDate>
		<dc:creator>jason</dc:creator>
				<category><![CDATA[All]]></category>
		<category><![CDATA[ASDoc]]></category>
		<category><![CDATA[Flex]]></category>

		<guid isPermaLink="false">http://knomedia.com/blog/?p=317</guid>
		<description><![CDATA[How to generate ASDocs using Flash Builder's External Tools Dialogue]]></description>
			<content:encoded><![CDATA[<p>Over the last year or two I have seen several different methodologies on creating ActionScript documentation using ASDoc.  Jesse Freeman shows a quick example of creating documentation using ANT tasks in his recent article <a href="http://www.insideria.com/2009/11/5-tips-for-documenting-code.html">5 Tips for Documenting Code</a> .  ANT tasks are nice in that they can be transfered with the code base as it moves from developer to developer.  When I need to quickly create ASDocs however, I typically use the External Tools dialogue directly in Flash Builder.</p>
<p>I thought I would document how to create a simple ASDoc configuration within Flash Builder&#8217;s External Tools dialogue.</p>
<p><strong>External Tools</strong></p>
<p>In Flash Builder, select Run &#8211;> External Tools &#8211;> External Tools Configurations</p>
<p><a href="http://knomedia.com/blog/wp-content/uploads/2009/11/1_ExternalTools1.png"><img src="http://knomedia.com/blog/wp-content/uploads/2009/11/1_ExternalTools1-300x225.png" alt="External Tools" title="External Tools" width="300" height="225" class="aligncenter size-medium wp-image-329" /></a></p>
<p>Create a new configuration by double clicking on the “Programs” button.  Next, give the new configuration a name, I’ll choose something generic like “Generic ASDoc”.  </p>
<p><strong>Location</strong></p>
<p>The External Tools Configurations window needs a bit of information.  The first is “Location”.  Select the “Browse File System” button and locate the the asdoc compiler.</p>
<p>On a Mac it is typically located at:</p>
<p><code>/Applications/Adobe Flash Builder Beta 2/sdks/4.0.0/bin/aasdoc</code></p>
<p>On windows (XP) I believe it is located at:</p>
<p><code>C:\Program Files\Adobe\Flex Builder 3\sdks\3.2.0\bin\asdoc.exe</code></p>
<p>I don’t have a PC to test this with currently, so if I am wrong, please feel free to correct me.</p>
<p><strong>Working Directory</strong></p>
<p>Next we need to add our “Working Directory”.  You can think of this as your base directory, the directory from which any relative paths will be resolved.  For this field I typically want it to be my “src” folder within the project I am working on.  Eclipse has some interesting variables that can help here.  You can see them by clicking the “Variables” button.  I usually end up with my working directory set as &#8220;The currently selected project&#8217;s &#8216;src&#8217; directory&#8221; like so:</p>
<p><code>${project_loc}/src</code></p>
<p><strong>ASDoc Arguments</strong></p>
<p>Lastly we need to add the necessary compiler arguments for ASDoc.  I’ll document the basic arguments here, and then point you toward a more in depth resource created by Adobe that discusses all of the arguments.</p>
<p><code>-source-path</code><br />
In this example I will set this to a period (.), meaning the same directory as the &#8220;Working Directory&#8221; from the previous step.</p>
<p><code>-doc-sources</code><br />
Again here I will set this to a period (.), meaning document all of the classes found within the source path (which in this case is our ‘src’ folder)</p>
<p><code>-output</code><br />
This is the directory in which ASDoc will build the documentation.  If the directory doesn&#8217;t exist, ASDoc will create it for you.  You could also use a relative path (relative from the Working Directory).  I’m setting it to DOCS, meaning that it will create a directory named “DOCS” within the “src” directory.</p>
<p><a href="http://knomedia.com/blog/wp-content/uploads/2009/11/BasicSetting.png"><img src="http://knomedia.com/blog/wp-content/uploads/2009/11/BasicSetting-292x300.png" alt="Basic Settings" title="Basic Settings" width="292" height="300" class="size-medium wp-image-333" /></a></p>
<p><strong>Other compiler arguments you can use</strong></p>
<p>For simple projects the previously named compiler arguments should get you started.  There are several other arguments you may need.  I’ll list a few of them here</p>
<p><code>-window-title</code><br />
This argument takes a String, be sure to enclose your value within double quotes if it will contain spaces.  The -window-title argument gets concatenated to the HTML title tag.</p>
<p><code>-main-title</code><br />
This argument also takes a String (use double quotes for spaces).  This argument value gets placed at the top of the documentation HTML</p>
<p><code>-library-path</code><br />
A relative path to any SWC file dependancies.  For example if you have a SWC file being used in the build path of your project found within the “libs” directory you would add “../libs” as the argument.</p>
<p><code>-exclude-classes</code><br />
The fully qualified name of any class file that you do no wish to have included in the documentation</p>
<p><strong>Running your configuration</strong></p>
<p>When you have your configuration set up, select &#8220;Apply&#8221;, and then &#8220;Run&#8221;.  You should see some feedback on the documentation process in Flash Builder&#8217;s console.  From now on, you should see the name of the configuration when you select Run&#8211;>External Tools.  Selecting the configuration will run it.  You can also run the configuration from the toolbar icon as well.</p>
<p><strong>More Info</strong></p>
<p>For more information you should check out <a href="http://blogs.adobe.com/flexdoc/pdfs/asdoc.pdf">this</a> document created by Adobe that discusses options for using ASDoc including both compiler arguments and options for commenting your code.</p>
]]></content:encoded>
			<wfw:commentRss>http://knomedia.com/blog/2009/11/05/creating-asdocs-in-flash-builder/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
	</channel>
</rss>

