<?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>RemObjects Blogs &#187; Prism</title>
	<atom:link href="http://blogs.remobjects.com/blogs/category/tools/prism/feed" rel="self" type="application/rss+xml" />
	<link>http://blogs.remobjects.com</link>
	<description>Remobjects Software Blogs</description>
	<lastBuildDate>Wed, 16 May 2012 11:42:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Managed is the New Native</title>
		<link>http://blogs.remobjects.com/blogs/jim/2012/05/15/p4268</link>
		<comments>http://blogs.remobjects.com/blogs/jim/2012/05/15/p4268#comments</comments>
		<pubDate>Tue, 15 May 2012 07:02:23 +0000</pubDate>
		<dc:creator>Jim McKeeth</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>
		<category><![CDATA[Windows]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?p=4268</guid>
		<description><![CDATA[It used to be that native development referred to compilers outputting code ready to execute on the target CPU. At the time, the pool of possible CPUs was small, and the alternatives where runtime interpretation. Since then a lot has changed. Modern CPUs have multiple modes of execution (protected mode, long mode, etc.) and optionals [...]]]></description>
			<content:encoded><![CDATA[<p>It used to be that native development referred to compilers outputting code ready to execute on the target CPU. At the time, the pool of possible CPUs was small, and the alternatives where runtime interpretation. Since then a lot has changed. Modern CPUs have multiple modes of execution (<a href="http://en.wikipedia.org/wiki/Protected_mode">protected mode</a>, <a href="http://en.wikipedia.org/wiki/Long_mode">long mode</a>, etc.) and optionals instruction sets (<a href="http://en.wikipedia.org/wiki/SSE4">SSE4a</a>, <a href="http://en.wikipedia.org/wiki/SSE5">SSE5</a>, etc.). A &#8220;native code&#8221; compiler must choose a minimum level to target, ignoring &#8220;higher&#8221; level functionality available on newer CPUs. This leaves programs unable to take advantage of the latest CPU innovations, and often running in a legacy compatibility mode on the very CPU it targets.</p>
<p>What is more native on the latest 64-bit processor: 32-bit x86 code or intermediate code just-in-time compiled to take advantage of the 64-bit architecture and latest SSE instruction set? Not so simple, is it?</p>
<p>Managed code platforms such as Java and .NET have a &#8220;native&#8221; advantage that no unmanaged (so called &#8220;native code&#8221;) compilers can match. Because managed platforms distribute their programs in an intermediate format (Intermediate Language [IL] Assemblies for .NET and Byte-code for Java) the Just-In-Time (JIT) compiler is able to compile the program to specifically target the CPU it is running on. This means the program can scale up or down as necessary on each CPU, even a CPU that wasn&#8217;t released when you wrote the code.</p>
<p>A misconception is that managed applications are slower than unmanaged applications, or that managed applications are interpreted at runtime. A managed application is JIT compiled into highly optimized machine code immediately on execution.</p>
<p>The alternative for non-managed compilers is to compile to multiple targets and then provide software emulation for CPU instruction sets on older CPUs. The result is a more bloated program that contains emulation code that is rarely used, or a program that is unable to take advantage of the latest CPU optimizations.</p>
<p>Now that managed is the new native, it leaves developers free to focus on what is really important: <a href="http://blogs.remobjects.com/blogs/mh/2012/04/19/p4243">A Native User Experience</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.remobjects.com/blogs/jim/2012/05/15/p4268/feed</wfw:commentRss>
		<slash:comments>27</slash:comments>
		</item>
		<item>
		<title>Use Oxygene in the 2nd PGD Challenge</title>
		<link>http://blogs.remobjects.com/blogs/jim/2012/03/22/p4139</link>
		<comments>http://blogs.remobjects.com/blogs/jim/2012/03/22/p4139#comments</comments>
		<pubDate>Thu, 22 Mar 2012 16:58:46 +0000</pubDate>
		<dc:creator>Jim McKeeth</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>
		<category><![CDATA[short]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?p=4139</guid>
		<description><![CDATA[The 2nd Pascal Game Development challenge was officially announced, and Oxygene for .NET (AKA Prism) and Oxygene for Java are both listed as &#8220;Key Tools&#8221; and &#8220;Allowed Languages&#8220;. If you are using Oxygene for Java, you might want to take a look at the JMonkey Engine video on RemObjects TV back from when we were [...]]]></description>
			<content:encoded><![CDATA[<p>The <a href="http://www.pascalgamedevelopment.com/content.php?323-2nd-PGD-Challenge-Official-Announcement">2nd Pascal Game Development challenge</a> was officially announced, and <a href="http://www.remobjects.com/Oxygene/">Oxygene for .NET</a> (AKA <a href="http://www.embarcadero.com/products/prism">Prism</a>) and <a href="http://www.remobjects.com/Oxygene/java.aspx">Oxygene for Java</a> are both listed as &#8220;<em>Key Tools</em>&#8221; and &#8220;<em>Allowed Languages</em>&#8220;. If you are using Oxygene for Java, you might want to take a look at the <a href="http://www.remobjects.com/tv/oxygene-06-cooper3d">JMonkey Engine video</a> on RemObjects TV back from when we were still calling it &#8220;Cooper&#8221;.</p>
<p>As an added bonus, if your game is powered by Oxygene, we will provide you with a complementary Oxygene for Java license. </p>
<p><a href="http://www.youtube.com/watch?v=Knw_gjtqi8k&#038;fmt=18">http://www.youtube.com/watch?v=Knw_gjtqi8k</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.remobjects.com/blogs/jim/2012/03/22/p4139/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>&#8220;await&#8221;</title>
		<link>http://blogs.remobjects.com/blogs/mh/2012/03/08/p4032</link>
		<comments>http://blogs.remobjects.com/blogs/mh/2012/03/08/p4032#comments</comments>
		<pubDate>Thu, 08 Mar 2012 15:56:56 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Metro]]></category>
		<category><![CDATA[Month of Metro]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>
		<category><![CDATA[Visual Studio]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?p=4032</guid>
		<description><![CDATA[Progress is being made on our support for Metro, Visual Studio 11 and .NET 4.5 integration, on many levels. One exciting new language feature in Oxygene for both Metro and the regular .NET 4.5 framework is support for the new &#8220;await&#8221; keyword that is also coming to C#. Simply put, &#8220;await&#8221; lets you use the [...]]]></description>
			<content:encoded><![CDATA[<p>Progress is being made on our support for Metro, Visual Studio 11 and .NET 4.5 integration, on many levels. One exciting new <em>language</em> feature in <a href="http://www.remobjects.com/oxygene">Oxygene</a> for both Metro and the regular .NET 4.5 framework is support for the new &#8220;await&#8221; keyword that is also coming to C#.</p>
<p>Simply put, &#8220;await&#8221; lets you use the result of an asynchronous operation (such as the result of many of Metro&#8217;s and .NET 4.5 new APIs) or &mdash; only in Oxygene &mdash; an <em>async future</em>, and have the resulting code be &#8220;wrapped around&#8221; to run asynchronously, as well.</p>
<p>In Oxygene, when you access a <em>async future</em>&#8216;s value, your code will block right there, and wait for the <em>future</em> to complete before it continues executing &mdash; after all you&#8217;re using the value, and that value has to come from somewhere.</p>
<p>Using the &#8220;await&#8221; keyword, your code will look and work much the same as without, except your code will <em>not</em> block. Instead, all parts of the code that depend on the <em>future</em> value (or otherwise precede your accessing it) will be extracted and moved into a separate block of code that runs asynchronously.</p>
<p>This is best seen with a concrete example, so consider the following code:</p>

<div class="wp_syntax"><div class="code"><pre class="oxygene" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">method</span> MainForm<span style="color: #000066;">.</span><span style="color: #000000;">CountFiles</span><span style="color: #000066;">&#40;</span>aStartFolder<span style="color: #000066;">:</span> String<span style="color: #000066;">&#41;</span><span style="color: #000066;">:</span> Int32<span style="color: #000066;">;</span>
<span style="color: #000000; font-weight: bold;">begin</span>
  <span style="color: #000000; font-weight: bold;">result</span> <span style="color: #000066;">:</span><span style="color: #000066;">=</span> Directory<span style="color: #000066;">.</span><span style="color: #000000;">GetFiles</span><span style="color: #000066;">&#40;</span>aStartFolder<span style="color: #000066;">&#41;</span><span style="color: #000066;">.</span><span style="color: #000066;">Length</span><span style="color: #000066;">;</span>
  <span style="color: #000000; font-weight: bold;">for</span> <span style="color: #000000; font-weight: bold;">each</span> d <span style="color: #000000; font-weight: bold;">in</span> Directory<span style="color: #000066;">.</span><span style="color: #000000;">GetDirectories</span><span style="color: #000066;">&#40;</span>aStartFolder<span style="color: #000066;">&#41;</span> <span style="color: #000000; font-weight: bold;">do</span>
    <span style="color: #000000; font-weight: bold;">result</span> <span style="color: #000066;">:</span><span style="color: #000066;">=</span> <span style="color: #000000; font-weight: bold;">result</span><span style="color: #000066;">+</span>CountFiles<span style="color: #000066;">&#40;</span>d<span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
<span style="color: #000000; font-weight: bold;">end</span><span style="color: #000066;">;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">method</span> MainForm<span style="color: #000066;">.</span><span style="color: #000000;">button1_Click</span><span style="color: #000066;">&#40;</span>sender<span style="color: #000066;">:</span> System<span style="color: #000066;">.</span><span style="color: #000000;">Object</span><span style="color: #000066;">;</span> e<span style="color: #000066;">:</span> System<span style="color: #000066;">.</span><span style="color: #000000;">EventArgs</span><span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
<span style="color: #000000; font-weight: bold;">begin</span>
  <span style="color: #000000; font-weight: bold;">var</span> x <span style="color: #000066;">:</span><span style="color: #000066;">=</span> <span style="color: #000000; font-weight: bold;">async</span> CountFiles<span style="color: #000066;">&#40;</span><span style="color: #ff0000;">'C:\'</span><span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
&nbsp;
  MessageBox<span style="color: #000066;">.</span><span style="color: #000000;">Show</span><span style="color: #000066;">&#40;</span><span style="color: #ff0000;">'You have '</span><span style="color: #000066;">+</span><span style="color: #000066;">&#40;</span><span style="color: #000000; font-weight: bold;">await</span> x<span style="color: #000066;">&#41;</span><span style="color: #000066;">+</span><span style="color: #ff0000;">' files.'</span><span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
<span style="color: #000000; font-weight: bold;">end</span><span style="color: #000066;">;</span></pre></div></div>

<p>Without the use of &#8220;await&#8221; (or without the use of the &#8220;async&#8221; keyword, which turns &#8220;x&#8221; into an <em>async future Int32</em>), this button click event would block, and your entire application would be hung while the program crawls across your harddisk to count files.</p>
<p>The <em>async future</em>, on its own, has the potential of making the the count asynchronous, but the following &#8220;MessageBox.Show&#8221; would block right away, making the use of the <em>future</em> essentially useless. Complex code could be written to wait for the <em>future</em> and then trigger the message box from a different place in code.</p>
<p>But &#8220;await&#8221; takes care of all that; it allows you to write code using the &#8220;na&iuml;ve&#8221; approach without worrying about application flow. You can concentrate on your application logic, and the complexities of threading (and synchronization of results back to the main thread) are handled for you.</p>
<p>So what happens when you run this? Easy: when you click the button, our <em>async future</em> is created and started, causing the (recursive) call to CountFiles. Once that is up and running, the event handler is done and returns control to your application. Now the <em>future</em> is running in the background, counting files, and probably taking a few minutes to do it, depending on your harddisk size.</p>
<p>Once the <em>future</em> is complete, the message string is assembled and &#8220;MessageBox.Show&#8221; is called to display it &mdash; also on the main thread, synchronized via the application&#8217;s message loop.</p>
<p>All this time, your application remains responsive! As a matter of fact, in the example above, i could go ahead and click the button several times, launching a handful of independent file scans (which of course makes little sense in this scenario &mdash; a real app could disable the one button, or might let you scan <em>different</em> folders at the same time, getting the path from an edit field) that run in parallel, and will each eventually respond with a message box, one by one.</p>
<p>&nbsp;</p>
<p><center><a href="http://blogs.remobjects.com/blogs/category/non-tech/month-of-metro"><img src="http://blogs.remobjects.com/wp-content/uploads/2012/02/MonthOfMetro.png" width="300"/></center></a></p>
<p>&nbsp;</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.remobjects.com/blogs/mh/2012/03/08/p4032/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Tell me, where have all the colors gone?</title>
		<link>http://blogs.remobjects.com/blogs/mh/2012/03/02/p4022</link>
		<comments>http://blogs.remobjects.com/blogs/mh/2012/03/02/p4022#comments</comments>
		<pubDate>Fri, 02 Mar 2012 22:30:49 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[Cooper]]></category>
		<category><![CDATA[Month of Metro]]></category>
		<category><![CDATA[Prism]]></category>
		<category><![CDATA[Visual Studio]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?p=4022</guid>
		<description><![CDATA[Our first progress report for the &#8220;Month of Metro&#8221;. One of the big changes in Visual Studio eleven is the new color scheme. Or should i say, lack-of-color scheme. Visual Studio 11 employs a new image style throughout the entire IDE for all icons, from project templates over toolbars to the files and other items [...]]]></description>
			<content:encoded><![CDATA[<p>Our first progress report for the &ldquo;Month of Metro&rdquo;.</p>
<p>One of the big changes in Visual Studio eleven is the new color scheme. Or should i say, lack-of-color scheme. Visual Studio 11 employs a new image style throughout the entire IDE for all icons, from project templates over toolbars to the files and other items in Solution Explorer.</p>
<p>Love it or hate it (and most people i talk to, including myself (yes, i talk to myself), haven&#8217;t really made it to the  &ldquo;love&rdquo; side of things yet), but it&#8217;s unique and distinctive, and in order to be a proper citizen of Visual Studio 11, we have to embrace it.</p>
<p>I have spent the better part of yesterday working on our template icons and solution explorer icons, and i&#8217;m happy to share what we have come up with:</p>
<p><center><img src="http://blogs.remobjects.com/wp-content/uploads/2012/03/Solution-Explorer.png" alt="Solution Explorer" /></center></p>
<p>&nbsp;</p>
<p>As you can see, i have tried to take some liberties, and not completely given up on color. In Visual Studio 2010, our project icons for Oxygene have been blue for .NET and yellow for Java, and i have stuck to that, and extended it to the code file icons as well, which show a subtle blue or yellow background shading.</p>
<p>Let us know what you think, but IMHO this retains a little bit of color in your solution, helps keep you distinguish between .NET and Java, if you happen to work with both, and i would say it still fits in nicely with the overal theming om the new Solution Explorer.</p>
<p>For reference, i have also included a C# project in the solution. In contrats to Oxygene, C# is entirely black-on-gray, and TBH i&#8217;m not really a fan of the &#8220;C#&#8221; text/logo as icon for the source code files &ndash; what do you think?</p>
<p>&nbsp;</p>
<p><center><a href="http://blogs.remobjects.com/blogs/category/non-tech/month-of-metro"><img src="http://blogs.remobjects.com/wp-content/uploads/2012/02/MonthOfMetro.png" width="300"/></center></a></p>
<p>&nbsp;</p>
<p>ps: my apologies. when i say &ldquo;Solution  Explorer&rdquo;, i of course mean &ldquo;SOLUTION EXPLORER&rdquo;. ;)</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.remobjects.com/blogs/mh/2012/03/02/p4022/feed</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Choosing the Best Toolchain for each Platform</title>
		<link>http://blogs.remobjects.com/blogs/mh/2012/02/04/p3836</link>
		<comments>http://blogs.remobjects.com/blogs/mh/2012/02/04/p3836#comments</comments>
		<pubDate>Sat, 04 Feb 2012 17:48:22 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Cocoa]]></category>
		<category><![CDATA[Delphi]]></category>
		<category><![CDATA[iOS]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Mac]]></category>
		<category><![CDATA[Metro]]></category>
		<category><![CDATA[Mono]]></category>
		<category><![CDATA[MonoDroid]]></category>
		<category><![CDATA[MonoTouch]]></category>
		<category><![CDATA[non-tech]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Platforms]]></category>
		<category><![CDATA[Prism]]></category>
		<category><![CDATA[RemObjects]]></category>
		<category><![CDATA[ROFX]]></category>
		<category><![CDATA[Visual Studio]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[WP7]]></category>
		<category><![CDATA[Xcode]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?p=3836</guid>
		<description><![CDATA[Four or five years ago, the software world was simple: if you were a commercial software developer, you were developing for Windows. But this has changed drastically with the advent of mobile platforms such as iOS and Android, the steadily increasing market share of Macs, and the establishment of new development paradigms such as rich [...]]]></description>
			<content:encoded><![CDATA[<p>Four or five years ago, the software world was simple: if you were a commercial software developer, you were developing for Windows. But this has changed drastically with the advent of mobile platforms such as iOS and Android, the steadily increasing market share of Macs, and the establishment of new development paradigms such as rich web applications hosted in browsers.</p>
<p>Here at RemObjects, I field the majority of so called &#8220;sales related&#8221; emails (that is, emails that aren&#8217;t technical support requests handled by our excellent support team and the product developers) myself &mdash; and as this century gets older, I see more and more requests asking what tools and toolchains to pick for different platforms. &#8220;Can I develop for both Windows Phone 7 and Android with Oxygene and share code?&#8221; &mdash; &#8220;Which version of Data Abstract is best for targeting iOS?&#8221; &mdash; &#8220;Should I use Oxygene for .NET with MonoDroid or Oxygene for Java for my Android app?&#8221;.</p>
<p>There are a lot of great development tool chains for the different platforms out there &mdash; be they Xcode/Cocoa, Visual Studio/.NET, Delphi, JavaScript &mdash; and sometimes the decision does not seem easy, because here at RemObjects we provide editions of most of our products for various development platforms, and often more than one choice can be applied to a specific platform need.</p>
<p>To help make heads and tails of this, we created a small graphical overview chart on our website that gives insight into which language/framework/product combinations we support on any given platform and &mdash; more importantly IMHO &mdash; which combination we recommend.*</p>
<p>[*And that recommendation might not always be what you think &mdash; for example, I often get looked at weirdly when I recommend Xcode over our own <a href="http://www.remobjects.com/oxygene">Oxygene</a> (plus Mono) for Mac development. But development tools, even versatile ones such as Oxygene, or Delphi, or Visual Studio, are not and should not be Jacks of all Trades, and thus no single tool, no matter how great (and we happen to think Oxygene is pretty great ;) can be the best choice for <i>all</i> scenarios. We acknowledge and honor that.]</p>
<p>You can find this overview matrix &mdash; which will be ever-expanding as time goes by and the development world around us changes &mdash; at <a href="http://www.remobjects.com/products/toolchains">remobjects.com/products/toolchains</a>; i&#8217;m also including a static screenshot of it, below.</p>
<p>May it help you to choose the best set of tools for your needs!</p>
<p><center><br />
<img src="http://blogs.remobjects.com/wp-content/uploads/2012/02/toolchains.png" alt="" /><br />
</center></p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.remobjects.com/blogs/mh/2012/02/04/p3836/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Wireless Android Control</title>
		<link>http://blogs.remobjects.com/blogs/brian-long/2012/02/03/p3855</link>
		<comments>http://blogs.remobjects.com/blogs/brian-long/2012/02/03/p3855#comments</comments>
		<pubDate>Fri, 03 Feb 2012 16:03:00 +0000</pubDate>
		<dc:creator>Brian Long</dc:creator>
				<category><![CDATA[Guest Post]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?guid=d4a1070a384247b123d418f3147eaf03</guid>
		<description><![CDATA[I’ve bumped into a couple of wireless Android control apps lately, one targeted at developers and one targeted at users. The two apps rely on both your Android device and the computer that will be wirelessly connected to it being on the same Wi-fi ne...]]></description>
			<content:encoded><![CDATA[<p>I’ve bumped into a couple of wireless Android control apps lately, one targeted at developers and one targeted at users. The two apps rely on both your Android device and the computer that will be wirelessly connected to it being on the same Wi-fi network, which is fair enough – you’ll be using this in a home or work environment.</p>
<p><u>adbWireless</u></p>
<p><a href="https://market.android.com/details?id=siir.es.adbWireless">adbWireless</a> one is solely aimed at developers, and I was introduced to it by <a href="http://blogs.remobjects.com/blogs/jim/2012/01/12/p3786">Jim McKeeth’s blog post</a> on using it in conjunction with Oxygene for Java.</p>
<p>Once you enable the app with the big red button on the main screen you can have <span style="font-family: consolas;font-size: small">adb</span> on your computer hook up to your device across the Wi-fi network, rather than via the more typical USB cable connection. This is done using the <span style="font-family: consolas;font-size: small">adb connect &lt;IP_address&gt;</span> command, where the IP address has a port specification and is supplied by adbWireless after the button is pressed.</p>
<p align="center"><a href="http://lh5.ggpht.com/-ZWTLmXOX2fA/Tyv3Iw22U-I/AAAAAAAAA7c/u6Kg5FzVrLk/s1600-h/adbWireless%25255B2%25255D.jpg"><img style="border-bottom: 0px;border-left: 0px;padding-left: 0px;padding-right: 0px;border-top: 0px;border-right: 0px;padding-top: 0px" border="0" alt="adbWireless" src="http://lh5.ggpht.com/-aJV9TqAXgFo/Tyv3JV4k-7I/AAAAAAAAA7k/fA4M7p-l1_c/adbWireless_thumb.jpg?imgmax=800" width="164" height="244"></a></p>
<p>After making this wireless <span style="font-family: consolas;font-size: small">adb</span> connection, you can work normally from the computer, deploying, running and debugging against the device. This works from any Android development tool, such as Eclipse or Oxygene for Java.</p>
<p>One rather large caveat, however, is that adbWireless only works on a <a href="http://en.wikipedia.org/wiki/Rooting_(Android_OS)">rooted</a> device. Rooting your device to gain root access is not risk-free (so on your own head be it!) and not always achievable.</p>
<p>In my case I recently tried to root my <a href="http://en.wikipedia.org/wiki/HTC_Desire">HTC Desire</a>, but failed to do so (fortunately without bricking it). This was not due to a lack of information on how to proceed – indeed the Desire is (relatively) old now, being introduced in February 2010. However the avenue I took to root it (<a href="http://unrevoked.com/">unrevoked</a> – a very straightforward, automated, hands-free approach) had not been updated to cope with the most recent firmware update that was applied to the telephone not long ago. I’ll have to try again when unrevoked is next <a href="http://unrevoked.com/rootwiki/doku.php/public/unrevoked3#changelog">updated</a>.</p>
<p>I very much like the idea of adbWireless, but currently I’m not in a position to try it out….</p>
<p><u>AirDroid</u></p>
<p><a href="https://market.android.com/details?id=com.sand.airdroid&amp;hl=en">AirDroid</a> is a general way of controlling your phone, using its services and accessing its data from a web page loaded on a machine on the same Wi-Fi network.</p>
<p>When you start AirDroid it shows you a simple IP-based local network URL that you can enter in a web browser on your computer, and a password to log in with.</p>
<p align="center"><a href="http://lh3.ggpht.com/-cHG7_lHXHAc/Tyv3K078dzI/AAAAAAAAA7o/09v-LFtAkHg/s1600-h/AirDroid_Phone%25255B2%25255D.png"><img style="border-bottom: 0px;border-left: 0px;padding-left: 0px;padding-right: 0px;border-top: 0px;border-right: 0px;padding-top: 0px" border="0" alt="AirDroid_Phone" src="http://lh4.ggpht.com/-Wv5TsdAuIb4/Tyv3LcWXuSI/AAAAAAAAA7s/L62OW6M1jYU/AirDroid_Phone_thumb.png?imgmax=800" width="140" height="244"></a></p>
<p>Navigating to the URL in a desktop browser shows the web site pushed out by AirDroid, offering many options including:</p>
<ul>
<li>browsing, playing and setting your ring/notification/alarm tones</li>
<li>browsing your photos, including options to download, set as wallpaper or delete)</li>
<li>browse your SMS conversations, compose and send SMS messages</li>
<li>browse/edit/delete your contacts</li>
<li>browse all details of your call log</li>
<li>browse installed apps, export apps and install new apps</li>
<li>browse details of storage</li>
<li>and more besides…</li>
</ul>
<p>The app itself also allows you to analyse/control various aspects of your device, including running tasks (and the obligatory task killer) memory usage:</p>
<p align="center"><a href="http://lh6.ggpht.com/-EKez6aljpwU/Tyv3MTwByKI/AAAAAAAAA74/rRKLV0uJ_MU/s1600-h/AirDroid_Phone2%25255B2%25255D.png"><img style="border-bottom: 0px;border-left: 0px;padding-left: 0px;padding-right: 0px;border-top: 0px;border-right: 0px;padding-top: 0px" border="0" alt="AirDroid_Phone2" src="http://lh6.ggpht.com/-rcCux2N2Q2M/Tyv3NJciczI/AAAAAAAAA8E/jML0VZnjHGk/AirDroid_Phone2_thumb.png?imgmax=800" width="140" height="244"></a></p>
<p>I’ve already found this app very useful. On my old phone I had a couple of apps that I’d refused to update with newer versions as I had seen the newer versions crippled the (free) apps and removed functionality from what I had installed. Additionally there was an app that had since been removed from the Android Market. With AirDroid I simply exported the apps in question from the old phone web site, then used the web site of the new phone to install them – problem solved!</p>
<p>Here’s the AirDroid web page showing storage analysis on a new phone that has been in active use for a few days:</p>
<p align="center"><a href="http://lh3.ggpht.com/-ZzKuY7BurW4/Tyv3P8tEedI/AAAAAAAAA8M/kjQTxxuGHNg/s1600-h/AirDroid_Desktop%25255B2%25255D.png"><img style="border-bottom: 0px;border-left: 0px;padding-left: 0px;padding-right: 0px;border-top: 0px;border-right: 0px;padding-top: 0px" border="0" alt="AirDroid_Desktop" src="http://lh4.ggpht.com/-yrlg6QZzKsU/Tyv3ROn8txI/AAAAAAAAA8U/js0zhjryosY/AirDroid_Desktop_thumb.png?imgmax=800" width="244" height="125"></a></p>
<p>Note that AirDroid works on any Android device, regardless of whether it has been rooted or not.</p>
<p>Also note that AirDroid is currently in beta and so you do occasionally get little hiccups, but in general it is an impressive piece of work.</p>
<div class="blogger-post-footer"><img /></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.blong.com/feeds/9113567342639945959/comments/default</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Problems installing and/or launching Android apps (2)</title>
		<link>http://blogs.remobjects.com/blogs/brian-long/2012/02/02/p3845</link>
		<comments>http://blogs.remobjects.com/blogs/brian-long/2012/02/02/p3845#comments</comments>
		<pubDate>Thu, 02 Feb 2012 17:15:00 +0000</pubDate>
		<dc:creator>Brian Long</dc:creator>
				<category><![CDATA[Guest Post]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?guid=8fb61a7a52462f09ab1af1f3b807c656</guid>
		<description><![CDATA[Further to my previous post on common problems installing and/or launching Android apps, here’s a little titbit to add into the mix. In that previous post I mentioned: Sometimes a small change in the application, like updating the package name or alt...]]></description>
			<content:encoded><![CDATA[<p>Further to my previous post on <a href="http://blog.blong.com/2012/01/problems-installing-andor-launching.html">common problems installing and/or launching Android apps</a>, here’s a little titbit to add into the mix.</p>
<p>In that previous post I mentioned:</p>
<blockquote><p>Sometimes a small change in the application, like updating the package name or altering the signing process (i.e. changing the package’s signature), will mean an application can’t be <em>re</em>-installed over a previous version.</p></blockquote>
<p>Just to add more detail, I realised there is a classic case of this type of issue. In building up either Android samples or proper applications in <a href="http://www.remobjects.com/oxygene/java">Oxygene for Java</a>, I often copy the project between machines, switching between a couple of laptops and a VM on a desktop machine. In the case of simple projects this machine switch is either done using a shared network drive or using <a href="http://blog.blong.com/2012/02/dropbox.html">my DropBox folder</a>.</p>
<p>The point is that as soon as I switch to another machine and start building a regular Android application I can no longer install it from the development environment. This is because Oxygene wants to re-install the application (so that any app data, such as SQLite databases) are preserved between increments of the application. That’s nice of Oxygene, but it’s hitting an issue with this goal.</p>
<p>Here&#8217;s the problem. As I mentioned in <a href="http://blong.com/Articles/OxygeneGoogleMaps/GoogleMaps2.htm#GetKey">another article</a>, without a dedicated certificate, the Android SDK tools invoked by Oxygene will use the default Android debug key to sign the application. The Android debug key is created on a given machine the first time the SDK tools are used to build an application. From machine to machine each Android debug key will be different, so when you go to re-install the same application compiled on a different machine Android will notice the inconsistencies in debug certificates and reject the re-installation attempt.</p>
<p>You have no choice but to drop to the command-line and use <span style="font-family: consolas;font-size: small">adb</span> to uninstall the application. After this, the application should install and run just fine.</p>
<p>Of course you get the same problem when using a dedicated certificate and you re-create it for whatever reason, or if on a given machine the Android debug certificate expires and gets recreated by the SDK tools (this happens every year, as the debug certificate is created with a validity period of 365 days). </p>
<div class="blogger-post-footer"><img /></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.blong.com/feeds/4578595154785874389/comments/default</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Jan 2012 Release of Oxygene</title>
		<link>http://blogs.remobjects.com/blogs/brian-long/2012/02/02/p3847</link>
		<comments>http://blogs.remobjects.com/blogs/brian-long/2012/02/02/p3847#comments</comments>
		<pubDate>Thu, 02 Feb 2012 16:51:00 +0000</pubDate>
		<dc:creator>Brian Long</dc:creator>
				<category><![CDATA[Guest Post]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?guid=545e2f36afb0533c03f5a8d64d6b39d6</guid>
		<description><![CDATA[On 27th January RemObjects released their first update to their Oxygene 5 products, Oxygene for .NET (aka Delphi Prism, aka Prism) and Oxygene for Java (aka Project “Cooper”). Oxygene for .NET v5 was released as part of Embarcadero’s RAD Studio X...]]></description>
			<content:encoded><![CDATA[<p>On 27th January RemObjects released their first update to their <a href="http://blog.blong.com/2011/09/oxygene-5.html">Oxygene 5</a> products, <a href="http://www.remobjects.com/oxygene/">Oxygene for .NET</a> (aka <a href="http://www.embarcadero.com/products/delphi"><a href="http://www.embarcadero.com/products/delphi-prism">Delphi Prism</a>,</a> aka Prism) and <a href="http://www.remobjects.com/oxygene/java">Oxygene for Java</a> (aka Project “Cooper”).</p>
<p>Oxygene for .NET v5 was released as part of Embarcadero’s <a href="http://edn.embarcadero.com/article/41595">RAD Studio XE2</a> in September 2011 and Oxygene for Java was initially released in September 2011.</p>
<p>Both products feature a completely re-written Oxygene compiler, no longer written in C#, but written in Oxygene itself, both the .NET and Java versions sharing the same code base. The integration into Visual Studio was also entirely re-architected and re-implemented to support better future extensibility.</p>
<p>The January 2012 release of Oxygene cleans up a whole bunch of teething problems inevitable in a complete re-write of a product and also inevitable, in the case of Oxygene for Java, in a product targeting a whole new platform. It also introduces new features and covers a number of user requests. The <a href="http://www.remobjects.com/changelogs.aspx?id=%7B732D12D5-F93C-4F87-A8AA-B251B14660B3%7D">change log</a> details the plethora of updates, improvements and fixes.</p>
<p>If you already have Oxygene in one of its various guises and have an active subscription, then you can pull down the update from the RemObjects <a href="http://downloads.remobjects.com/">downloads page</a>. The update will work out which Oxygene edition (or editions) you have and update accordingly.</p>
<p>If you want to try Oxygene, either for .NET, Java or both platforms, pop along and get the updated <a href="http://www.remobjects.com/trials">trial version</a>.</p>
<div class="blogger-post-footer"><img /></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.blong.com/feeds/554688604411411354/comments/default</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Hydra 4 and Oxygene January 2012 Releases</title>
		<link>http://blogs.remobjects.com/blogs/mh/2012/02/01/p3824</link>
		<comments>http://blogs.remobjects.com/blogs/mh/2012/02/01/p3824#comments</comments>
		<pubDate>Wed, 01 Feb 2012 14:32:04 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Android]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Cooper]]></category>
		<category><![CDATA[Delphi]]></category>
		<category><![CDATA[Hydra]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>
		<category><![CDATA[Visual Studio]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[WP7]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?p=3824</guid>
		<description><![CDATA[We&#8217;re hitting the ground running for 2012 and finished January with the first two product releases of the year. Hydra 4 Hydra 4 is a major new release for our .NET/Delphi cross-platform product, and one we&#8217;re very excited about. Hydra has been at version 3 for a while now and seen mostly incremental changes, but [...]]]></description>
			<content:encoded><![CDATA[<p>We&#8217;re hitting the ground running for 2012 and finished January with the first two product releases of the year.</p>
<h2>Hydra 4</h2>
<p><a href="http://www.remobjects.com/hydra">Hydra 4</a> is a major new release for our .NET/Delphi cross-platform product, and one we&#8217;re very excited about. Hydra has been at version 3 for a while now and seen mostly incremental changes, but with version 4 we&#8217;re adding three major new features/platforms to the mix:</p>
<ul>
<li>Support for 64-bit Delphi Host Applications and Plugins</li>
<li>Support for FireMonkey Host Applications and Plugins</li>
<li>Support for hosting Silverlight-based Plugins</li>
</ul>
<p>Compiling true <strong>64-bit Windows</strong> applications has been on the wish-list for Delphi developers for a long time, and Delphi XE2 finally provided the elusive support, and Hydra has been updated to match. This makes it easier to build applications that use large amounts of memory, can interact with .NET plugins in 64-bit space, or simply run more natively on the 64-bit Windows systems that are standard these days.</p>
<p><strong>FireMonkey</strong> is Embarcadero&#8217;s new framework for creating rich &#8220;HD&#8221; or 3D graphical user interfaces in Delphi, and it is destined to supersede the VCL sooner or later. Unfortunately, Embarcadero does not let applications mix FireMonkey (FMX) and VCL by default — but that is no reason to jump ship to FireMonkey and discard all your existing VCL code. Hydra adds FireMonkey to its list of platforms supported by plugins and lets you seamlessly mix new FireMonkey UI alongside existing VCL code or even among WinForms and WPF. And FireMonkey host support lets you create new FMX applications and integrate existing VCL (or WinForms and WPF) code and UI into them, as well.</p>
<p>Finally, there&#8217;s <strong>Silverlight</strong>, Microsoft&#8217;s platform for rich web controls and (more prominently, as of recent) Windows Phone 7. Silverlight is based on the same concepts as .NET but uses a smaller and a tad more limited runtime — in exchange it can run in Browsers on Windows and Mac, as well as on Microsoft&#8217;s new phone platform. With Hydra 4, Silverlight can now also run in your Delphi (or .NET) based host applications, alongside other plugins. This allows you to easily share code and visual elements between your web application and your desktop app, or between your phone and your desktop.</p>
<p>We think Hydra 4 will be an essential tool for the modern Delphi developer — whether to add .NET to your Delphi projects or to add FireMonkey.</p>
<p>Hydra 4 is a free update to all users with an active subscription and available for immediate download. If your subscription expired before January 27, you can renew now for $249 to get access to Hydra 4; the price for new users is $499, including on year of free updates (and we do have more exciting stuff planned for Hydra in 2012!). Of course Hydra 4 is also included in the Suite Subscriptions for both .NET and Delphi.</p>
<h2>Oxygene — January 2012 Release</h2>
<p>Last November, we shipped a major new release of Oxygene, introducing the brand new <a href="http://www.remobjects.com/oxygene/java">Oxygene for Java</a> as second platform for everyone&#8217;s favorite modern Object Pascal.</p>
<p>After skipping the holidays, we&#8217;re back to our monthly release cycle, and the January 2012 release kicks the year off with a large range of fixes and enhancements for both .NET and Java/Android developers. Altogether, the <a href="http://www.remobjects.com/changelogs.aspx?id={732D12D5-F93C-4F87-A8AA-B251B14660B3}">change log</a> contains over 170 improvements.</p>
<p>The new Oxygene build is a free update for all customers with an active subscription, including all users of Prism XE2 and RAD Studio XE2.</p>
<p>For those of you using Oxygene for both .NET and Java, the update (like all future updates) is a combined installer — it will automatically detect if you have both editions of Oxygene and update both.</p>
<h2>Get Em While They&#8217;re Hot</h2>
<p>Head over to our trials download page at <a href="http://www.remobjects.com/trials">remobjects.com/trials</a> now to give Hydra 4 or Oxygene a spin. Or if you&#8217;re already a customer, visit the <a href="http://downloads.remobjects.com">downloads page</a> on your customer portal to get the latest versions.</p>
<p>Oxygene and Hydra go great together by the way. If you&#8217;re a Delphi-only developer right now but thinking about adding .NET code to your application, Hydra makes that easy, and Oxygene lets you keep using the familiar Object Pascal language, even for your .NET work.</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.remobjects.com/blogs/mh/2012/02/01/p3824/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Android Design site</title>
		<link>http://blogs.remobjects.com/blogs/brian-long/2012/01/18/p3807</link>
		<comments>http://blogs.remobjects.com/blogs/brian-long/2012/01/18/p3807#comments</comments>
		<pubDate>Wed, 18 Jan 2012 17:08:00 +0000</pubDate>
		<dc:creator>Brian Long</dc:creator>
				<category><![CDATA[Guest Post]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?guid=363b32d3094e83700a05b8b89c36e767</guid>
		<description><![CDATA[For all those working in Android development you should head along to the new Android Design web site. This new area on the Android developer's site gives the low down on how to design Android applications and looks at the various controls, common aspe...]]></description>
			<content:encoded><![CDATA[<p>For all those working in Android development you should head along to the new <a href="http://developer.android.com/design">Android Design</a> web site.</p>
<p>This new area on the Android developer&#8217;s site gives the low down on how to design Android applications and looks at the various controls, common aspects of Android UIs, style, and much more. It’s been put together to help people get a handle on how to work with the new Ice Cream Sandwich (Android 4.0) release.</p>
<p>It makes useful and interesting reading!</p>
<div class="blogger-post-footer"><img /></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.blong.com/feeds/3650530126141029845/comments/default</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Problems installing and/or launching Android apps</title>
		<link>http://blogs.remobjects.com/blogs/brian-long/2012/01/18/p3806</link>
		<comments>http://blogs.remobjects.com/blogs/brian-long/2012/01/18/p3806#comments</comments>
		<pubDate>Wed, 18 Jan 2012 14:52:00 +0000</pubDate>
		<dc:creator>Brian Long</dc:creator>
				<category><![CDATA[Guest Post]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?guid=4dfbde1e040e26d7fa0415da8fe9de52</guid>
		<description><![CDATA[Sometimes you try and launch your Android application from Oxygene for Java and nothing much happens. Sometimes you the application builds successfully and then nothing appears on the device. Sometimes you go to choose a target device to deploy to and ...]]></description>
			<content:encoded><![CDATA[<p>Sometimes you try and launch your Android application from Oxygene for Java and nothing much happens. Sometimes you the application builds successfully and then nothing appears on the device. Sometimes you go to choose a target device to deploy to and none are listed. There are many of these sort of problems, which often have very simple solutions.</p>
<p>When building Android apps with any development tool, be it Oxygene for Java, C# and Mono for Android or Java and Eclipse, there are a lot of different tools trying to work together to produce the results you want. In the case of Oxygene for Java we have Microsoft’s <a href="http://www.microsoft.com/visualstudio">Visual Studio</a>, RemObjects’ <a href="http://www.remobjects.com/oxygene/java">Oxygene for Java</a> compiler, Google’s <a href="http://developer.android.com/sdk/index.html">Android SDK</a> tools and Oracle’s <a href="http://www.oracle.com/technetwork/java/javase/downloads/index.html">Java</a> tools. All different tools, of various versions from different software companies. Sometimes tools from different vendors don’t play well together.</p>
<p>For most of the problems I mention above i find the commonest cause is that the <a href="http://developer.android.com/guide/developing/tools/adb.html">Android Debug Bridge</a> (adb) daemon has gone ‘stale’. You can try a quick remedy by bringing up a command prompt and running these commands:</p>
<p><span style="font-family: consolas;font-size: small">adb kill-server<br />adb start-server</span></p>
<p>Then try what you were trying before and see if that improves matters. Note that you’ll need the Android SDK’s <span style="font-family: consolas;font-size: small">platform-tools</span> directory on your path to run the command without fully-qualifying the call to adb.exe.</p>
<p>If that doesn’t fix the problem then you should resort to the Android logs to see if there are any clues, for example, in the case of an application not installing on a device or emulator.</p>
<p>You can see the logs either by using:</p>
<p><span style="font-family: consolas;font-size: small">adb –d logcat</span></p>
<p>or by running <a href="http://developer.android.com/guide/developing/debugging/ddms.html">DDMS</a> from the Android SDK and selecting the appropriate device.</p>
<p>During the attempt to install your app there will be log messages showing the progress and when the failure occurs you should see some sort of error message and maybe a call stack to assist working out what’s wrong.</p>
<p>Additionally, if you install your app from the command-line (as opposed to your IDE) you will often see an error code printed, which you can look for advice on with an Internet search. The error code is the name of a static field from the <a href="http://developer.android.com/reference/android/content/pm/PackageManager.html"><span style="font-family: consolas;font-size: small">PackageManager</span></a> class, albeit one that won’t be listed in the Android SDK documentation You can, however, find them in the <a href="http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android/4.0.1_r1/android/content/pm/PackageManager.java#PackageManager.0INSTALL_FAILED_ALREADY_EXISTS">Android source</a>.</p>
<p>A command-line install looks like this</p>
<p><span style="font-family: consolas;font-size: small">adb –d install –r mypackage.apk</span></p>
<p>The <span style="font-family: consolas;font-size: small">–r</span> switch requests a reinstall, which preserves app data such as databases. If that is not important, skip the <span style="font-family: consolas;font-size: small">–r</span> from the command.</p>
<p>For example, if you messed up the details of a certificate the app was signed with, you might get this:</p>
<p><span style="font-family: consolas;font-size: small">Failure [<a href="http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android/4.0.1_r1/android/content/pm/PackageManager.java#PackageManager.0INSTALL_PARSE_FAILED_NO_CERTIFICATES">INSTALL_PARSE_FAILED_NO_CERTIFICATES</a>]</span></p>
<p></font></span>
<p>or perhaps this:</p>
<p><span style="font-family: consolas;font-size: small">Failure [<a href="http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android/4.0.1_r1/android/content/pm/PackageManager.java#PackageManager.0INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES">INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES</a>]</span></p>
<p>Searching the Internet will tell you that during the package manager’s verification process it couldn’t verify your package was suitably signed – perhaps because the certificate was in error, or maybe because you are using JDK 7 and haven’t worked out how to work with it’s set of new default values that affect harmonious Android development (I’ve written about this issue as it cropped up in <a href="http://blong.com/Articles/OxygeneGoogleMaps/GoogleMaps4.htm#SignAppJDK7">this article</a>).</p>
<p>Sometimes a small change in the application, like updating the package name or altering the signing process (i.e. changing the package’s signature), will mean an application can’t be <em>re</em>-installed over a previous version.</p>
<p><span style="font-family: consolas;font-size: small">Failure [<a href="http://grepcode.com/file/repository.grepcode.com/java/ext/com.google.android/android/4.0.1_r1/android/content/pm/PackageManager.java#PackageManager.0INSTALL_FAILED_UPDATE_INCOMPATIBLE">INSTALL_FAILED_UPDATE_INCOMPATIBLE</a>]</span></p>
<p>You can easily deal with this by forcibly uninstalling the prior version, again using adb. If your app’s package is called <span style="font-family: consolas;font-size: small">org.me.myapp</span> and is on a physical device, you’d use:</p>
<p><span style="font-family: consolas;font-size: small">adb –d uninstall org.me.myapp</span></p>
<p>Change the <span style="font-family: consolas;font-size: small">-d</span> switch to a <span style="font-family: consolas;font-size: small">-e</span> if using an emulator instead.</p>
<p>I’ve been quite surprised how many times rather annoying issues have been deftly resolved by simply restarting the adb daemon, or uninstalling an old version of an app that was ‘getting in the way’ of a new version being installable.</p>
<p>One other point to mention before ending is that DDMS is a great log viewing tool, but it acts as a debugger. If you have it running and then try to launch an application for debugging from Oxygene for Java, you won’t get very far as DDMS will already have set itself up as the primary debugger. To debug, you must first close DDMS, which isn’t a great loss – the Oxygene debugger does have a <a href="http://developer.android.com/guide/developing/tools/adb.html#logcat">logcat</a> window that shows the same logging information as DDMS does.</p>
<div class="blogger-post-footer"><img /></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.blong.com/feeds/8425478500003000038/comments/default</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Accessing Android’s Google Map control in Oxygene for Java</title>
		<link>http://blogs.remobjects.com/blogs/brian-long/2012/01/18/p3805</link>
		<comments>http://blogs.remobjects.com/blogs/brian-long/2012/01/18/p3805#comments</comments>
		<pubDate>Wed, 18 Jan 2012 01:02:00 +0000</pubDate>
		<dc:creator>Brian Long</dc:creator>
				<category><![CDATA[Guest Post]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?guid=b7561085035341e6c66d7cb756ddcdb7</guid>
		<description><![CDATA[When I was working out how to use the Google Map control on Android devices i found it a little daunting with all the information scattered around the web, often missing out crucial points and almost never mentioning the impact that Java 7 has on thing...]]></description>
			<content:encoded><![CDATA[<p>When I was working out how to use the Google Map control on Android devices i found it a little daunting with all the information scattered around the web, often missing out crucial points and almost never mentioning the impact that Java 7 has on things….</p>
<p>So I thought it best to write all my findings up in a detailed article on the matter from the viewpoint of an Oxygene for Java developer – it turned out to be much longer than I was expecting! You can find the article on my web site as <em><a href="http://blong.com/Articles/OxygeneGoogleMaps/GoogleMaps.htm">Using the Google MapView in Android with Oxygene for Java</a></em>.</p>
<p>I hope you find it useful – it represents quite a long time spent researching and fiddling and testing things out!</p>
<div class="blogger-post-footer"><img /></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.blong.com/feeds/9057326624988418211/comments/default</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Android events in Oxygene for Java</title>
		<link>http://blogs.remobjects.com/blogs/brian-long/2012/01/14/p3799</link>
		<comments>http://blogs.remobjects.com/blogs/brian-long/2012/01/14/p3799#comments</comments>
		<pubDate>Fri, 13 Jan 2012 23:19:00 +0000</pubDate>
		<dc:creator>Brian Long</dc:creator>
				<category><![CDATA[Guest Post]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?guid=19cbe30b1bcae497f65d98b37de63f9a</guid>
		<description><![CDATA[When I first started looking at the Android SDK I quickly realised that events were set up differently to the frameworks I had worked with before. Instead of being defined as closures, or method pointers, event fields are defined using interface types....]]></description>
			<content:encoded><![CDATA[<p>When I first started looking at the <a href="http://developer.android.com/reference/packages.html">Android SDK</a> I quickly realised that events were set up differently to the frameworks I had worked with before. Instead of being defined as closures, or method pointers, event fields are defined using interface types. To handle an event you need to implement the interface in some class.</p>
<p>In Java this is done using some syntactic sugar that gets the compiler to implement the interface in an anonymous helper class. When working with <a href="http://www.remobjects.com/oxygene/">the Oxygene language</a> we also need this syntactic sugar to avoid degenerating into a mess of unwieldy code, hence the introduction of <em>inline interface implementation</em>.</p>
<p>There are various ways of using inline interface implementation and a couple of other options for implementing events, so I’ve written up a short article illustrating the primary options available for those using <a href="http://www.remobjects.com/oxygene/java">Oxygene for Java</a> called <em>Android event handling &amp; inline interface implementation with Oxygene for Java</em>. If interested in following up on this, you can find the article <a href="http://blong.com/Articles/OxygeneInlineInterfaces/InlineInterfaceImplementation.htm">here on my web site</a>.</p>
<div class="blogger-post-footer"><img /></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.blong.com/feeds/6772614636980258990/comments/default</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Android Market app built in Oxygene for Java</title>
		<link>http://blogs.remobjects.com/blogs/brian-long/2012/01/11/p3775</link>
		<comments>http://blogs.remobjects.com/blogs/brian-long/2012/01/11/p3775#comments</comments>
		<pubDate>Wed, 11 Jan 2012 16:48:00 +0000</pubDate>
		<dc:creator>Brian Long</dc:creator>
				<category><![CDATA[Guest Post]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?guid=afa3989f4887381bfdfd74ebd21f2970</guid>
		<description><![CDATA[In Autumn 2011 I was approached by Nail Soup Ltd. about an Android development opportunity. Nail Soup had a client, a charitable organisation called Amber Foundation, who wanted some mobile applications built. Primarily they wanted to offer a free iPho...]]></description>
			<content:encoded><![CDATA[<p>In Autumn 2011 I was approached by <a href="http://nailsoup.doodlekit.com/home">Nail Soup Ltd.</a> about an Android development opportunity. Nail Soup had a client, a charitable organisation called <a href="http://amberweb.org/">Amber Foundation</a>, who wanted some mobile applications built. Primarily they wanted to offer a free iPhone and Android app that would allow people to search for various types of resources to help homeless people in the UK. This was to be called the Amber Homeless Helper and was set to be released shortly before Christmas 2011.</p>
<p align="center"><a href="http://lh3.ggpht.com/-4VWCQokcAWY/Tw2uk3wigoI/AAAAAAAAA1c/IRPxac4FVuM/s1600-h/AmberApp_Splash%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="AmberApp_Splash" src="http://lh3.ggpht.com/-TF5gbiZXW_E/Tw2ulxoiVfI/AAAAAAAAA1k/YdaOWuzHLnE/AmberApp_Splash_thumb.png?imgmax=800" width="164" height="244"></a></p>
<p>The idea was to have a web-resident database sat behind a web service that could be queried with various different search criteria to get resources around a specified location. Nail Soup were happily building the web service, a web front end and also the iPhone app, and they asked me to build the equivalent Android application. Since at the time it was very close to the release of <a href="http://www.remobjects.com/oxygene/java">Oxygene for Java</a> I chose that as the development tool for the job.</p>
<p>The app was completed and published for the target release date of 19th December 2011 and the iPhone and Android versions are in the <a href="http://itunes.apple.com/gb/app/amber-homeless-helper/id477429748">Apple App Store</a> and the <a href="https://market.android.com/details?id=org.amberweb.amberhh">Android Market</a> respectively, though they are only visible to people in the UK since they are providing UK-specific resources.</p>
<p align="center"><a href="http://lh3.ggpht.com/-RFHJJ671E3o/Tw2uoccI9xI/AAAAAAAAA1s/QsSn0cbhpPk/s1600-h/Market_1%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="Market_1" src="http://lh6.ggpht.com/-nRNsPo8eHn4/Tw2upHYcVUI/AAAAAAAAA10/2F6JLj-GD_Y/Market_1_thumb.png?imgmax=800" width="148" height="244"></a>&nbsp; <a href="http://lh6.ggpht.com/-GsObk17JCiA/Tw2usCZ4q_I/AAAAAAAAA18/i917AUEQazI/s1600-h/Market_1b%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="Market_1b" src="http://lh6.ggpht.com/-Lmt9NDnX2fM/Tw2usy7VDxI/AAAAAAAAA2E/p5kn0KGaGLc/Market_1b_thumb.png?imgmax=800" width="148" height="244"></a>&nbsp; <a href="http://lh4.ggpht.com/-f57VyakFyLM/Tw2uumCQfFI/AAAAAAAAA2M/2-ro625j0-Y/s1600-h/Market_2%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="Market_2" src="http://lh6.ggpht.com/-ddf0sxo65Mk/Tw2uvfy3Y0I/AAAAAAAAA2Q/KecRotTUiIE/Market_2_thumb.png?imgmax=800" width="148" height="244"></a></p>
<p>Amber Homeless Helper is the first published app built with Oxygene for Java and was fun to do. It’s not the most complex application, primarily being a search tool with some additional information and the ability to contact Amber and donate to the charity, as well as look at previous archived search results but involved a number of technically interesting aspects of Android development. Additionally it acted as a good test of the initial 1.0 release of Oxygene for Java finding a couple of rough edges that were quickly addressed by the developers at <a href="http://www.remobjects.com/">RemObjects</a>.</p>
<p>This post is intended to give an overview of what areas of Android programming were involved in getting the Amber Homeless Helper to its finished state, operating as the design dictated.</p>
<p> <a></a>
<p align="center"><a href="http://lh6.ggpht.com/-OqV0q55n2uI/Tw2uwtHWGsI/AAAAAAAAA2c/t_TuY9I3mSk/s1600-h/AmberApp_Home%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="AmberApp_Home" src="http://lh4.ggpht.com/-p2WKSvncSsw/Tw2uxXMdW0I/AAAAAAAAA2k/D7i4_UzkViU/AmberApp_Home_thumb.png?imgmax=800" width="148" height="244"></a></p>
<p align="left">On start-up you can immediately see a couple of things about the app, even if we ignore the splash screen (shown at the top of this blog post). Firstly, it uses a tab widget to allow the five main screens (aka activities) to be selected. This is quite straightforward to set up in the main activity layout and main activity class.</p>
<p align="left">Secondly, it departs from the typical default Android colour schemes of white on black (or black on white) and uses colours more associated with Amber Foundation. This required using a custom application theme in a theme.xml file and some custom styles in a styles.xml file applied. In fact, just to check I could achieve it (and this wasn’t in the specification) I built in the custom colour scheme in a manner that allowed me to turn it on and off by selecting or deselecting the custom theme.</p>
<p align="left">It turned out this was mostly very straightforward. The slightly sticky part involved the tabs. In the colourful version of the app these are custom-drawn to allow the gradient backgrounds to be achieved and to round off the tab corners. In the original version of the app they are the stock tab widget. So some conditions were added into the main activity to differentiate between a custom theme or the default theme, which itself was identified using the value of a custom attribute (defined in an attrs.xml file) used in one of the styles. Other than that the theming is automatic.</p>
<p align="left">Another thing evident on start-up is the application icon being inserted into the status bar. This is a nice little touch achieved by calling:</p>
<p align="left"><font size="3"><font face="Consolas">requestWindowFeature(Window.FEATURE_LEFT_ICON);</font></font></p>
<p align="left">before loading up the activity layout and then afterwards calling:</p>
<p align="left"><font size="3"><font face="Consolas">FeatureDrawableResource[Window.FEATURE_LEFT_ICON] := <font color="#2b91af">R</font>.<font color="#2b91af">drawable</font>.amber_app_icon;</font></font></p>
<p align="left">Clicking the information buttons on the home page brings up typical Android dialog style views, achieved by applying the Theme.Dialog theme to the activity that displays the explanatory text.</p>
<p align="center"><a href="http://lh6.ggpht.com/-R6s8ukRtZO4/Tw2uzanD_LI/AAAAAAAAA2s/uu8LEPEMEhg/s1600-h/AmberApp_About%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="AmberApp_About" src="http://lh4.ggpht.com/-WExzyhHGAiw/Tw2u0SABzDI/AAAAAAAAA20/skicGKQtqgk/AmberApp_About_thumb.png?imgmax=800" width="148" height="244"></a></p>
<p>The <em>Search</em> page is the main focus of the application. It’s where most of the functionality is invoked from and set up for.</p>
<p align="center"><a href="http://lh3.ggpht.com/-hU_CulTOIvM/Tw2u1oOXXSI/AAAAAAAAA28/wFo_pLZIgnQ/s1600-h/AmberApp_Search%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="AmberApp_Search" src="http://lh4.ggpht.com/-EY37PEgJ_Nc/Tw2u2YdxnRI/AAAAAAAAA3E/La2JU5III0U/AmberApp_Search_thumb.png?imgmax=800" width="148" height="244"></a></p>
<p>The available service categories are not hard-coded. On first run they are sucked in from the web-resident database via a web service call and stored in a local SQLite database. When the app starts up a custom <span style="font-family: consolas;font-size: small">Application</span> object starts the ball rolling by checking if the categories in the remote database are more up to date than what we have locally. If so, it queries the database to get the new categories and records when they were updated.</p>
<p>By this time the user may already have gone to the search screen so to communicate the new information over the custom <span style="font-family: consolas;font-size: small">Application</span> object broadcasts a custom <span style="font-family: consolas;font-size: small">Intent</span>. The search page has a broadcast receiver registered in case such an <span style="font-family: consolas;font-size: small">Intent</span> comes along so it can update the service category list onscreen.</p>
<p>The web service is SOAP-based so I used <a href="http://sourceforge.net/projects/ksoap2/">kSOAP2</a> to communicate with it. This was straightforward: just a case of referencing the kSOAP2 .jar file and then calling the relevant methods. Additionally, to ensure the UI experience wasn’t affected by the Internet communication all web service calls were set up to operate asynchronously in secondary threads.</p>
<p>When searching for resources in the app you can either enter a location and search within a specified radius, or use your current location. To support searching on the current location there’s code running in the background trying to identify where you are as soon as the <em>Search</em> page shows up, using either the coarse network cell-based location and/or GPS-based location identification. It continues to search, in an attempt to refine the location or keep track of where you are if you are moving, until you leave the <em>Search</em> page &#8211; as soon as the <em>Search</em> page is switched from in one way or another this location detection is disabled.</p>
<p>When you initiate a search with one of the search buttons your search criteria are collected: category, radius, location and optional additional advanced criteria. These are sent off to the web service to get some results.</p>
<p>The search results are available in two forms: a map and a list.</p>
<p align="center"><a href="http://lh3.ggpht.com/-86AjyEMgTWU/Tw2u71tWhNI/AAAAAAAAA3M/IA_HyVjLQmg/s1600-h/AmberApp_Search_Results_Map2%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="AmberApp_Search_Results_Map2" src="http://lh6.ggpht.com/-4fiKtOonvx4/Tw2u89F1kGI/AAAAAAAAA3U/7vXtqU5JcZA/AmberApp_Search_Results_Map2_thumb.png?imgmax=800" width="148" height="244"></a>&nbsp; <a href="http://lh4.ggpht.com/-5FarNW9XUfA/Tw2u-iDk51I/AAAAAAAAA3c/WGP78jEBajY/s1600-h/AmberApp_Search_Results_List2%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="AmberApp_Search_Results_List2" src="http://lh5.ggpht.com/-Fc4GllsNhyc/Tw2u_RriLwI/AAAAAAAAA3k/3dtrjYrkz6s/AmberApp_Search_Results_List2_thumb.png?imgmax=800" width="148" height="244"></a></p>
<p>The red pins indicate matches on the sought categories, and the purple pins show other resources that may additionally be useful.</p>
<p>The map is implemented using Google&#8217;s <span style="font-family: consolas;font-size: small"><a href="http://code.google.com/android/add-ons/google-apis/reference/com/google/android/maps/MapView.html">MapView</a></span> control. However this control is not part of the Android SDK – it’s part of an add-on library that you need to pull down with the Android SDK Manager. You also need to add it to your project, specify you’re using it in your Android manifest file and take other steps to have it work at all. It requires you to have an API key, which you get from a <a href="http://code.google.com/android/maps-api-signup.html">Google web page</a> after plugging in the MD5 fingerprint of the certificate used to sign your application.</p>
<p>Even if you don’t explicitly provide a certificate to sign your app with, it will still be signed using a debug certificate created when you first build with the SDK. But if your goal is to publish to the Android Market you may as well create a specific certificate, sign the app with that and use it to create the map API key. This API key needs to be given to the <span style="font-family: consolas;font-size: small">MapView</span> control, either specified as an attribute in the layout file or passed as a constructor parameter.</p>
<p>If this all sounds rather convoluted and complicated that would be because it <em>is</em> rather convoluted and complicated. It’s a shame Google wanted to keep the map controls out of the open Android OS, but I’ll write more later on the technical specifics of using these map controls with Oxygene for Java.</p>
<p>The problems with maps don’t end there. When programming for iPhone and iPad with iOS the <a href="http://developer.apple.com/library/ios/#documentation/MapKit/Reference/MKMapView_Class/MKMapView/MKMapView.html">map control</a> there has lots of pre-packaged functionality, including support for adding markers to the map that can be clicked on, yielding a nice balloon box with a title and text in and so forth. On Android we don’t get such niceties all ‘in the box.’ Apparently the iOS functionality was put together back in the days when Google and Apple were close allies and good working partners, before the days of Android. So iOS benefitted from the Google expertise, but for some apparently inexplicable reason, Google didn’t ensure their own map offerings for the Android platform matched in capability and richness.</p>
<p>The Amber app does achieve this popup balloon effect, however:</p>
<p align="center"><a href="http://lh5.ggpht.com/-8lnO_s0t-KM/Tw2vDzWkSMI/AAAAAAAAA3s/btqA8vNwWUE/s1600-h/AmberApp_Search_Results_Map_Selection2%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="AmberApp_Search_Results_Map_Selection2" src="http://lh4.ggpht.com/-krZOQ7UQbM8/Tw2vFLh2bhI/AAAAAAAAA30/8D6PFzt0D5Y/AmberApp_Search_Results_Map_Selection2_thumb.png?imgmax=800" width="148" height="244"></a></p>
<p>But it requires some work to do. Indeed a little search turned up <a href="https://github.com/jgilfelt/android-mapviewballoons#readme">an implementation of these map balloon views</a> already done for Android users, so I made use of that work.</p>
<p>The map also has the search radius displayed as a circle on the map, so that involves another map overlay which I coded up and added to the map view.</p>
<p>Tapping the balloon view opens another activity that displays the full details of the selected service:</p>
<p align="center"><a href="http://lh5.ggpht.com/-FA6UOlKHwog/Tw2vGezm_gI/AAAAAAAAA38/YjxfN1Z882U/s1600-h/AmberApp_Service_Details2%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="AmberApp_Service_Details2" src="http://lh4.ggpht.com/-rb7JRzO_H1g/Tw2vHMUqk3I/AAAAAAAAA4E/NVzkb0wmQfs/AmberApp_Service_Details2_thumb.png?imgmax=800" width="148" height="244"></a></p>
<p>Buttons on this page will dial the service provider telephone number and open its web site. Buttons on the <em>Donate</em> and <em>Contact</em> pages support donation through SMS and communicating with Amber via email. While it is quite feasible to have the Amber app actually send an SMS or display a web page or send an email or dial a telephone number, there are also good reasons why the app chooses to not directly do this. Instead it makes use of the inbuilt SMS app, web browser, email app and telephone dialler.</p>
<p>These jobs were delegated for a couple of reasons. Firstly any Android system already has all the required functionality in pre-supplied applications and it’s very common to mix and match bits of the Android system into an application to avoid reinventing the wheel. But perhaps more importantly if the app was coded to, for example, directly send an SMS using the <span style="font-family: consolas;font-size: small">SmsManager</span> class then it would need <span style="font-family: consolas;font-size: small">SEND_SMS</span> added to the app’s list of required permissions.</p>
<p>If the app was coded to directly dial a number it would need <span style="font-family: consolas;font-size: small">CALL_PHONE</span> added to the permissions list. When someone looked at the app on the Android market they would see the app requires these permissions and might choose to wonder how legitimately the application behaved with regards to text messages and phone calls and maybe choose to not install it. Delegating to the inbuilt apps, which get launched with the basic information filled in, removes those permission requirements and still ensures the user is in control as they can discard the SMS before it is sent, or close the telephone dialler before the call is made.</p>
<p>The other tabbed page not mentioned so far is the <em>Archive</em> page. This displays the list of previous searches made, whose results have been stored locally in the SQLite database. When an archived search is chosen the app checks to see if Internet connectivity exists. If it does then the results are displayed on the map page, otherwise the results list page is displayed. Archived searches can be deleted either individually or en masse through a separate screen (invoked through a menu item).</p>
<p align="center"><a href="http://lh6.ggpht.com/-iE1qxfmE9rE/Tw2vIotOl9I/AAAAAAAAA4M/comri_jLYyI/s1600-h/AmberApp_Archive%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="AmberApp_Archive" src="http://lh4.ggpht.com/-4tDwFa64tes/Tw2vJB0mkNI/AAAAAAAAA4U/ZIf4NmcfHrc/AmberApp_Archive_thumb.png?imgmax=800" width="148" height="244"></a>&nbsp; <a href="http://lh3.ggpht.com/-yMBIQiEXmDo/Tw2vKmAf2wI/AAAAAAAAA4c/xIte5s2HO54/s1600-h/AmberApp_Archive_Delete%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="AmberApp_Archive_Delete" src="http://lh4.ggpht.com/-tShTvCTjt9o/Tw2vLIK2LNI/AAAAAAAAA4g/sQJyzeTztIw/AmberApp_Archive_Delete_thumb.png?imgmax=800" width="148" height="244"></a></p>
<p>All in all, the majority of the work in the app deals with reading and writing various bits of data from and to the database, and making the asynchronous calls to the web service. Various proxy objects are used to represent the search results and the list of found services that are returned to make things more manageable.</p>
<p>Since Amber Homeless Helper’s release it has got some press coverage:</p>
<ul>
<li><a href="http://www.guardian.co.uk/society/2011/dec/20/society-daily-email">The Guardian’s Social pages</a> on 20th December, 2011:<br /><a href="http://lh6.ggpht.com/-g1Tb3Rd83J4/Tw2vLmr-keI/AAAAAAAAA4o/eiKdw5GyC3E/s1600-h/TheGuardian-20111220%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="TheGuardian-20111220" src="http://lh6.ggpht.com/-NEqRretgxFk/Tw2vMUoTQJI/AAAAAAAAA4w/bbBdm3lFMS4/TheGuardian-20111220_thumb.png?imgmax=800" width="244" height="83"></a>
<li>The Wiltshire Times on 23rd December, 2011:<br /><a href="http://lh3.ggpht.com/-jDJbR_2EVWk/Tw2vRMF9n8I/AAAAAAAAA48/j-WMgTdMkgM/s1600-h/Wiltshire%252520Times%25252020111223%25255B2%25255D.png"><img style="border-right-width: 0px;margin: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="Wiltshire Times 20111223" src="http://lh5.ggpht.com/-sT4jToqgVdI/Tw2vSSG-E0I/AAAAAAAAA5E/kXo_5xSp28c/Wiltshire%252520Times%25252020111223_thumb.png?imgmax=800" width="198" height="244"></a>
<li><a href="http://www.wscountytimes.co.uk/news/local/homelessness_app_launched_1_3360152">The West Sussex County Times</a> on 30th December, 2011:<br /><a href="http://lh5.ggpht.com/-6zBrzOtr-bo/Tw2vTix9BlI/AAAAAAAAA5M/04RvJFDDpkE/s1600-h/WestSussexCountyTimes-20111230%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="WestSussexCountyTimes-20111230" src="http://lh3.ggpht.com/-l5ouzlkAcpQ/Tw2vUSZomsI/AAAAAAAAA5Q/YAlWffDAF2I/WestSussexCountyTimes-20111230_thumb.png?imgmax=800" width="197" height="244"></a>
<li><a href="http://www.thisissurreytoday.co.uk/Phone-app-help-homeless/story-14279007-detail/story.html">This is Surrey Today</a> on 30th December, 2011:<br /><a href="http://lh5.ggpht.com/-YtrH-3jQ90M/Tw2vVAdjqXI/AAAAAAAAA5Y/xRlXcBh2tss/s1600-h/ThisIsSurreyToday-20111230%25255B2%25255D.png"><img style="border-right-width: 0px;padding-left: 0px;padding-right: 0px;border-top-width: 0px;border-bottom-width: 0px;border-left-width: 0px;padding-top: 0px" border="0" alt="ThisIsSurreyToday-20111230" src="http://lh5.ggpht.com/-0WcyYfPhYV4/Tw2vVnRtiGI/AAAAAAAAA5k/InwOC2MuvCg/ThisIsSurreyToday-20111230_thumb.png?imgmax=800" width="244" height="183"></a></li>
</ul>
<p>The app took a couple of weeks to build (albeit with my previous experience of the Android SDK and how Android applications work in general) and we spent a couple more weeks&nbsp; testing it out and tweaking things and fixing bits, but it was a pleasingly short development cycle. I’ve found that Oxygene for Java makes an ideal tool for the Delphi developer to jump into the Android development world.</p>
<p>You can find the Amber Homeless Helper, if you’re UK-based in the <a href="http://itunes.apple.com/gb/app/amber-homeless-helper/id477429748">Apple App Store</a> here and in the <a href="https://market.android.com/details?id=org.amberweb.amberhh">Android Market here</a>.</p>
<div class="blogger-post-footer"><img /></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.blong.com/feeds/8461370774159426764/comments/default</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Oxygene for Java introductory Android article available</title>
		<link>http://blogs.remobjects.com/blogs/brian-long/2012/01/04/p3738</link>
		<comments>http://blogs.remobjects.com/blogs/brian-long/2012/01/04/p3738#comments</comments>
		<pubDate>Wed, 04 Jan 2012 18:21:00 +0000</pubDate>
		<dc:creator>Brian Long</dc:creator>
				<category><![CDATA[Guest Post]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?guid=43137e4526001dc1625ef4d1d3c4f913</guid>
		<description><![CDATA[Over the holiday period i spent some time knocking up an introductory article that looks at getting Oxygene for Java set up for Android development, looking at an overview of how Android apps work and how an Android project is laid out, and getting a s...]]></description>
			<content:encoded><![CDATA[<p>Over the holiday period i spent some time knocking up an introductory article that looks at getting Oxygene for Java set up for Android development, looking at an overview of how Android apps work and how an Android project is laid out, and getting a simple app up and running on an Android device or emulator.</p>
<p>You can find the article on <a href="http://blong.com" >my web site</a> at <a href="http://blong.com/Articles/OxygeneForJavaIntro/OxygeneForAndroid.htm" >http://blong.com/Articles/OxygeneForJavaIntro/OxygeneForAndroid.htm</a>.</p>
<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1853768304794693097-6443430787894341393?l=blog.blong.com' alt='' /></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.blong.com/feeds/6443430787894341393/comments/default</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Oxygene by Example &#8211; Command line parsing</title>
		<link>http://blogs.remobjects.com/blogs/ck/2011/12/23/p3682</link>
		<comments>http://blogs.remobjects.com/blogs/ck/2011/12/23/p3682#comments</comments>
		<pubDate>Fri, 23 Dec 2011 14:22:23 +0000</pubDate>
		<dc:creator>Carlo Kok</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Cooper]]></category>
		<category><![CDATA[Mono]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>
		<category><![CDATA[Uncategorized]]></category>
		<category><![CDATA[Wiki]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?p=3682</guid>
		<description><![CDATA[This is second article in my blog post series &#8220;Oxygene by Example&#8221;. While working with command line arguments in Prism is quite simple, the &#8220;Main&#8221; method has an array of string that holds the value, it can become quite complex when having to parse options too. When having to work with those, it&#8217;s easiest to [...]]]></description>
			<content:encoded><![CDATA[<p>This is second article in my blog post series &#8220;Oxygene by Example&#8221;.</p>
<p>While working with command line arguments in Prism is quite simple, the &#8220;Main&#8221; method has an array of string that holds the value, it can become quite complex when having to parse options too. When having to work with those, it&#8217;s easiest to use the <a href="http://code.remobjects.com/p/ndeskoptionspas/">NDesk for Oxygene</a> file. It&#8217;s a single file that can be added to any project (no need for a separate dll library). It was originally written in C# by Jonathan Pryor, we ported it to Oxygene so it can be embedded in an Oxygene project too.</p>
<p>The first step is to add NDesk.Options to the uses list, this is where the classes are defined. A general console application entry point looks like:</p>

<div class="wp_syntax"><div class="code"><pre class="oxygene" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">class</span> <span style="color: #000000; font-weight: bold;">method</span> ConsoleApp<span style="color: #000066;">.</span><span style="color: #000000;">Main</span><span style="color: #000066;">&#40;</span>arguments<span style="color: #000066;">:</span> <span style="color: #000000; font-weight: bold;">array</span> <span style="color: #000000; font-weight: bold;">of</span> String<span style="color: #000066;">&#41;</span><span style="color: #000066;">:</span> Integer<span style="color: #000066;">;</span>
<span style="color: #000000; font-weight: bold;">begin</span>
  <span style="color: #000000; font-weight: bold;">var</span> lSourceUri<span style="color: #000066;">:</span> String<span style="color: #000066;">;</span>
  <span style="color: #000000; font-weight: bold;">var</span> lDestinationUri<span style="color: #000066;">:</span> String<span style="color: #000066;">;</span>
  <span style="color: #000000; font-weight: bold;">var</span> lSomeOption<span style="color: #000066;">:</span> Boolean<span style="color: #000066;">;</span>
  <span style="color: #000000; font-weight: bold;">var</span> lShowHelp<span style="color: #000066;">:</span> Boolean<span style="color: #000066;">;</span>
  <span style="color: #000000; font-weight: bold;">var</span> lOptionSet <span style="color: #000066;">:</span><span style="color: #000066;">=</span> <span style="color: #000000; font-weight: bold;">new</span> OptionSet<span style="color: #000066;">&#40;</span><span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span> 
  <span style="color: #000000; font-weight: bold;">var</span> lFiles<span style="color: #000066;">:</span> <span style="color: #000000; font-weight: bold;">sequence</span> <span style="color: #000000; font-weight: bold;">of</span> String<span style="color: #000066;">;</span>
&nbsp;
  lOptionSet<span style="color: #000066;">.</span><span style="color: #000000; font-weight: bold;">Add</span><span style="color: #000066;">&#40;</span>&quot;s|source<span style="color: #000066;">=</span>&quot;<span style="color: #000066;">,</span> &quot;<span style="color: #808080; font-style: italic;">{filename or url}</span> <span style="color: #000000; font-weight: bold;">of</span> source object&quot;<span style="color: #000066;">,</span> v <span style="color: #000066;">-</span>&gt; <span style="color: #000000; font-weight: bold;">begin</span> lSourceUri <span style="color: #000066;">:</span><span style="color: #000066;">=</span> v <span style="color: #000000; font-weight: bold;">end</span> <span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
  lOptionSet<span style="color: #000066;">.</span><span style="color: #000000; font-weight: bold;">Add</span><span style="color: #000066;">&#40;</span>&quot;d|destination<span style="color: #000066;">=</span>&quot;<span style="color: #000066;">,</span> &quot;<span style="color: #808080; font-style: italic;">{filename or url}</span> <span style="color: #000000; font-weight: bold;">of</span> destination object&quot;<span style="color: #000066;">,</span> v <span style="color: #000066;">-</span>&gt; <span style="color: #000000; font-weight: bold;">begin</span> lDestinationUri <span style="color: #000066;">:</span><span style="color: #000066;">=</span> v <span style="color: #000000; font-weight: bold;">end</span> <span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
  lOptionSet<span style="color: #000066;">.</span><span style="color: #000000; font-weight: bold;">Add</span><span style="color: #000066;">&#40;</span>&quot;o|someoption&quot;<span style="color: #000066;">,</span> &quot;some binary option&quot;<span style="color: #000066;">,</span> v <span style="color: #000066;">-</span>&gt; <span style="color: #000000; font-weight: bold;">begin</span> lSomeOption <span style="color: #000066;">:</span><span style="color: #000066;">=</span> <span style="color: #000066;">assigned</span><span style="color: #000066;">&#40;</span>v<span style="color: #000066;">&#41;</span> <span style="color: #000000; font-weight: bold;">end</span> <span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
  lOptionSet<span style="color: #000066;">.</span><span style="color: #000000; font-weight: bold;">Add</span><span style="color: #000066;">&#40;</span>&quot;h|?&quot;<span style="color: #000066;">,</span> &quot;show help&quot;<span style="color: #000066;">,</span> v <span style="color: #000066;">-</span>&gt; <span style="color: #000000; font-weight: bold;">begin</span> lShowHelp <span style="color: #000066;">:</span><span style="color: #000066;">=</span> <span style="color: #000066;">assigned</span><span style="color: #000066;">&#40;</span>v<span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span> <span style="color: #000000; font-weight: bold;">end</span> <span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
  <span style="color: #000000; font-weight: bold;">try</span>
    lFiles <span style="color: #000066;">:</span><span style="color: #000066;">=</span> lOptionSet<span style="color: #000066;">.</span><span style="color: #000000;">Parse</span><span style="color: #000066;">&#40;</span>arguments<span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
  <span style="color: #000000; font-weight: bold;">except</span>
    <span style="color: #000000; font-weight: bold;">on</span>  Exception  <span style="color: #000000; font-weight: bold;">do</span>
      lShowHelp <span style="color: #000066;">:</span><span style="color: #000066;">=</span> <span style="color: #000000; font-weight: bold;">true</span><span style="color: #000066;">;</span>
  <span style="color: #000000; font-weight: bold;">end</span><span style="color: #000066;">;</span>
  <span style="color: #000000; font-weight: bold;">if</span>  <span style="color: #000066;">&#40;</span>lShowHelp<span style="color: #000066;">&#41;</span>  <span style="color: #000000; font-weight: bold;">then</span> <span style="color: #000000; font-weight: bold;">begin</span>
    lOptionSet<span style="color: #000066;">.</span><span style="color: #000000;">WriteOptionDescriptions</span><span style="color: #000066;">&#40;</span>Console<span style="color: #000066;">.</span><span style="color: #000000; font-weight: bold;">Out</span><span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
    <span style="color: #000000; font-weight: bold;">exit</span> <span style="color: #0000ff;">1</span><span style="color: #000066;">;</span>
  <span style="color: #000000; font-weight: bold;">end</span> <span style="color: #000000; font-weight: bold;">else</span>  <span style="color: #000000; font-weight: bold;">begin</span>
    Console<span style="color: #000066;">.</span><span style="color: #000000;">WriteLine</span><span style="color: #000066;">&#40;</span><span style="color: #ff0000;">'Options supplied:'</span><span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
    Console<span style="color: #000066;">.</span><span style="color: #000000;">WriteLine</span><span style="color: #000066;">&#40;</span><span style="color: #ff0000;">'Source: '</span> <span style="color: #000066;">+</span> lSourceUri<span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
    Console<span style="color: #000066;">.</span><span style="color: #000000;">WriteLine</span><span style="color: #000066;">&#40;</span><span style="color: #ff0000;">'Destination: '</span> <span style="color: #000066;">+</span> lDestinationUri<span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
    Console<span style="color: #000066;">.</span><span style="color: #000000;">WriteLine</span><span style="color: #000066;">&#40;</span><span style="color: #ff0000;">'Some option: '</span> <span style="color: #000066;">+</span> iif<span style="color: #000066;">&#40;</span>lSomeOption<span style="color: #000066;">,</span><span style="color: #ff0000;">'ON'</span><span style="color: #000066;">,</span><span style="color: #ff0000;">'OFF'</span><span style="color: #000066;">&#41;</span><span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
    <span style="color: #000000; font-weight: bold;">for</span> <span style="color: #000000; font-weight: bold;">each</span> el <span style="color: #000000; font-weight: bold;">in</span> lFiles <span style="color: #000000; font-weight: bold;">do</span> Console<span style="color: #000066;">.</span><span style="color: #000000;">WriteLine</span><span style="color: #000066;">&#40;</span><span style="color: #ff0000;">'Argument: '</span><span style="color: #000066;">+</span>el<span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
  <span style="color: #000000; font-weight: bold;">end</span><span style="color: #000066;">;</span>
  Console<span style="color: #000066;">.</span><span style="color: #000000;">ReadLine</span><span style="color: #000066;">&#40;</span><span style="color: #000066;">&#41;</span><span style="color: #000066;">;</span>
<span style="color: #000000; font-weight: bold;">end</span><span style="color: #000066;">;</span></pre></div></div>

<p>The OptionSet class is the main class for the options parser, first you have to define the different options by using the &#8220;Add&#8221; method. The first parameter defines what option it maps to. in &#8220;s|source=&#8221;, there are two bindings for this option, &#8220;s&#8221; and &#8220;source&#8221;, the | just separates them. The &#8220;=&#8221; is used to denote that the option takes a parameter. &#8220;s&#8221; is a single letter option, to use it one can use &#8220;MyApp -ssourcefile.text&#8221;, or &#8220;MyApp &#8211;source sourcefile.text&#8221;, the short options do not have a space, and a single dash, the long options have a space and two dashes.</p>
<p>The second parameter for Add is the description, when writing out the option list it will print this (see below), the last parameter is a delegate that gets called when it&#8217;s triggered. This delegate (in the cases above we use <a href="http://wiki.oxygenelanguage.com/en/Anonymous_Methods_and_Delegates">anonymous methods</a>) has one parameter with the value passed. From these anonymous methods we set the options we define in the variables above it, that way we can read them later on. </p>
<p>The last step is <b>lOptionSet.Parse(arguments)</b>, this will return a list of &#8220;rest&#8221; parameters, anything that&#8217;s not an option (or parameter to an option) will be in this list. It will raise an exception when there&#8217;s an error parsing arguments. We set the lShowHelp to true in this case, so we can later write the options to the console with <b>WriteOptionDescriptions</b>.</p>
<p>Using the Ndesk.Options classes makes parsing parameters a lot easier than doing it manually.  The OptionSet classes have a lot more features, all of which are documented at the top of the source file <a href="http://code.remobjects.com/p/ndeskoptionspas/source/tree/HEAD/trunk/NDesk.Options.Prism/Options.pas">Options.pas</a>.</p>
<p>The original version of this article can be found in our <a href="http://wiki.oxygenelanguage.com/en/Oxygene_by_Example_-_Commandline">wiki</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.remobjects.com/blogs/ck/2011/12/23/p3682/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Oxygene for Java takes Delphi programmers to the Java and Android platforms</title>
		<link>http://blogs.remobjects.com/blogs/brian-long/2011/12/17/p3739</link>
		<comments>http://blogs.remobjects.com/blogs/brian-long/2011/12/17/p3739#comments</comments>
		<pubDate>Sat, 17 Dec 2011 16:36:00 +0000</pubDate>
		<dc:creator>Brian Long</dc:creator>
				<category><![CDATA[Guest Post]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?guid=bec19e0b696b29a7d7623dcc1db0da8b</guid>
		<description><![CDATA[At the end of November 2011, RemObjects released Oxygene for Java, previously known as Project “Cooper” as per this official blog post and, for that matter, the press release. Anyone familiar with Delphi Prism, which is RemObjects’ .NET compiler ...]]></description>
			<content:encoded><![CDATA[<p>At the end of November 2011, <a href="http://www.remobjects.com/" >RemObjects</a> released <a href="http://www.remobjects.com/oxygene/java" >Oxygene for Java</a>, previously known as Project “Cooper” as per this <a href="http://blogs.remobjects.com/blogs/mh/2011/11/30/p3525" >official blog post</a> and, for that matter, the <a href="http://www.prweb.com/releases/2011/11/prweb8997975.htm" >press release</a>.</p>
<p>Anyone familiar with <a href="http://www.embarcadero.com/products/prism" >Delphi Prism</a>, which is RemObjects’ .NET compiler (also known as <a href="http://www.remobjects.com/oxygene/" >Oxygene for .NET</a>) will know it is a high-performance compiler with some lovely enhancements to Object Pascal and support for all features of its target platform, .NET.</p>
<p>Oxygene for Java is the same compiler, the <a href="http://blog.blong.com/2011/09/oxygene-5.html" >same language</a>, but targeting the Java platform. This allows you to build:</p>
<ul>
<li>cross-platform applications running on the Java Virtual Machine (as per the trivial <a href="http://blog.blong.com/2011/06/project-cooper-mandelbrot-set.html" >Mandelbrot example</a> I blogged about before)
<li>Java applets (some applets I built in Oxygene based on some online examples can be seen at <a href="http://blong.com/Test/OxygeneApplets.html" >this test page</a>)
<li>Tomcat servlets, as discussed by Sebastian Gingter in <a href="http://blogs.remobjects.com/blogs/sebastiang/2011/12/15/p3522" >this blog post</a>
<li>probably most interestingly, Android apps. Oxygene for Java supports a full tool chain for taking Java compiled classes and making them digestible to Android’s Dalvik Virtual machine
<li>pretty much any other Java-based utility</li>
</ul>
<p>In the middle of November I popped over to Antwerp, Belgium to deliver the launch presentation for Oxygene for Java at <a href="http://be-delphi.com/" >Be Delphi 2011</a>. There are some pictures from the day’s sessions <a href="http://be-delphi.com/photos.php" >here</a>, including a couple from my presentation that have the tell-tale Oxygene logo on the screen.</p>
<p align="center"><img src="http://be-delphi.com/img/event/be6.jpg" width="540"></p>
<p align="center"><img src="http://be-delphi.com/img/event/be8.jpg" width="540"></p>
<p align="center"><img src="http://be-delphi.com/img/event/be9.jpg" width="540"></p>
<p align="center"><img src="http://be-delphi.com/img/event/be11.jpg" width="540"></p>
<p>Be Delphi was a great inaugural day-long conference from a new Belgium-based Delphi community.</p>
<p>Since that launch presentation (and after a couple of other small jobs) I’ve spent a couple of weeks working on an Android project for a client, writing it in Oxygene for Java. More on that in another post.</p>
<p>I’m hoping to be making plenty of noise about this product over coming months in various forms, but until the next post, just note that Oxygene for Java is now available at <a href="http://www.remobjects.com/shop/#oxygene" >the RemObjects store</a>.</p>
<div class="blogger-post-footer"><img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/1853768304794693097-173685154559211028?l=blog.blong.com' alt='' /></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.blong.com/feeds/173685154559211028/comments/default</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Announcing the Oxygene 5.0.31 release, and Oxygene for Java</title>
		<link>http://blogs.remobjects.com/blogs/mh/2011/11/30/p3525</link>
		<comments>http://blogs.remobjects.com/blogs/mh/2011/11/30/p3525#comments</comments>
		<pubDate>Wed, 30 Nov 2011 13:14:53 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Cooper]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Platforms]]></category>
		<category><![CDATA[Prism]]></category>
		<category><![CDATA[RemObjects]]></category>
		<category><![CDATA[Visual Studio]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?p=3525</guid>
		<description><![CDATA[Today we are proud to announce the release and immediate availability of Oxygene 5.0.31, introducing our brand new second platform edition of the Oxygene language: Oxygene for Java. This release marks the culmination of more than a year of work from the Oxygene team, and is, I believe, one of the most important milestones the [...]]]></description>
			<content:encoded><![CDATA[<p>Today we are proud to announce the release and immediate availability of Oxygene 5.0.31, introducing our brand new second platform edition of the Oxygene language: Oxygene for Java.</p>
<p>This release marks the culmination of more than a year of work from the Oxygene team, and is, I believe, one of the most important milestones the product has seen so far.</p>
<p>So, what&#8217;s new in 5.0.31?</p>
<h2>Oxygene for Java</h2>
<p>The main new feature in this release is, of course, our new support for the Java runtime environment. Oxygene for Java is a separate product and not part of the existing &#8220;Oxygene for .NET&#8221; (a.k.a. Embarcadero Prism) SKU, but it is built on the same code base and, in fact, shares the exact same binaries with its older sibling.</p>
<p>But what is Oxygene for Java, exactly?</p>
<p>Oxygene for Java is the same Oxygene language and IDE experience that you already know and love on the .NET platform – for Java. It is literally the same compiler, and all the language features are the same (there are a few <em>very</em> minor differences owed to the underlying platform, but these are so minor, even I don&#8217;t remember what they are ;).</p>
<p>Just like Oxygene for .NET directly consumes the .NET assemblies and the .NET framework (and third party) classes, Oxygene for Java directly consumes java .JAR files and gives you direct access to the standard Java class hierarchy and any first and third party libraries out there. Just like Oxygene for .NET generates 100% native .NET assemblies, Oxygene for Java generates 100% native .JAR files indistinguishable (expect by their awesomeness from all the cool language features you can use on the inside) from those created using the Java Language.</p>
<p>Oxygene for Java shares the same IDE experience as Oxygene for .NET. It integrates with Visual Studio (for now; we&#8217;re also looking at integrating (both editions) into more traditional Java IDEs, such as Eclipse), along with all our advanced features such as the Smart Editing capabilities, advanced inline error reporting, etc. and all the standard Visual Studio infrastructure, from project templates to Solution Explorer. If you are familiar with working on .NET projects in Visual Studio, you already know how to work with Oxygene for Java projects, as well.</p>
<p>Oxygene for Java also includes a full-fledged Java debugger integrated into the Visual Studio IDE. Use the Visual Studio debugger infrastructure to launch or attach to Java and Android applications, leverage watches, view stack traces, switch between threads, choose what Java exceptions to break on, step from Oxygene for Java into Java Language code. All your expertise debugging .NET applications in VS will apply right to debugging Oxygene for Java projects.</p>
<p>Finally, Oxygene for Java integrates the full Android deployment tool chain into the Visual Studio IDE. Just press Run, and your project not only gets compiled, it also gets post-processed for Android, packed into an .apk, and sent right to the emulator or your attached Android device, ready to be debugged and tested.</p>
<p>And this is just the beginning. Moving forward Oxygene for Java and Oxygene for .NET will evolve side-by-side, gaining new language features and other enhancements at the same time.</p>
<p>Oxygene for Java is available at <a href="http://www.remobjects.com/shop/#oxygene">remobjects.com/shop</a> now, for only $399. Or get the bundle with Oxygene for .NET, at only $599.</p>
<h2>Is that all?</h2>
<p>No, of course that&#8217;s not all. Oxygene 5.0.31 also includes a large set of fixes and improvements for existing users of the .NET compiler, as well as a handful of minor new features (despite officially being a &#8220;bug-fix only&#8221; release, on the .NET side:</p>
<p><strong>Experimental Support for the Visual Studio 11 Developer Preview</strong> has been added, letting you try out Oxygene in the next version of Microsoft&#8217;s IDE. This does not include new features for Metro/WinRT and .NET 4.5 yet (we&#8217;re working on those, but are not quite ready to ship them in an official release), but the core Oxygene features should be usable (both .NET and Java).</p>
<p>Oxidizer has been expanded with <strong>support for importing and pasting Java Language Code</strong> (in both product editions), in addition to the existing options for legacy code Delphi and C#. Although it is most useful for Oxygene for Java users (just like Importing C# is mostly useful for .NET users), this can be helpful when wanting to use generic/algorithmic Java code in an Oxygene project, as well.</p>
<p>Finally, a lot of work has been done to <strong>improve IDE Performance</strong> throughout the product, and all project templates have been updated to enable the <strong>&#8220;Warn on case mismatch&#8221; turned on by default</strong>, as we think that&#8217;s a good practice, and more Oxygene users should be exposed to that feature by default.</p>
<h2>Enjoy</h2>
<p>So, that&#8217;s Oxygene 5.0.31. We&#8217;re very excited about this release (and about where we will take the Java platform and Oxygene in general over the next year or so), and I hope you are too. We&#8217;re only getting started.</p>
<p>I think this is a great time to be an Oxygene developer</p>
<p>Yours,<br />
marc</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.remobjects.com/blogs/mh/2011/11/30/p3525/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Prism / Oxygene for .NET &#8220;October 2011&#8243; Update, New Betas, and More!</title>
		<link>http://blogs.remobjects.com/blogs/mh/2011/10/29/p3455</link>
		<comments>http://blogs.remobjects.com/blogs/mh/2011/10/29/p3455#comments</comments>
		<pubDate>Sat, 29 Oct 2011 20:56:17 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Cooper]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[non-tech]]></category>
		<category><![CDATA[Oxygene]]></category>
		<category><![CDATA[Prism]]></category>
		<category><![CDATA[ROFX]]></category>
		<category><![CDATA[Visual Studio]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?p=3455</guid>
		<description><![CDATA[As promised, yesterday we shipped our second monthly update to Embarcadero Prism XE2, a.k.a. Oxygene for .NET 5. The new release is available for all Oxygene users from the Licensed Downloads Page on our customer portal. It will also be available directly from Embarcadero, soon. As mentioned before, if you bought Prism XE2 from a [...]]]></description>
			<content:encoded><![CDATA[<p>As promised, yesterday we shipped our second monthly update to Embarcadero Prism XE2, a.k.a. Oxygene for .NET 5.</p>
<p>The new release is available for all Oxygene users from the <a href="https://secure.remobjects.com/portal/downloads/">Licensed Downloads Page</a> on our customer portal. It will also be available directly from Embarcadero, soon. As mentioned before, if you bought Prism XE2 from a different reseller, directly from Embarcadero, or received it as part of RAD Studio XE2, you can go ahead and <a href="https://secure.remobjects.com/portal/serials/registerserial">register your serial number with us</a>, two get access to the download, betas, and more.</p>
<p>Build 5.0.29.931 marks the third release of Oxygene 5.0.29, and is the last update before we consolidate the code bases and ship Oxygene for Java, (Code-named &#8220;Cooper&#8221;), at the end of next month.</p>
<h2>Oxygene Betas</h2>
<p>In addition to the new &#8220;master&#8221; release, we also shipped new beta builds of &#8220;Cooper&#8221; (Oxygene for Java) and &#8220;Echoes&#8221; (Oxygene for . NET), based on the common code base that we are preparing to ship next month. The Betas for Cooper and Echoes will be synced moving forward, both for the initial release and afterwards, as the two editions of the Oxygene language will advance together, now.</p>
<p>You can find out more about these beta programs on our new <a href="http://connect.remobjects">RemObjects Connect</a> support forums, in particular at <a href="http://connect.remobjects.com/categories/cooper-beta">connect.remobjects.com/categories/cooper-beta</a> and <a href="http://connect.remobjects.com/categories/echoes-beta">connect.remobjects.com/categories/echoes-beta</a> (login needed). Anyone with a &#8220;Cooper&#8221; pre-order or a license of Prism XE2 registered with us has access to the betas, and we encourage you to check them out!</p>
<h2>ROFX Betas</h2>
<p>To round things off, we also shipped new beta builds of our <a href="http://www.remobjects.com/da">Data Abstract</a> and <a href="http://www.remobjects.com/ro">RemObjects SDK</a> products, for all three platforms; highlights include enhancements to the JavaScript client (shipping next month) and domain import/export in Relativity Server.</p>
<p>Find out more about that at <a href="http://connect.remobjects.com/categories/rofx-beta">connect.remobjects.com/categories/rofx-beta</a>.</p>
<p>As with Oxygene again, any customer with an active subscription has access to the ROFX betas.</p>
<h2>RemObjects SDK for Java</h2>
<p>Finally, we&#8217;re also putting the finishing touches on the first beta drop for <a href="http://www.remobjects.com/ro/java">RemObjects SDK for Java</a>, code-named &#8220;White Lodge&#8221;,and expect the beta to become available next week. If you talked to us about beta access before, expect to see email form us soon with details; of course you can also always <a href="http://shop.remobjects.com">pre-order</a> our Java editions, for example when renewing your existing products – as many have already done. All pre-orders of course include full beta access.</p>
<p>&nbsp;</p>
<p>As you can see, the year is far from over, and there&#8217;s still lots of good stuff ahead. See you on the beta forums!</p>
<p>marc</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.remobjects.com/blogs/mh/2011/10/29/p3455/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>RemObjects SDK and Data Abstract for JavaScript</title>
		<link>http://blogs.remobjects.com/blogs/mh/2011/10/07/p3340</link>
		<comments>http://blogs.remobjects.com/blogs/mh/2011/10/07/p3340#comments</comments>
		<pubDate>Fri, 07 Oct 2011 17:20:11 +0000</pubDate>
		<dc:creator>marc</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Delphi]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[Prism]]></category>
		<category><![CDATA[ROFX]]></category>
		<category><![CDATA[Visual Studio]]></category>
		<category><![CDATA[Xcode]]></category>

		<guid isPermaLink="false">http://blogs.remobjects.com/?p=3340</guid>
		<description><![CDATA[Today we are shipping the first beta builds of RemObjects SDK and Data Abstract with our new JavaScript client support. This beta is available at beta.remobjects.com for all users with an active subscription, and we are planning to ship this feature officially in the upcoming Winter release next month. This blog post aims at giving [...]]]></description>
			<content:encoded><![CDATA[<p>Today we are shipping the first beta builds of RemObjects SDK and Data Abstract with our new JavaScript client support. This beta is available at <a href="http://beta.remobjects.com">beta.remobjects.com</a> for all users with an active subscription, and we are planning to ship this feature officially in the upcoming Winter release next month.</p>
<p>This blog post aims at giving you a quick overview into what&#8217;s there and how to use it.</p>
<p><strong>RemObjects SDK and Data Abstract for JavaScript</strong> is essentially the fourth client platform for RO/DA that we have implemented, and constitutes a fully native JavaScript implementation of our RO/DA client library – with everything you need to talk to RO or DA servers directly from JavaScript-based clients. The main focus right now is on web clients (i.e. clients running locally in a browser), but RODA/JS should also be usable from any other JavaScript based platform, such as Windows 8&#8242;s Metro, <em>cough</em> WebOS <em>cough</em>, and the like.</p>
<p>RODA/JS is not a separate product; rather, it ships in the box with all three of our existing server platforms: RODA/.NET, RODA/Delphi and Relativity Server.</p>
<p>In most cases, you will want to add the ability to expose a scripting client right from inside the regular RO/DA server you are building, and we have created components that make this really easy: Both RODA/.NET and RODA/Delphi have gained (TRO)JavaScriptHttpDispatcher and (TDA)JavaScriptHttpDispatcher components that you can simply drop into your project and hook up to your server channels. These components embed and automatically serve the core RODA/JS script files, and can also serve any custom files (scripts and HTML/CSS/Images) that you created to implement your JavaScript client (from a folder or from resources embedded in your server app).</p>
<p>With that done, you can simply point your browser to a subpath of your server&#8217;s URL, such as http://localhost:8099/js to access your web app.</p>
<p><center><img src="http://blogs.remobjects.com/wp-content/uploads/2011/10/RO-MegaDemo-Delphi2.png" alt="TROJavaScriptHttpDispatcher in Delphi" /></center></p>
<p>The screenshot above shows the RO/Delphi MegaDemo, but a similar component is available for DA and on .NET, and all MegaDemos and DA Sample Servers have been extended to already expose sample JavaScript clients.</p>
<p>If you run the server and point your browser to it, it will look something like this (not about to win any design awards, but it works ;) ).</p>
<p><center><img src="http://blogs.remobjects.com/wp-content/uploads/2011/10/ROMegaDemo-JavaScript.png" alt="MegaDemo JavaScript Client in Action" /></center></p>
<p>What does the source look like? Aside from the HTML that defines what we see, there are three script files included:</p>
<pre><code>&lt;script type="text/javascript" src="RemObjectsSDK.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="MegaDemoLibrary_intf.js"&gt;&lt;/script&gt;
&lt;script type="text/javascript" src="script.js"&gt;&lt;/script&gt;
</code></pre>
<p>The first is the core RO/JS library – automatically served by the JavaScriptHttpDispatcher component. The second is the Interface file for our server&#8217;s RODL – more on that below. Lastly, scripts.js contains the code we custom-wrote to implement our client. Let&#8217;s look at that in more detail:</p>
<p>First, we create our service and related components (I&#8217;m shortening the code a bit for the purpose of this post, if you look at the real sample, you&#8217;ll see it will optionally choose between JSON and BinMessage, etc):</p>
<pre><code>var Service;
createService();
function createService()
{
    var svcUrl = "http://" + document.location.host + "/bin";
    Service = new MegaDemoService(new RemObjects.SDK.HTTPClientChannel(svcUrl),
    new RemObjects.SDK.BinMessage());
}
</code></pre>
<p>Next, let&#8217;s look at how we call Sum():</p>
<pre><code>function BeginSumMethod()
{
    var A = document.getElementById("editA").value;
    var B = document.getElementById("editB").value;
    Service.Sum(A, B,
                    function SuccessSumMethod(result)
                    {
                        AddLineToLog('Result is ' + result);
                    },
                    function ErrorSumMethod(msg, ex)
                    {
                        if (ex) {
                            AddLineToLog(" Error: " + ex);
                    } else {
                        AddLineToLog(msg.getErrorMessage());
                    });
}
</code></pre>
<p>As you see, JavaScript is big on asynchronicity. Instead of calling Sum() and getting back a value, Sum runs asynchronously, and we provide a callback that gets executed when the result was received (and a second callback that gets called for any errors or exceptions).</p>
<p>To generate Interface files for your custom RODLs (such as MegaDemoLibrary_intf.js in the sample above), both Service Builder (Windows) and rodl2objc (Mac) have been expanded with an extra option to generate .js files. Simply open your RODL and save the Intf.js, as you already know how to do for all the other languages we support:</p>
<p><center><img src="http://blogs.remobjects.com/wp-content/uploads/2011/10/rodl2objc-JavaScript.png" alt="rodl2code with JS" /></center></p>
<p>(As you can see, rodl2objc has also received a bit of an interface facelift ;) )</p>
<p>That&#8217;s RemObjects SDK for JavaScript, for talking to custom Web Services. Next, let&#8217;s look at <strong>Data Abstract</strong>.</p>
<p>Like with RO, making a DA server accessible from JavaScript is as easy as adding the dispatcher and (optionally) some custom script or HTML files. Here&#8217;s what the JavaScript sample for our PCTrade Sample Servers looks like (both for .NET and Delphi):</p>
<p><center><img src="http://blogs.remobjects.com/wp-content/uploads/2011/10/DA-Sample-JavaScript1.png" alt="PCTrade Sample for JavaScript" /></center></p>
<p>On the left, there&#8217;s list of all the tables, dynamically created by looking at the schema; once a table is selected, it shows a grid on the right. For this sample, we&#8217;re using a jQuery grid, but there&#8217;s nothing that inherently ties Data Abstract to jQuery or any other JavaScript framework – you get access to the raw data via a table object and can work with it any way you please. Of course, we cannot only show data, but also maintain updates and apply them back to the server.</p>
<p>Let&#8217;s look at the code again:</p>
<pre><code>&lt;script src="RemObjectsSDK.js" type="text/javascript"&gt;&lt;/script&gt;
&lt;script src="DataAbstract.js" type="text/javascript"&gt;&lt;/script&gt;
&lt;script src="DataAbstract4_Intf.js" type="text/javascript"&gt;&lt;/script&gt;
&lt;script src="/js/jquery/jquery-1.4.4.js" type="text/javascript"&gt;&lt;/script&gt;
&lt;script src="/js/jquery/js/grid.locale-en.js" type="text/javascript"&gt;&lt;/script&gt;
&lt;script src="/js/jquery/js/jquery.jqGrid.min.js" type="text/javascript"&gt;&lt;/script&gt;
&lt;script src="DataAbstractjQGrid.js" type="text/javascript"&gt;&lt;/script&gt;
</code></pre>
<p>In addition to the core three RO/DA files (all of which are served by default by Data Abstract&#8217;s version of the JavaScriptHttpDispatcher), we include a few jQuery files, as well as a DA-specific helper file for jQGrid that we provide for your convenience. Once again, using jQGrid is just an implementation choice for this sample (much like using QuantumGrid would be for a Delphi app).</p>
<p>Other than that, all the application-specific script in this sample is in the main HTML file.</p>
<p>For example, here is how we set up the RemoteDataAdapter:</p>
<pre><code>var Channel = new RemObjects.SDK.HTTPClientChannel("http://" + window.location.host + "/JSON");
var Message = new RemObjects.SDK.JSONMessage();
var Service = new RemObjects.SDK.RemoteService(Channel, Message, "DASampleService");
var daService = new DataAbstractService(Service);
var loginService = new RemObjects.SDK.RemoteService(Channel, Message, "LoginService");
var rda = new RemObjects.DataAbstract.RemoteDataAdapter(Service, loginService, RemObjects.DataAbstract.Bin2DataStreamer);
</code></pre>
<p>And here is how we fetch data for a table (and show it using the jQGrid helper):</p>
<pre><code>rda.getData(Tables[CurrentTable], function() {
                GridView = new RemObjects.DataAbstract
                    .Views.JQGridView(Tables[CurrentTable], "#list", "#pager");
            },
        function(msg, e) {
            if (e) {alert(e)}
            else alert(msg.getErrorMessage());
        });
</code></pre>
<p>If you&#8217;re familiar with RO and DA, you will already see that the classes are very similar to what you know. We have client channels, messages, remote services and a remote data adapter.</p>
<p><strong>Relativity Server</strong> now also optionally exposes the required JavaScript files (including full Intf.js files for its admin API) as well as a JSON message. All you need to do to activate this is to check the <em>Enable JavaScript Publishing</em> option in Server Explorer:</p>
<p><center><img src="http://blogs.remobjects.com/wp-content/uploads/2011/10/DASMx-JavaScript-Option1.png" alt="Server Explorer for Mac" /></center></p>
<p>If the option is grayed out, your Relativity Server does not support JavaScript yet; if the option is not available, you need a newer version of Server Explorer for Mac.</p>
<h2>A Word about Cross-Domain Data Access</h2>
<p>You might be asking: why does the JavaScript need to be served by the RO/DA server? Can&#8217;t I just put it on my website? Technically, you could, but there&#8217;s a limitation on most browsers that – for security reasons – won&#8217;t just let JavaScript connect to different servers willy-nilly. So if you&#8217;re opening a website from http://mywebsite.com, the browser won&#8217;t let the JavaScript on that site send requests to http://database.mywebsite.com:8099 – unless at least some of the scripts originate from that server. So you <em>can</em> embed JavaScript code in your website and have it talk to your RO/DA server on a different domain or port, but you must at least reference the RemObjectsSDK.js and/or DataAbstract.js files from the RO/DA server to let the browser know that it&#8217;s ok to connect there.</p>
<p>This limitation might not apply when using JavaScript on other non-web platforms, for example on Metro (we haven&#8217;t tested that yet) or application platforms such as Titanium. It&#8217;s a limitation of what the browser lets you do, not a limitation of our client library.</p>
<h2>Summary</h2>
<p>Our new native JavaScript client libraries open up RO and DA servers to a wide variety of new client platforms, with rich browser-based apps only being one of many possibilities.</p>
<p>We have a good six weeks of beta cycle left before this feature ships, and we hope you&#8217;ll give the beta builds a try and let us know any feedback you have. Head over to <a href="http://beta.remobjects.com">beta.remobjects.com</a> now to get started.</p>
<p>Enjoy!</p>
]]></content:encoded>
			<wfw:commentRss>http://blogs.remobjects.com/blogs/mh/2011/10/07/p3340/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

