<?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>FlexBandit &#187; Eclipse</title>
	<atom:link href="http://flexbandit.com/archives/tag/eclipse/feed" rel="self" type="application/rss+xml" />
	<link>http://flexbandit.com</link>
	<description>Yet another Flex enthusiast? You Betcha!</description>
	<lastBuildDate>Sun, 04 Dec 2011 15:34:22 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Eclipse/FlexBuilder Memory Settings</title>
		<link>http://flexbandit.com/archives/75</link>
		<comments>http://flexbandit.com/archives/75#comments</comments>
		<pubDate>Wed, 16 Sep 2009 13:09:28 +0000</pubDate>
		<dc:creator>donkeybandit</dc:creator>
				<category><![CDATA[Flex Gotchas]]></category>
		<category><![CDATA[Flex Info]]></category>
		<category><![CDATA[General]]></category>
		<category><![CDATA[Eclipse]]></category>

		<guid isPermaLink="false">http://flexbandit.com/?p=75</guid>
		<description><![CDATA[Increase the amount of heap used by Eclipse/FlexBuilder by adding the following command line options: -vmargs -Xms256M -Xmx512M Shortcut Example: "C:\Program Files\eclipse\eclipse.exe" -vmargs -Xms256M -Xmx512M Alternatively, you can update your eclipse.ini file. More information can be found on Ryan Phelan&#8217;s site. These examples have been tested on a Windows XP PC with 2GB RAM.]]></description>
			<content:encoded><![CDATA[<p>Increase the amount of heap used by Eclipse/FlexBuilder by adding the following command line options:</p>
<p><code>-vmargs -Xms256M -Xmx512M</code></p>
<p>Shortcut Example: <code>"C:\Program Files\eclipse\eclipse.exe" -vmargs -Xms256M -Xmx512M</code></p>
<p>Alternatively, you can update your eclipse.ini file.</p>
<p>More information can be found on <a title="Tweaking Compiler Performance in Flex Builder" href="http://www.rphelan.com/2008/03/27/tweaking-compiler-performance-in-flex-builder/" target="_blank">Ryan Phelan&#8217;s site</a>.</p>
<p>These examples have been tested on a Windows XP PC with 2GB RAM.</p>
]]></content:encoded>
			<wfw:commentRss>http://flexbandit.com/archives/75/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Subclipse With SSH &#8211; Top Tip</title>
		<link>http://flexbandit.com/archives/69</link>
		<comments>http://flexbandit.com/archives/69#comments</comments>
		<pubDate>Sun, 21 Jun 2009 13:36:17 +0000</pubDate>
		<dc:creator>donkeybandit</dc:creator>
				<category><![CDATA[Flex Gotchas]]></category>
		<category><![CDATA[Flex Info]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[SVN+SSH]]></category>

		<guid isPermaLink="false">http://flexbandit.com/?p=69</guid>
		<description><![CDATA[If you&#8217;ve attempted to use subclipse with a secure session, you may well have experienced the dreaded error message: The system cannot find the file specified. svn: Can't create tunnel: The system cannot find the file specified. Typically, you experience it when using a url with the following structure: svn+ssh://myfancy.svnserver.com/repo Thankfully there is a very [...]]]></description>
			<content:encoded><![CDATA[<p>If you&#8217;ve attempted to use subclipse with a secure session, you may well have experienced the dreaded error message:</p>
<p><code>The system cannot find the file specified.<br />
svn: Can't create tunnel: The system cannot find the file specified.</code></p>
<p>Typically, you experience it when using a url with the following structure:</p>
<p><code>svn+ssh://myfancy.svnserver.com/repo</code></p>
<p>Thankfully there is a very simple fix. All you need to do is <span id="more-69"></span>adjust one of the settings in the &#8220;<strong>Window-&gt;Preferences</strong>&#8221; menu.</p>
<p>Navigate the tree to &#8220;<strong>Team-&gt;SVN</strong>&#8221; and you will notice a section called &#8220;SVN Interface&#8221;. If the client is set to &#8220;JavaHL (JNI)&#8221; then <strong>change it to &#8220;SVNKit (Pure Java)&#8221;</strong>.</p>
<p>Thanks to <a href="http://markphip.blogspot.com/" target="_blank">Mark Phippard</a> for this gem.</p>
]]></content:encoded>
			<wfw:commentRss>http://flexbandit.com/archives/69/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Setting Up a Basic BlazeDS Server with Debugging</title>
		<link>http://flexbandit.com/archives/55</link>
		<comments>http://flexbandit.com/archives/55#comments</comments>
		<pubDate>Sun, 01 Mar 2009 22:17:38 +0000</pubDate>
		<dc:creator>donkeybandit</dc:creator>
				<category><![CDATA[ActionScript]]></category>
		<category><![CDATA[Flex Info]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[BlazeDS]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[HowTo]]></category>

		<guid isPermaLink="false">http://flexbandit.com/?p=55</guid>
		<description><![CDATA[Working with Eclipse is a great experience with lots of powerful features at your fingertips.  Unfortunately, for a beginner it can be a little difficult to get used to and not immediately obvious how to do certain tasks. Setting up projects can be particularly challenging, especially if you have a lot of extra development requirements [...]]]></description>
			<content:encoded><![CDATA[<p>Working with Eclipse is a great experience with lots of powerful features at your fingertips.  Unfortunately, for a beginner it can be a little difficult to get used to and not immediately obvious how to do certain tasks. Setting up projects can be particularly challenging, especially if you have a lot of extra development requirements (for example, using Maven, Ant, Sping, etc.).  Using the standard <a title="Getting started with BlazeDS" href="http://www.adobe.com/devnet/livecycle/articles/blazeds_gettingstarted.html" target="_blank">Adobe getting started guide</a> gives you a gentle introduction to remotiing and messaging, but doesn&#8217;t give you details on how to set up a clean &#8220;bare bones&#8221; application.</p>
<p>This article lists the steps to create a bare bones BlazeDS server configuration using the <a href="http://opensource.adobe.com/wiki/display/blazeds/BlazeDS/">turnkey</a> solution.<span id="more-55"></span></p>
<h2>What You&#8217;ll Need</h2>
<p>First I&#8217;ll assume you have already downloaded and installed the following:</p>
<ul>
<li>Eclipse</li>
<li>Flex Builder (or Flex Builder plugin for Eclipse)</li>
<li>BlazeDS turnkey</li>
</ul>
<p>If you followed all of the instructions for installing and running the basic BlazeDS turnkey, then you currently have a tomcat server running a demo on localhost (port 8400). If successful, you should see the BlazeDS index page by clicking <a title="Localhost BlazeDS Install..... hopefully!" href="http://localhost:8400/" class="broken_link">here</a>. If you see an error at this point, then you can go and check your server logs and try to correct it. <strong>Do not proceed with this guide until you see the functioning index page.</strong></p>
<p>Now you have successfully installed Tomcat and BlazeDS turnkey, you will need to turn it off as you won&#8217;t be using it from here. Yes that&#8217;s right, <strong>turn it off!</strong> Shutdown the tomcat server using any method you choose (i.e. ctrl-c, shutdown.bat, stop the service, catalina stop, etc.). This will free up port 8400 and allow you to run the server from Eclipse after we have configured it.</p>
<h2>Setting up Tomcat in Eclipse</h2>
<p>These are the steps for creating a connection to the tomcat server:</p>
<ol>
<li>Start Eclipse and select the &#8220;Java EE&#8221; perspective</li>
<li>In the bottom panel, select the &#8220;Servers&#8221; tab</li>
<li>Right click on the panel and select &#8220;New-&gt;Server&#8221;</li>
<li>Select the server settings and point them to your newly installed tomcat server. The installation directory should be &#8220;&lt;base turnkey installation dir&gt;\tomcat&#8221; (in my case this is &#8220;C:\blazeds\tomcat&#8221;).</li>
<li>Click Finish</li>
</ol>
<p>Once you have completed these steps, you should see a new server created in the &#8220;Servers&#8221; panel, plus a new tree entry in the Project Explorer (also called &#8220;Servers&#8221;). Your environment should look a bit like <a title="Server setup screenshot" href="http://flexbandit.com/wp-content/uploads/2009/03/eclipseserverscreenshot.jpg">this</a>.</p>
<h2>Creating a Project</h2>
<p>The next step is to create the server side project.</p>
<ol>
<li>Create a new &#8220;Dynamic Web Project&#8221; with the following settings:
<ul>
<li><strong>Project name:</strong> myBlazeProject</li>
<li><strong>Target Runtime:</strong> &#8220;Apache Tomcat x.x&#8221; (this is the server you created in the last section)</li>
<li><strong>Configuration:</strong> Default Configuration for Apache Tomcat x.x</li>
</ul>
</li>
<li>Click &#8220;Finish&#8221;</li>
</ol>
<p>After creating the project, your environment should look a little like <a href="http://flexbandit.com/wp-content/uploads/2009/03/eclipsenewprojectscreenshot.jpg">this</a>.</p>
<h2>Creating the Bare Bones BlazeDS Configuration</h2>
<p>Ok, we now have the server set up and a basic project. The next steps set up the BlazeDS libraries and configure the environment to auto-update the server when the project is built.</p>
<ol>
<li>Overwrite the contents of your &#8220;WebContent&#8221; directory with the BlazeDS directory structure &#8220;&lt;base turnkey installation dir&gt;\tomcat\webapps\blazeds&#8221;.  The result should look a little like <a href="http://flexbandit.com/wp-content/uploads/2009/03/eclipsecopiedfilesscreenshot.jpg">this</a>.</li>
<li>Right click on your newly created &#8220;myBlazeProject&#8221; project and select &#8220;Properties&#8221;</li>
<li>Select &#8220;Java Build Path&#8221; from the list in the left hand panel.</li>
<li>Set the &#8220;Default output folder&#8221; to &#8220;myBlazeProject/WebContent/WEB-INF/classes&#8221;. This will cause your web server to automatically update every time you rebuild your project.</li>
</ol>
<h2>Create a Basic Remote Class</h2>
<p>Great! We&#8217;re nearly there&#8230; now let&#8217;s create and configure a Java class so we can test our configuration.</p>
<ol>
<li>In the &#8220;myBlazeProject/WebContent/WEB-INF/src&#8221; directory, create a new class called HelloWorld.java.</li>
<pre>public class HelloWorld {
    public String sayHello(String name) {
        return "Hello, " + name;
    }
}</pre>
<li>Configure BlazeDS to allow remoting requests to the HelloWorld class by adding a destination to the &#8220;<strong>remoting-config.xml</strong>&#8221; file found in the &#8220;myBlazeProject/WebContent/WEB-INF/flex&#8221; directory. Use the following destination configuration:</li>
<pre>&lt;destination id="HelloWorld"&gt;
    &lt;properties&gt;
        &lt;source&gt;HelloWorld&lt;/source&gt;
    &lt;/properties&gt;
&lt;/destination&gt;</pre>
<li>Start your application server by clicking on the green &#8220;play&#8221; button. Verify your web application is configured by going to the following URL (The url and port may vary depending on your application server configuration and what you named your project): <a href="http://localhost:8400/myBlazeProject/" target="_blank" class="broken_link">http://localhost:8400/myBlazeProject/</a><br />
If your server is not configured to display directory contents, you might see a 404 error. This is OK, but failure to connect errors are not.</li>
</ol>
<h2>Create a Flex Project</h2>
<p>Whether you use the Flex Builder 3 plugin for Eclipse or standalone Flex builder 3 installation is entirely up to you. It&#8217;s possible to manage your Flex and Java code in one IDE if you use the plugin, but you may prefer the standalone IDE instead.</p>
<p>These steps create the Flex project and link it to your server:</p>
<ol>
<li>Create a new Flex Project
<ul>
<li> <strong>Project name: </strong>testHelloWorld</li>
<li><strong>Application server type:</strong> J2EE</li>
<li><strong>Use remote object access service:</strong> enabled (with &#8220;LiveCycle Data Services&#8221; selected)</li>
</ul>
</li>
<li>Click &#8220;Next &gt;&#8221;</li>
<li>Use these settings:
<ul>
<li><strong>Root folder:</strong> point this to your &#8220;WebContent&#8221; directory in the Java project</li>
<li><strong>Root URL:</strong> http://localhost:8400/myBlazeProject/</li>
<li><strong>Context Root:</strong> /myBlazeProject</li>
</ul>
</li>
<li>Click &#8220;Validate Configuration&#8221;</li>
<li>Click &#8220;Finish&#8221;</li>
</ol>
<h2>Create a Client Test Application</h2>
<p>Finally, let&#8217;s update the Flex project to use our BlazeDS Server so we can test our remote object:</p>
<ol>
<li>Update the testHelloWorld.mxml file with the following code:</li>
<pre>&lt;?xml version="1.0" encoding="utf-8"?&gt;
&lt;mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"&gt;

    &lt;mx:RemoteObject id="ro" destination="HelloWorld"/&gt;
    &lt;mx:TextInput id="n" change="ro.sayHello(n.text)"/&gt;
    &lt;mx:Label text="{ro.sayHello.lastResult}"/&gt;

&lt;/mx:Application&gt;</pre>
<li>Build and Run!</li>
</ol>
<p>If all went well, then you should have a working Flex app that connects to your remote service and responds with &#8220;Hello, &lt;your name&gt;&#8221;.  Something like <a title="Success!" href="http://flexbandit.com/wp-content/uploads/2009/03/chromeremoteresult.jpg" target="_blank">this</a>.</p>
<h2>Troubleshooting</h2>
<p>If you for some reason your components don&#8217;t talk to each other after following all the steps, try cleaning the projects and restarting the server.</p>
<h2>Server Side Debugging</h2>
<p>Now that we have created the bare bones server in this manner, we can use the fantastic debug functionality provided by Eclipse in the Java server code as well as the Eclipse client code!</p>
<p>To use the Java debug mode, just add your breakpoints to your source files and make sure the server is running in debug mode. Then when your Flex apps call the remote objects, they will trigger the debug mode and Eclipse will automagically put you into Java debug mode.</p>
<h2>Further Reading</h2>
<p>This article was inspired by the excellent in depth articles provided by the following sources:</p>
<ul>
<li><a href="http://www.javaworld.com/community/node/2181">Bare Bones BlazeDS Object Remoting &#8211; by Dustin Marx</a></li>
<li><a href="http://www.infoq.com/articles/blazeds-intro">Building Web and Desktop Applications with BlazeDS and AMF &#8211; by James Ward and Shashank Tiwari</a></li>
</ul>
]]></content:encoded>
			<wfw:commentRss>http://flexbandit.com/archives/55/feed</wfw:commentRss>
		<slash:comments>38</slash:comments>
		</item>
	</channel>
</rss>

