<?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>lejnieks &#187; ASDocs</title>
	<atom:link href="http://www.lejnieks.com/tag/asdocs/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.lejnieks.com</link>
	<description></description>
	<lastBuildDate>Fri, 29 Jan 2010 19:22:21 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<item>
		<title>Compile ASDocs with ANT</title>
		<link>http://www.lejnieks.com/2009/01/10/compile-asdocs-with-ant/</link>
		<comments>http://www.lejnieks.com/2009/01/10/compile-asdocs-with-ant/#comments</comments>
		<pubDate>Sun, 11 Jan 2009 05:24:07 +0000</pubDate>
		<dc:creator>klejnieks</dc:creator>
				<category><![CDATA[Ant]]></category>
		<category><![CDATA[Flex]]></category>
		<category><![CDATA[ASDocs]]></category>

		<guid isPermaLink="false">http://lejnieks.com/?p=62</guid>
		<description><![CDATA[Continuing on with ANT &#8211; Flex compilation, this sample script below will help you output ASDocs for your projects deliverable. Ant Script &#60;?xml version=&#34;1.0&#34; encoding=&#34;utf-8&#34;?&#62; &#60;project name=&#34;ASDocsTest&#34; default=&#34;compile&#34; basedir=&#34;.&#34;&#62; &#160; &#60;!-- import our build properties file --&#62; &#60;property file=&#34;./build.properties&#34; /&#62; &#160; &#160; &#60;!-- Flex Ant Tasks used to perform compc and mxml compiling more info [...]]]></description>
			<content:encoded><![CDATA[<p>Continuing on with ANT &#8211; Flex compilation, this sample script below will help you output ASDocs for your projects deliverable.</p>
<p><span id="more-62"></span></p>
<p><strong>Ant Script</strong></p>

<div class="wp_syntax"><div class="code"><pre class="xml" style="font-family:monospace;"><span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;?xml</span> <span style="color: #000066;">version</span>=<span style="color: #ff0000;">&quot;1.0&quot;</span> <span style="color: #000066;">encoding</span>=<span style="color: #ff0000;">&quot;utf-8&quot;</span><span style="color: #000000; font-weight: bold;">?&gt;</span></span>
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;project</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;ASDocsTest&quot;</span> <span style="color: #000066;">default</span>=<span style="color: #ff0000;">&quot;compile&quot;</span> <span style="color: #000066;">basedir</span>=<span style="color: #ff0000;">&quot;.&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
&nbsp;
	<span style="color: #808080; font-style: italic;">&lt;!--</span>
<span style="color: #808080; font-style: italic;">	import our build properties file</span>
<span style="color: #808080; font-style: italic;">	--&gt;</span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;property</span> <span style="color: #000066;">file</span>=<span style="color: #ff0000;">&quot;./build.properties&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span>
&nbsp;
&nbsp;
	<span style="color: #808080; font-style: italic;">&lt;!--</span>
<span style="color: #808080; font-style: italic;">	Flex Ant Tasks used to perform compc and mxml compiling more info at http://labs.adobe.com/wiki/index.php/Flex_Ant_Tasks</span>
<span style="color: #808080; font-style: italic;">	--&gt;</span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;taskdef</span> <span style="color: #000066;">resource</span>=<span style="color: #ff0000;">&quot;flexTasks.tasks&quot;</span> <span style="color: #000066;">classpath</span>=<span style="color: #ff0000;">&quot;${flexTasks.jar}&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span>
&nbsp;
&nbsp;
	<span style="color: #808080; font-style: italic;">&lt;!--</span>
<span style="color: #808080; font-style: italic;">	Execute the ASDoc Compile</span>
<span style="color: #808080; font-style: italic;">	--&gt;</span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;target</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;compile&quot;</span> <span style="color: #000066;">depends</span>=<span style="color: #ff0000;">&quot;generateASDocs&quot;</span> <span style="color: #000066;">description</span>=<span style="color: #ff0000;">&quot;series of tasks to create docs&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
&nbsp;
&nbsp;
	<span style="color: #808080; font-style: italic;">&lt;!--</span>
<span style="color: #808080; font-style: italic;">	DELETE the existing output folder and files and then re-generate the output folder</span>
<span style="color: #808080; font-style: italic;">	--&gt;</span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;target</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;cleanASDocsDir&quot;</span> <span style="color: #000066;">description</span>=<span style="color: #ff0000;">&quot;DELETE the existing output folder and files and then re-generate the output folder&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;delete</span> <span style="color: #000066;">dir</span>=<span style="color: #ff0000;">&quot;${asdocOutput.dir}&quot;</span> <span style="color: #000066;">failOnError</span>=<span style="color: #ff0000;">&quot;true&quot;</span> <span style="color: #000066;">includeEmptyDirs</span>=<span style="color: #ff0000;">&quot;true&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;mkdir</span> <span style="color: #000066;">dir</span>=<span style="color: #ff0000;">&quot;${asdocOutput.dir}&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;echo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>doc directory cleaned<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/echo<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/target<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
&nbsp;
&nbsp;
	<span style="color: #808080; font-style: italic;">&lt;!--</span>
<span style="color: #808080; font-style: italic;">	Run the ASDoc executable and generate the ASDocs to the new output folder</span>
<span style="color: #808080; font-style: italic;">	--&gt;</span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;target</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;generateASDocs&quot;</span> <span style="color: #000066;">depends</span>=<span style="color: #ff0000;">&quot;cleanASDocsDir, asDocsLog&quot;</span> <span style="color: #000066;">description</span>=<span style="color: #ff0000;">&quot;Run the ASDoc executable and generate the ASDocs to the new output folder&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;echo</span> <span style="color: #000066;">message</span>=<span style="color: #ff0000;">&quot;Generating ASDocs&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;exec</span> <span style="color: #000066;">executable</span>=<span style="color: #ff0000;">&quot;${asdoc.dir}&quot;</span> <span style="color: #000066;">failonerror</span>=<span style="color: #ff0000;">&quot;true&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
			<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;arg</span> <span style="color: #000066;">line</span>=<span style="color: #ff0000;">&quot;-doc-sources ${asdocClassPath}&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
			<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;arg</span> <span style="color: #000066;">line</span>=<span style="color: #ff0000;">&quot;-source-path '${srcpath.dir}'&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
			<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;arg</span> <span style="color: #000066;">line</span>=<span style="color: #ff0000;">&quot;-external-library-path '${externalLib.dir}'&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span>
			<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;arg</span> <span style="color: #000066;">line</span>=<span style="color: #ff0000;">&quot;-window-title '${asdocsTitle}'&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
			<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;arg</span> <span style="color: #000066;">line</span>=<span style="color: #ff0000;">&quot;-main-title '${asdocsTitle}'&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span>
			<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;arg</span> <span style="color: #000066;">line</span>=<span style="color: #ff0000;">&quot;-footer '${asdocsFooter}'&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span>
			<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;arg</span> <span style="color: #000066;">line</span>=<span style="color: #ff0000;">&quot;-output '${asdocOutput.dir}'&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/exec<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;echo</span> <span style="color: #000066;">message</span>=<span style="color: #ff0000;">&quot;ASDocs created successfully&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/target<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
&nbsp;
&nbsp;
	<span style="color: #808080; font-style: italic;">&lt;!--</span>
<span style="color: #808080; font-style: italic;">	LOG writes asdoc output to log file: log.txt</span>
<span style="color: #808080; font-style: italic;">	--&gt;</span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;target</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;asDocsLog&quot;</span><span style="color: #000000; font-weight: bold;">&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;echo</span> <span style="color: #000066;">message</span>=<span style="color: #ff0000;">&quot;start the asdoc generation log&quot;</span> <span style="color: #000000; font-weight: bold;">/&gt;</span></span>
		<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;record</span> <span style="color: #000066;">name</span>=<span style="color: #ff0000;">&quot;${asdocOutput.dir}/asdoc-log.txt&quot;</span> <span style="color: #000066;">action</span>=<span style="color: #ff0000;">&quot;start&quot;</span> <span style="color: #000066;">append</span>=<span style="color: #ff0000;">&quot;true&quot;</span><span style="color: #000000; font-weight: bold;">/&gt;</span></span>
	<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/target<span style="color: #000000; font-weight: bold;">&gt;</span></span></span>
&nbsp;
<span style="color: #009900;"><span style="color: #000000; font-weight: bold;">&lt;/project<span style="color: #000000; font-weight: bold;">&gt;</span></span></span></pre></div></div>

<p><strong>Build.properties</strong></p>

<div class="wp_syntax"><div class="code"><pre class="ini" style="font-family:monospace;"># Home directory for flex sdk <span style="">3</span>, change this to build for Mac or PC using # as comment
<span style="color: #000099;">FLEX_HOME</span> 		<span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">	sdks/flex-<span style="">3.2</span>-sdk</span>
flexTasks.jar		<span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">	tools/FlexTasks/lib/flexTasks.jar</span>
srcpath.dir      	<span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">	../src</span>
externalLib.dir  	<span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">	../libs</span>
&nbsp;
# ASDoc
asdoc.dir		<span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">	sdks/flex-<span style="">3.2</span>-sdk/bin/asdoc</span>
asdocOutput.dir  	<span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;">	../html_docs</span>
<span style="color: #000099;">asdocClassPath</span> 		<span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;"> 	$<span style="">&#123;</span>srcpath.dir<span style="">&#125;</span>/com</span>
<span style="color: #000099;">asdocsTitle</span> 		<span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;"> 	ASDocs Test Library</span>
<span style="color: #000099;">asdocsFooter</span> 		<span style="color: #000066; font-weight:bold;">=</span><span style="color: #660066;"> 	CONFIDENTIAL. Copyright <span style="">2009</span> My Company</span></pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://www.lejnieks.com/2009/01/10/compile-asdocs-with-ant/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
