<?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>I.T. aware &#187; Eclipse</title>
	<atom:link href="http://www.itaware.eu/category/anglais/eclipse/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.itaware.eu</link>
	<description>Sébastien Letélié and Cyril Balit weblog</description>
	<lastBuildDate>Wed, 20 Feb 2013 07:34:02 +0000</lastBuildDate>
	<language>fr-FR</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.4.2</generator>
<atom:link rel="hub" href="http://pubsubhubbub.appspot.com"/><atom:link rel="hub" href="http://superfeedr.com/hubbub"/>		<item>
		<title>Java BarCamp Paris 4th ed. : Cloud and DDD</title>
		<link>http://www.itaware.eu/2009/04/05/java-barcamp-paris-4th-ed-cloud-and-ddd/</link>
		<comments>http://www.itaware.eu/2009/04/05/java-barcamp-paris-4th-ed-cloud-and-ddd/#comments</comments>
		<pubDate>Sun, 05 Apr 2009 19:20:31 +0000</pubDate>
		<dc:creator>Sébastien Letélié</dc:creator>
				<category><![CDATA[Anglais]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[cloud-computing]]></category>
		<category><![CDATA[ddd]]></category>
		<category><![CDATA[qi4j]]></category>

		<guid isPermaLink="false">http://www.itaware.eu/?p=463</guid>
		<description><![CDATA[A big success! It was full of people in the great Google's office. 2 schedules / 4 rooms and a total of 7 sessions, I present the both where I participated : Cloud computing (definition, actors and amazon eclipse tool) and DDD (definition and qi4j) <a href="http://www.itaware.eu/2009/04/05/java-barcamp-paris-4th-ed-cloud-and-ddd/" target="_blank">[...]</a>]]></description>
			<content:encoded><![CDATA[<p>A big success! It was full of people in the great Google&rsquo;s office. 2 schedules / 4 rooms and a total of 7 sessions, I present the both where I participated :</p>
<p><strong>Cloud computing </strong><br />
Not really a Java subject but it attract people. We tried to define the cloud computing and we fixed that there is 3 offers :</p>
<ul>
<li><strong>IAAS</strong> (Infrastructure as a Service): this is typical <a href="http://aws.amazon.com/" target="_blank">Amazon services</a> products, S3 for storage and EC2 for virtualized servers. Amazon offer very basic service now with a very powerful management tool in <a href="http://aws.amazon.com/eclipse/" target="_blank">Eclipse plug-in</a> (see the <a href="http://awsmedia.s3.amazonaws.com/videos/awsToolkit.html" target="_blank">demo</a>). There is also <a href="http://www.elastic-grid.com/" target="_blank">Elastic Grid</a> proposing to develop and deploy easily on the Amazon infrastructure, <a href="http://www.gogrid.com/index.php" target="_blank">GoGrid</a> an Amazon concurrent. I believe that the recent IBM / Sun merge will create new offerings.</li>
<li> <strong>SAAS</strong> (Software as a Service): we find a lot of solutions (often based on the previous offer), for example Amazon <a href="http://aws.amazon.com/simpledb/" target="_blank">SimpleDB</a>, Amazon <a href="http://aws.amazon.com/sqs/" target="_blank">SQS</a>, <a href="http://www.google.com/a" target="_blank">Google Apps</a>, Microsoft <a href="http://www.microsoft.com/azure/" target="_blank">Azure</a> Services <a href="http://www.cloudmq.com/" target="_blank">CloudMQ</a>, <a href="http://www.zumodrive.com/" target="_blank">ZumoDrive</a> &#8230; and I could continue like a long time&#8230;</li>
<li><strong>PAAS</strong> (Platform as a Service): is hosting the application on a common and scalable platform, it is typically <a href="http://appengine.google.com/" target="_blank">Google AppEngine</a>, it is possible to deploy all yours web application if you know Python. Microsoft probably has a deal in Azure (I should have a look) and Sun has just launched <a href="http://zembly.com/" target="_blank">Zembly</a>.</li>
</ul>
<p>A lot of discussion on what about offline, security, and where is java in the cloud. For me offline mode is really important in a world of increasingly nomad people. Cloud is primarily storage space allowing me to share my data between my devices, then an area of services, and finally deployment platform of my apps.<br />
Finished managing a backup that is never done, losed time finding  a way to share data and finally used USB key, now my data are in the cloud and synchronized on all my devices. I have set up Zumodrive in my company and it&rsquo;s very cool, the documents are shared even outside the company and I don&rsquo;t care about backup.<br />
Security is the most bigger difficulty for acceptance in the company, I hear the same remarks when talking about the payment on Internet ten years ago. All these services are secure and there is no zero risk.<br />
Java have his place in the cloud on client and server side. The multi platform aspect facilitates the developments on the client (eg: ZumoDrive client is in Java), I want to see more and more Java APIs &laquo;&nbsp;cloud-ready&nbsp;&raquo; facilitating the integration of service in code. Similarly on the server side I look forward to Google AppEngine in Java.<br />
Finally the advantage of cloud computing is primarily economic, smalls company are the first customers and have found lower cost and flexible capabilities.</p>
<p><strong>DDD (<a href="http://domaindrivendesign.org/" target="_blank">Domain Driven Design</a>)</strong><br />
I had little success at the last barcamp with this subject, this time it was proposed by others much more stronger than me and have made relevant arguments on the benefits of the concept. One of the important point raised we used talking too much technical and framework implementation than focus more on the reality, something that we tend to forget wanting to put our new framework in our code. I talked about <a href="http://www.qi4j.org/" target="_blank">Qi4j</a>, that is not pure DDD implementation, but is for me the best way to modelling reality. I want make a demo of my medical record implemented with Qi4j to really prove that this approach is relevant.<br />
Of course I&rsquo;m convinced that a DDD refactoring of an existing code is difficult. DDD is a best practice and a new way of development vision. Have to follow for sure &#8230;</p>
<p>Thank you again to the organizers. It is always a good opportunity to exchange. And i hope Google will open their doors as often as possible;)</p>
]]></content:encoded>
			<wfw:commentRss>http://www.itaware.eu/2009/04/05/java-barcamp-paris-4th-ed-cloud-and-ddd/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Server-side OSGi, is it really useful ?</title>
		<link>http://www.itaware.eu/2008/10/19/server-side-osgi-is-it-really-useful/</link>
		<comments>http://www.itaware.eu/2008/10/19/server-side-osgi-is-it-really-useful/#comments</comments>
		<pubDate>Sun, 19 Oct 2008 10:19:08 +0000</pubDate>
		<dc:creator>Sébastien Letélié</dc:creator>
				<category><![CDATA[Anglais]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[SOA]]></category>
		<category><![CDATA[jsr 277]]></category>
		<category><![CDATA[modular approach]]></category>
		<category><![CDATA[osgi]]></category>
		<category><![CDATA[solstice]]></category>

		<guid isPermaLink="false">http://www.itaware.eu/?p=327</guid>
		<description><![CDATA[<img class="alignleft size-full wp-image-323" title="puzzle" src="http://www.itaware.eu/wp-content/uploads/2008/10/puzzle.jpg" alt="" width="150" height="112" /> The recent <a href="http://www.parisjug.org/xwiki/bin/view/Main/WebHome" target="_blank">Paris JUG</a> was an opportunity to talk about <a href="http://www.osgi.org/" target="_blank">OSGi</a> technology, already mentioned <a href="http://www.itaware.eu/2008/01/26/news-on-osgi/" target="_blank">several</a> <a href="http://www.itaware.eu/2007/02/20/osgi-demo/" target="_blank">times</a> in this blog, and continues to hear about it. Although OSGi is present on the client side with Eclipse, the development of the server side and especially in Java EE environment sometimes leaves developers not convinced. Spring Source (<a href="http://www.springsource.com/products/suite/dmserver" target="_blank">Spring DM server</a>), ObjectWeb (<a href="http://wiki.jonas.objectweb.org/xwiki/bin/view/Main/WebHome" target="_blank">JOnAS</a>), Sun (<a href="https://glassfish.dev.java.net/" target="_blank">Glassfish</a>) and IBM (<a href="http://publib.boulder.ibm.com/infocenter/ieduasst/v1r1m0/index.jsp?topic=/com.ibm.iea.was_v6/was/6.1/Architecture/WASv61_Componentization/player.html" target="_blank">WebSphere 6.1</a>) have clearly made the choice. What are the real benefits for our applications on server side? <a href="http://www.itaware.eu/2008/10/19/server-side-osgi-is-it-really-useful/">[...]</a>]]></description>
			<content:encoded><![CDATA[<p><img class="alignleft size-full wp-image-323" title="puzzle" src="http://www.itaware.eu/wp-content/uploads/2008/10/puzzle.jpg" alt="" width="150" height="112" /> The recent <a href="http://www.parisjug.org/xwiki/bin/view/Main/WebHome" target="_blank">Paris JUG</a> was an opportunity to talk about <a href="http://www.osgi.org/" target="_blank">OSGi</a> technology, already mentioned <a href="http://www.itaware.eu/2008/01/26/news-on-osgi/" target="_blank">several</a> <a href="http://www.itaware.eu/2007/02/20/osgi-demo/" target="_blank">times</a> in this blog, and continues to hear about it. Although OSGi is present on the client side with Eclipse, the development of the server side and especially in Java EE environment sometimes leaves developers not convinced. Spring Source (<a href="http://www.springsource.com/products/suite/dmserver" target="_blank">Spring DM server</a>), ObjectWeb (<a href="http://wiki.jonas.objectweb.org/xwiki/bin/view/Main/WebHome" target="_blank">JOnAS</a>), Sun (<a href="https://glassfish.dev.java.net/" target="_blank">Glassfish</a>) and IBM (<a href="http://publib.boulder.ibm.com/infocenter/ieduasst/v1r1m0/index.jsp?topic=/com.ibm.iea.was_v6/was/6.1/Architecture/WASv61_Componentization/player.html" target="_blank">WebSphere 6.1</a>) have clearly made the choice. What are the real benefits for our applications on server side?<br />
First don&rsquo;t forget OSGi is a specification designed for the embedded domain. This make an implementation without the new Java 5 features : annotations, generics, etc &#8230; and that makes us appear OSGi like an old technology. But OSGi stay attractive because what is important above all is the concept: modularization. Concept that on each ear of OOP developer can not be ignored. By development on development we have tried to improve the way we write code, trying to organize it to not create inter-dependencies and go over possible reusability. The arrival of the <a title="Dependency Injection" href="http://en.wikipedia.org/wiki/Dependency_injection" target="_blank">DI</a> pattern help us to do that and the success of Spring is a good example. OSGi creates a continuity in offering us an infrastructure that obliges us to respect the rules and allows us to dynamically manipulate our components. The dynamic aspect and hot deployment is the icing on the cake but this is not what makes OSGi essential on server side, the current deployment technics with clustered servers, or even with the simple <a href="http://developer.apple.com/fr/webobjects/" target="_blank">WebObjects</a> <a href="http://developer.apple.com/documentation/WebObjects/Deployment/Deploying_Applications/Introduction/chapter_1_section_1.html#//apple_ref/doc/uid/TP30000059-TPXREF101" target="_blank">Monitor</a> tool, help us to update applications gracefully. What is interesting it&rsquo;s how the code is organized and the hierarchy throw the management of dependency imposed by OSGi, in application servers and applications themselves.<br />
So in fact this specification is not suited to Java EE and remains technically difficult to understand, but the concept of modularization is a good approach to improve the quality of our developments. That is why Spring focused on because it fits with their framework.<br />
Moreover <a href="http://openjdk.java.net/projects/modules/osgi-support-draft.html" target="_blank">reconciliation</a> between JCP and OSGi promises well, I hope in the right direction, to make the best of 2 worlds, i.e. all existing OSGi in one hand and the server aspect and Java 5 new features for Sun on the other.<br />
However, we must not forget the dynamic aspect because although users are not insist to see a new button dynamically appear at each time thez need a new functionnality, the fact is with OSGi it is technically possible. But is it really an improvement, actually with a web application it is also possible in PHP, in Java (must reload session). For RIA this becomes more complicated because part of the functional is deported on the client side and update requires complete reloading. This is typically what <a href="Chris Brind" target="_blank">Chris Brind</a> has managed to improve by combining Flex and OSGi with <a href="Solstice" target="_blank">Solstice</a>. This framework show the potential of modular approach in this domain.<br />
Again what is important is the concept, the modular approach will bring us more quality in our development and greater flexibility in deployment. Let the community choose the best technology to do it&#8230;</p>
]]></content:encoded>
			<wfw:commentRss>http://www.itaware.eu/2008/10/19/server-side-osgi-is-it-really-useful/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>BIRT DESIGNER-Hide/Show a component</title>
		<link>http://www.itaware.eu/2008/10/01/birt-designer-hideshow-a-component/</link>
		<comments>http://www.itaware.eu/2008/10/01/birt-designer-hideshow-a-component/#comments</comments>
		<pubDate>Wed, 01 Oct 2008 21:48:08 +0000</pubDate>
		<dc:creator>Cyril Balit</dc:creator>
				<category><![CDATA[Anglais]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[birt]]></category>
		<category><![CDATA[birt designer]]></category>

		<guid isPermaLink="false">http://www.itaware.eu/?p=287</guid>
		<description><![CDATA[On a project using BIRT I was confronted with this problem. I generate complex reports using components and datasets defined in a library. I wish to show a component only if the bound dataset contains data. The operation is simple but I looked for the most generic solution. Indeed the component will be used in [...]]]></description>
			<content:encoded><![CDATA[<p>On a project using <a href="http://www.eclipse.org/birt/phoenix/" target="_blank">BIRT</a> I was confronted with this problem. I generate complex reports using components and datasets defined in a library. I wish to show a component only if the bound dataset contains data.<br />
The operation is simple but I looked for the most generic solution. Indeed the component will be used in some reports and the update operations have to be the simplest as possible.<br />
<span id="more-287"></span>First of all it is necessary to distinguish two situations:</p>
<ol>
<li>Dataset that contain only one set of data (characteristics of a customer for example)</li>
<li>Dataset multi-lines (customers list)</li>
</ol>
<p>I used Birt Designer to configure the various elements.</p>
<ol>
<li><strong>Dataset with one record</strong></li>
</ol>
<p>You have to add to the dataset a column which will represents the visible status of the bound component. Edit the dataset properties and create a <strong>computed columns</strong> by clicking on <strong>new </strong></p>
<p><a href="http://www.itaware.eu/wp-content/uploads/2008/09/birt01.bmp"><img class="size-medium wp-image-274 alignnone" title="birt01" src="http://www.itaware.eu/wp-content/uploads/2008/09/birt01.bmp" alt="" /></a></p>
<p>Then you have to set:</p>
<ul>
<li>The name of the column (isVisible for example)</li>
<li>Its type: boolean</li>
</ul>
<p><a href="http://www.itaware.eu/wp-content/uploads/2008/09/birt02.bmp"><img class="aligncenter size-medium wp-image-275" title="birt02" src="http://www.itaware.eu/wp-content/uploads/2008/09/birt02.bmp" alt="" /></a></p>
<p>Then you have to  build the expression allowing to test the other columns:</p>
<ul>
<li>Click on  <strong>fx</strong></li>
<li>Build the expression by testing the wished columns</li>
</ul>
<p><a href="http://www.itaware.eu/wp-content/uploads/2008/09/birt03.bmp"><img class="aligncenter size-medium wp-image-276" title="birt03" src="http://www.itaware.eu/wp-content/uploads/2008/09/birt03.bmp" alt="" /></a><strong></strong></p>
<p>2.<strong> Dataset with multi-lines</strong></p>
<p>First you have to create a computed column with the following attributes:</p>
<p><a href="http://www.itaware.eu/wp-content/uploads/2008/09/birt04.bmp"><img class="aligncenter size-medium wp-image-277" title="birt04" src="http://www.itaware.eu/wp-content/uploads/2008/09/birt04.bmp" alt="" /></a></p>
<ul>
<li>name : length</li>
<li>Data type : integer</li>
<li>Aggregation : <strong>COUNT</strong></li>
</ul>
<p>We create then an &laquo;&nbsp;isVisible&nbsp;&raquo; column which test the value of the column lenght with the following expression : <strong></strong></p>
<p><strong>row ["length"]!=0 </strong></p>
<p><a href="http://www.itaware.eu/wp-content/uploads/2008/09/birt05.bmp"><img class="alignnone size-medium wp-image-278" title="birt05" src="http://www.itaware.eu/wp-content/uploads/2008/09/birt05.bmp" alt="" /></a></p>
<p>3.<strong> Visible status of the component</strong></p>
<p>In the tab <strong>properties </strong>and  in the <strong>visibility </strong>column</p>
<ul>
<li>Select  the &laquo;&nbsp;Hide element &nbsp;&raquo;  checkbox</li>
<li>Set the expression field with the value:<strong> ! Row [" isVisible "] </strong></li>
</ul>
<p><a href="http://www.itaware.eu/wp-content/uploads/2008/09/birt06.bmp"><img class="aligncenter size-medium wp-image-273" title="birt06" src="http://www.itaware.eu/wp-content/uploads/2008/09/birt06.bmp" alt="" /></a><br />
If the return value is true the component is not display in the report.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.itaware.eu/2008/10/01/birt-designer-hideshow-a-component/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		</item>
		<item>
		<title>Asynchronous Web Applications</title>
		<link>http://www.itaware.eu/2008/05/02/asynchronous-web-applications/</link>
		<comments>http://www.itaware.eu/2008/05/02/asynchronous-web-applications/#comments</comments>
		<pubDate>Thu, 01 May 2008 23:00:11 +0000</pubDate>
		<dc:creator>Sébastien Letélié</dc:creator>
				<category><![CDATA[Anglais]]></category>
		<category><![CDATA[Eclipse]]></category>

		<guid isPermaLink="false">http://www.itaware.eu/2008/05/02/asynchronous-web-applications/</guid>
		<description><![CDATA[It is a fact, web applications become asynchronous. AJAX maked end of long response time due to the old practice of response-loop request to load a whole page. Before AJAX this technique was already used with a hidden Applet which accessed to a MOM (Message Oriented Middleware). Do the MOM become itself as the exchange [...]]]></description>
			<content:encoded><![CDATA[<p>It is a fact, web applications become asynchronous. AJAX maked end of long response time due to the old practice of response-loop request to load a whole page. Before AJAX this technique was already used with a hidden Applet which accessed to a MOM (Message Oriented Middleware). Do the MOM become itself as the exchange architecture the most appropriated for web applications ?<br />
<span id="more-169"></span><br />
Currently in a few case it&rsquo;s a response to a need of web applications for managing differents aspects :</p>
<ol>
<li>synchronization (between clients), </li>
<li>response time, </li>
<li>offline, </li>
<li>reliable data. </li>
</ol>
<p>The MOM is used mainly for the first two aspects and least for the next two. Most of time it is a dedicated server where messages are transmitted. If the server go down or the network go down the application show transfer error. This is typically the case in <a href="http://www.adobe.com/products/livecycle/dataservices/">Life Cycle Data Service</a>: the messaging mode lets you synchronize and improve response time, but if the network go down, messages sent by the client are lost. In addition, the application I currently developing, uses Eclipse RCP and embed a Web application that communicates with messaging but with a local queue, make sure of message delivering. The solution is based on IBM <a href="http://www-306.ibm.com/software/integration/wmq/">MQSeries</a> and <a href="http://www.ibm.com/software/integration/wmqe/">MQ Everyplace</a> and implementation is complex but it responds to the 4 aspects.&#160; </p>
<p>Is this the end of HTTP ? This is the disadvantage of asynchronous architecture as the value of HTTP is to pass throw firewalls, using another protocol limit visibility of a web application. To resolve this problem MOM have to use HTTP and this is already done. </p>
<p>Don&rsquo;t forget that this model implies that user is not dependent of response, or most of request are in this case. Hence the need for a local database allowing offline mode. The exchange client / server is then reduced to synchronize database to database. Is this becomes too heavy in terms of deployment and management ? not really because databases are already on board (<a href="http://developers.sun.com/javadb/">Java DB</a> via Java Plugin, <a href="http://www.sqlite.org/">SQLite</a> via <a href="http://gears.google.com/">Google Gears</a>). Yes, but what about the database loading ? Indeed it&rsquo;s necessary to load the database once and it could be long but it depends of the expected need. </p>
<p><a href="http://www.itaware.eu/wp-content/uploads/2008/04/internet-asynchrone.png"><img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="228" alt="internet_asynchrone" src="http://www.itaware.eu/wp-content/uploads/2008/04/internet-asynchrone-thumb.png" width="374" align="right" border="0" /></a></p>
<p>This architecture represented in the diagram cons is surely ideal for certain types of Web applications that require autonomy. It&rsquo;s still difficult to implement because it requires a complicated setup and tools are not intuitive. Eventually this should become completely masked to developers,&#160; using methods send / receive without worrying about the rest. Messaging is a proven technology we just need tool or framework to realize such architecture in a simple way. </p>
]]></content:encoded>
			<wfw:commentRss>http://www.itaware.eu/2008/05/02/asynchronous-web-applications/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Revision control with Mercurial</title>
		<link>http://www.itaware.eu/2007/12/25/revision-control-with-mercurial/</link>
		<comments>http://www.itaware.eu/2007/12/25/revision-control-with-mercurial/#comments</comments>
		<pubDate>Tue, 25 Dec 2007 21:24:27 +0000</pubDate>
		<dc:creator>Sébastien Letélié</dc:creator>
				<category><![CDATA[Anglais]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[General]]></category>

		<guid isPermaLink="false">http://www.itaware.eu/2007/12/25/revision-control-with-mercurial/</guid>
		<description><![CDATA[Mercurial is a distributed revision control system. Instead of centralized system like CVS or Subversion the whole revisions are stored locally and by all developers. A different approach good for work in disconnected mode and to manage backups. An eclipse plugin exist.]]></description>
			<content:encoded><![CDATA[<p><a href="http://en.wikipedia.org/wiki/Mercurial_(software)">Mercurial</a> is a distributed revision control system. Instead of centralized system like CVS or Subversion the whole revisions are stored locally and by all developers. A different approach good for work in disconnected mode and to manage backups. An eclipse plugin <a href="http://www.vectrace.com/mercurialeclipse/">exist</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.itaware.eu/2007/12/25/revision-control-with-mercurial/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Groovy and DSL</title>
		<link>http://www.itaware.eu/2007/12/06/groovy-and-dsl/</link>
		<comments>http://www.itaware.eu/2007/12/06/groovy-and-dsl/#comments</comments>
		<pubDate>Thu, 06 Dec 2007 22:39:53 +0000</pubDate>
		<dc:creator>Sébastien Letélié</dc:creator>
				<category><![CDATA[Anglais]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[Java]]></category>

		<guid isPermaLink="false">http://www.itaware.eu/2007/12/06/groovy-and-dsl/</guid>
		<description><![CDATA[We were lucky receiving Guillaume Laforge at Improve for a Groovy and DSL presentation. I didn&#8217;t have time to really study script languages, i just take a quik look on Scala and Groovy and not on JRuby and Jython. I worried about the capacity of the developers to debug with this languages. I had a [...]]]></description>
			<content:encoded><![CDATA[<p>We were lucky receiving Guillaume Laforge at <a href="http://www.improve.fr">Improve</a> for a <a href="http://groovy.codehaus.org/">Groovy</a> and <a href="http://en.wikipedia.org/wiki/Domain-specific_programming_language">DSL</a> presentation.<br />
I didn&rsquo;t have time to really study script languages, i just take a quik look on <a href="http://www.scala-lang.org/">Scala</a> and Groovy and not on JRuby and Jython. I worried about the capacity of the developers to debug with this languages. I had a lot of problems with Javascript. We were agree with <a href="http://weblogs.java.net/blog/joshy/">Josh Marinacci</a>  in our last <a href="http://www.itaware.eu/2006/11/12/java-dinner-in-prague/">exchange</a> to say that this technology is really interesting but how we can control it. Guillaume put me at rest it&rsquo;s not really a problem, developers don&rsquo;t make really more mistakes than they do in Java, and now IntelliJ have a great plugin which manage debugging, color syntaxing, content assist, refactoring&#8230; The Eclipse plugin haven&rsquo;t it yet but it comes.<br />
It&rsquo;s clear Groovy is a really great tool to realise DSL. The syntax is malleable and readable. His extension capacity with category concept (like in Objective C) or with operators is really great.<br />
I forgot to ask him what&rsquo;s he thinking about JavaFX. The <a href="http://blogs.sun.com/chrisoliver/">Chris Oliver</a>&lsquo;s DSL to create Swing UI is not based on Groovy for <a href="https://openjfx.dev.java.net/JavaFX_FAQ.html#Why_not_Groovy.3F">this reason</a>, is it a good reason ?<br />
For your information Guillaume has created a company <a href="http://www.g2one.com">G2one</a> offering services around Groovy and Grails. The slides he shows us are available on <a href="http://www.grails-exchange.com/">grails-exchange</a>. Guillaume will be at <a href="http://www.javapolis.com/confluence/display/JP07/Guillaume+Laforge">JavaPolis</a>.<br />
Thank&rsquo;s a lot Guillaume and see you soon <img src='http://www.itaware.eu/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.itaware.eu/2007/12/06/groovy-and-dsl/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>RCP with Guice</title>
		<link>http://www.itaware.eu/2007/11/27/rcp-with-guice/</link>
		<comments>http://www.itaware.eu/2007/11/27/rcp-with-guice/#comments</comments>
		<pubDate>Tue, 27 Nov 2007 16:18:17 +0000</pubDate>
		<dc:creator>Sébastien Letélié</dc:creator>
				<category><![CDATA[Anglais]]></category>
		<category><![CDATA[Eclipse]]></category>

		<guid isPermaLink="false">http://www.itaware.eu/2007/11/26/rcp-with-guice/</guid>
		<description><![CDATA[To make my RCP application a little SOA oriented i choose Guice. It&#8217;s easy and quick to implement. To call a service you use : Guice.createInjector().getInstance(aClass); aClass is not a service but an object using injected services, then you can&#8217;t create a ViewPart including service, you must use an intermediate object : a controller. For [...]]]></description>
			<content:encoded><![CDATA[<p>To make my RCP application a little SOA oriented i choose <a href="http://code.google.com/p/google-guice/">Guice</a>. It&rsquo;s easy and quick to implement. To call a service you use :</p>
<pre>
Guice.createInjector().getInstance(aClass);
</pre>
<p><i>aClass</i> is not a service but an object using injected services, then you can&rsquo;t create a ViewPart including service, you must use an intermediate object : a controller.<br />
For example you have a ViewPart (MissionViewPart), a controller (MissionViewController) and a service (MissionService). The declaration look like this :<br />
<span id="more-131"></span><br />
 &#8211; MissionService :</p>
<pre>
@ImplementedBy(MissionServiceImpl.class)
public interface MissionService {
...
}
</pre>
<p>and create a singleton MissionServiceImpl that implements MissionService.<br />
 &#8211; MissionServiceImpl :</p>
<pre>
@Singleton
public class MissionServiceImpl implements MissionService {
    public MissionServiceImpl() {
	...
	}
...
}
</pre>
<p> &#8211; MissionViewController (where the service is injected) :</p>
<pre>
public class MissionViewController {
    MissionService service;

    @Inject
    public MissionViewController(MissionService service) {
        this.service = service;
    }
...
}
</pre>
<p> &#8211; MissionViewPart</p>
<pre>
 public class MissionView extends ViewPart {
    public static final String ID = "ResUrgencesSMUR.missionView";
    MissionViewController controller;

    public MissionView() {
        controller = Controllers.getInstance(MissionViewController.class);
    }
...
}
</pre>
<p>I use a Controllers object because the <a href="http://google-guice.googlecode.com/files/Guice%201.0%20User%27s%20Guide.pdf">Guice User&rsquo;s Guide</a> say :<br />
<i><br />
Your code should deal directly with the Injector as little as possible. Instead,<br />
you want to bootstrap your application by injecting one root object. The container<br />
can further inject dependencies into the root object&rsquo;s dependencies, and so on<br />
recursively. In the end, your application should ideally have one class (if that<br />
many) which knows about the Injector, and every other class should expect to<br />
have dependencies injected.<br />
</i><br />
 &#8211; Controllers :</p>
<pre>
public class Controllers {
    static Injector injector = Guice.createInjector();
    static Map controllers = new HashMap();
    public static <T> T getInstance(Class<T> type) {
        T controller = (T)controllers.get(type);
        if (controller == null) {
            controller = injector.getInstance(type);
            controllers.put(type, controller);
        }
        return controller;
    }
}
</pre>
<p>So now when the controller is called by the view, to create UI and bind it and do whatever you want, the service is automatically injected. To use differents service&rsquo;s implementation you must use the Module concept to define, at the beginning, which implementation have to be uses by each service interface, the @implementedBy key is just the default implementation.<br />
It&rsquo;s a kind of injection use but if the application is complex and big, and also use a lot of services and differents technologies, i think it&rsquo;s best to use enterprise SOA frameworks (<a href="http://www.improve-foundations.com/">Improve Foundations</a>, <a href="http://www.springframework.org/">Spring</a>).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.itaware.eu/2007/11/27/rcp-with-guice/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>XML SWT Design</title>
		<link>http://www.itaware.eu/2007/11/20/xml-swt-design-2/</link>
		<comments>http://www.itaware.eu/2007/11/20/xml-swt-design-2/#comments</comments>
		<pubDate>Tue, 20 Nov 2007 20:09:26 +0000</pubDate>
		<dc:creator>Sébastien Letélié</dc:creator>
				<category><![CDATA[Anglais]]></category>
		<category><![CDATA[Eclipse]]></category>

		<guid isPermaLink="false">http://www.itaware.eu/2007/11/20/xml-swt-design-2/</guid>
		<description><![CDATA[After Dave J. Orme XSWT for SWT in XML, Tom Schindl extend it with EXSWT. When i choose RCP to develop my applications, i began directly with XML to design my UI. I think it&#8217;s a good way because it reduce your code (even if now you can mask it with your Java editor), but [...]]]></description>
			<content:encoded><![CDATA[<p>After <a href="http://www.coconut-palm-software.com/the_visual_editor/">Dave J. Orme</a> <a href="http://www.coconut-palm-software.com/the_visual_editor/?page_id=58">XSWT</a> for SWT in XML, <a href="http://tom-eclipse-dev.blogspot.com/">Tom Schindl</a> extend it with <a href="http://tom-eclipse-dev.blogspot.com/2007/03/xswt-databinding-dataforms.html">EXSWT</a>. When i choose RCP to develop my applications, i began directly with XML to design my UI. I think it&rsquo;s a good way because it reduce your code (even if now you can mask it with your Java editor), but the most important reason is the loosely coupled aspect and the capacity to have more than one version of your UI. For example if you have one application and many customers, it&rsquo;s sure that some customers want different design or evolution of the UI. An XML UI is the best way to personalize the UI. For example, adding XInclude in your EXSWT file give you the ability to choose within different version of a part of your UI by managing the resolution of the &laquo;&nbsp;href&nbsp;&raquo; attribute.<br />
<span id="more-127"></span><br />
This is just a few example of EXSWT code to give you an idea of how it simple to design with :<br />
 &#8211; Composite, Label, Text, ComboViewer</p>
<table>
<tr>
<td>
<pre>
&lt;w:composite background="#82cff1"&gt;
  &lt;a:layout x:class="gridLayout" f:numColumns="2" /&gt;
  &lt;w:label background="#82cff1" text="Raison :"&gt;
    &lt;a:layoutData x:class="gridData" f:horizontalAlignment="GridData.END" /&gt;
  &lt;/w:label&gt;
  &lt;w:text w:style="SWT.BORDER" x:id="callReason" font="Arial,10,SWT.BOLD"&gt;
    &lt;a:layoutData x:class="gridData" f:widthHint="320" f:horizontalAlignment="GridData.BEGINNING" /&gt;
  &lt;/w:text&gt;
  &lt;w:label background="#82cff1" text="Type :"&gt;
    &lt;a:layoutData x:class="gridData" f:horizontalAlignment="GridData.END" /&gt;
  &lt;/w:label&gt;
  &lt;v:comboViewer x:id="missionType" v:style="SWT.READ_ONLY" font="Arial,10,SWT.BOLD"&gt;
    &lt;a:combo.layoutData x:class="gridData" f:widthHint="120" f:horizontalAlignment="GridData.BEGINNING" /&gt;
  &lt;/v:comboViewer&gt;
&lt;/w:composite&gt;
</pre>
</td>
</tr>
<tr>
<td>
<img src='http://www.itaware.eu/wp-content/uploads/2007/11/ui2.jpg'/>
</td>
</tr>
</table>
<p> &#8211; TableViewer, Group, ToolBar</p>
<table width="100%">
<tr align="center">
<td>
<pre>
&lt;w:group text="Victimes" background="#82cff1" x:id="victimGroup" enabled="false"&gt;
  &lt;a:layout x:class="gridLayout" f:numColumns="2" f:marginHeight="0" f:marginWidth="0" marginTop="5" f:verticalSpacing="4" /&gt;
  &lt;v:tableViewer x:id="victims" v:style="SWT.BORDER | SWT.H_SCROLL | SWT.V_SCROLL | SWT.MULTI | SWT.FULL_SELECTION | SWT.HIDE_SELECTION" table.linesVisible="true" table.headerVisible="true"&gt;
    &lt;a:table.layoutData x:class="gridData" f:horizontalAlignment="GridData.FILL" f:grabExcessHorizontalSpace="true" f:heightHint="95" /&gt;
    &lt;v:tableViewerColumn column.text="Nom" x:id="victim.name" /&gt;
    &lt;v:tableViewerColumn column.text="Sexe/Age" x:id="victim.sexeAge" v:column.style="SWT.CENTER" /&gt;
    &lt;v:tableViewerColumn column.text="Motif" x:id="victim.motif" v:column.style="SWT.CENTER" /&gt;
    &lt;v:tableViewerColumn column.text="Transport" x:id="victim.transport" /&gt;
  &lt;/v:tableViewer&gt;
  &lt;w:toolBar background="#82cff1" w:style="SWT.FLAT | SWT.VERTICAL"&gt;
    &lt;w:toolItem toolTipText="Supprimer" x:id="victim.remove" /&gt;
    &lt;w:toolItem toolTipText="Ajouter" x:id="victim.add" /&gt;
    &lt;w:toolItem toolTipText="Exporter" x:id="victim.export" /&gt;
  &lt;/w:toolBar&gt;
&lt;/w:group&gt;
</pre>
</td>
</tr>
<tr>
<td>
<img src='http://www.itaware.eu/wp-content/uploads/2007/11/ui11.jpg'/>
</td>
</tr>
</table>
<p> &#8211; Combo, ListViewer, CDateTime (Nebula Widget)</p>
<table>
<tr>
<td>
<pre>
&lt;a:layout x:class="fillLayout" /&gt;
&lt;w:composite background="#82cff1"&gt;
  &lt;a:layout x:class="gridLayout" f:marginHeight="0" f:marginWidth="0" /&gt;
  &lt;w:combo x:id="filter" w:style="SWT.READ_ONLY"&gt;
    &lt;a:layoutData x:class="gridData" f:horizontalAlignment="GridData.CENTER" f:grabExcessHorizontalSpace="true" f:widthHint="140" /&gt;
  &lt;/w:combo&gt;
  &lt;v:listViewer v:style="SWT.MULTI | SWT.BORDER | SWT.V_SCROLL" x:id="resources"&gt;
    &lt;a:list.layoutData x:class="gridData" f:horizontalAlignment="GridData.CENTER" f:verticalAlignment="GridData.FILL" f:grabExcessVerticalSpace="true" f:widthHint="140" /&gt;
  &lt;/v:listViewer&gt;
&lt;/w:composite&gt;
&lt;w:cDateTime background="#82cff1" x:id="takeAt" w:style="CDT.TIME_SHORT | CDT.BORDER | CDT.SIMPLE | CDT.CLOCK_12_HOUR"&gt;
&lt;/w:cDateTime&gt;
</pre>
</td>
</tr>
<tr>
<td>
<img src='http://www.itaware.eu/wp-content/uploads/2007/11/ui3.jpg' />
</td>
</tr>
</table>
<p>Now i make the dream that <a href="http://www.eclipse.org/vep/WebContent/main.php">VE</a> could be able to generate EXSWT in WYSIWYG.<br />
Tom also implements <a href="http://wiki.eclipse.org/index.php/JFace_Data_Binding">JFace Data Binding</a> in EXSWT (XBL) and it&rsquo;s easy to bind your model directly in your XML.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.itaware.eu/2007/11/20/xml-swt-design-2/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>Interaction between web and desktop application</title>
		<link>http://www.itaware.eu/2007/07/15/interaction-between-web-and-desktop-application/</link>
		<comments>http://www.itaware.eu/2007/07/15/interaction-between-web-and-desktop-application/#comments</comments>
		<pubDate>Sun, 15 Jul 2007 14:48:03 +0000</pubDate>
		<dc:creator>Sébastien Letélié</dc:creator>
				<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[RIA-RDA-RWA]]></category>

		<guid isPermaLink="false">http://www.itaware.eu/2007/07/15/interaction-between-web-and-desktop-application/</guid>
		<description><![CDATA[Browser component in Eclipse RCP application offers the possibility to mix web and desktop applications. There's a lot of advantages of this technic, in particular when it concern a reuse of an existing web application. One of the interest is to never be dependant of the browser but you're application is the browser. 
To make this working it's necessary to communicate between web and desktop. This article suggest 6 solutions...]]></description>
			<content:encoded><![CDATA[<p>Browser component in Eclipse RCP application offers the possibility to mix web and desktop applications. There&rsquo;s a lot of advantages of this, in particular when it concern reuse of an existing web application. One of the interest is to never be dependant of the browser but to make your application become the browser.<br />
To make this working it&rsquo;s necessary to communicate between web and desktop, it&rsquo;s relatively easy to send data to browser by using (<a href="http://help.eclipse.org/help33/nftopic/org.eclipse.platform.doc.isv/reference/api/org/eclipse/swt/browser/Browser.html#setUrl(java.lang.String)">setURL()</a>) or by executing Javascript (<a href="http://help.eclipse.org/help33/nftopic/org.eclipse.platform.doc.isv/reference/api/org/eclipse/swt/browser/Browser.html#execute(java.lang.String)">execute()</a>). But for sending data to the desktop it&rsquo;s more difficult. I suggest 6 solutions to do that :<br />
1. via the status bar : like it show on the SWT snippets site (<a href="http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet160.java?view=co">Snippet160</a>)<br />
2. via the address bar: like <a href="http://www.developer.com/java/ent/article.php/3644196">Peter Nehrer</a> say<br />
3. directly request HTML DOM : by using Mozilla Browser (new in 3.3) with the <a href="http://www.eclipse.org/swt/faq.php#howusejavaxpcom">XPCOM</a> library. A little example using the <a href="http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet267.java?view=co">Snippet267</a> and modify it to use XPath and catch a title of an input field. There&rsquo;s a lot of possibility with this API like <a href="http://www.eclipse.org/atf/">ATF</a> do (maybe i have to take time to make an article about the possibility offers by XPCOM).</p>
<pre>
static Browser browser;
public static void main(String[] args) {
    Display display = new Display();
    Shell shell = new Shell(display);
    shell.setLayout(new GridLayout(2, true));
    shell.setText("Use Mozilla's Design Mode");
    try {
        browser = new Browser(shell, SWT.MOZILLA);
    } catch (SWTError e) {
        System.out.println("Could not instantiate Browser: " + e.getMessage());
        return;
    }
    browser.setLayoutData(new GridData(GridData.FILL, GridData.FILL, true, true, 2, 1));
    Button searchButton = new Button(shell, SWT.PUSH);
    searchButton.setText("Search");
    searchButton.addListener(SWT.Selection, new Listener() {
        public void handleEvent(Event event) {
            search();
        }
    });
    browser.setUrl("http://www.google.com");
    shell.setSize(400, 400);
    shell.open();
    while (!shell.isDisposed()) {
        if (!display.readAndDispatch())
             display.sleep();
    }
    display.dispose();
}

public static boolean search() {
    nsIWebBrowser webBrowser = (nsIWebBrowser) browser.getWebBrowser();
    if (webBrowser == null) {
        System.out.println("Could not get the nsIWebBrowser from the Browser widget");
        return false;
    }
    nsIDOMWindow window = webBrowser.getContentDOMWindow();
    nsIDOMDocument document = window.getDocument();
    nsIDOMXPathEvaluator xpath = (nsIDOMXPathEvaluator) document.queryInterface(nsIDOMXPathEvaluator.NS_IDOMXPATHEVALUATOR_IID);
    nsIDOMXPathNSResolver res = xpath.createNSResolver(document);
    nsISupports obj = xpath.evaluate("//input[@name='q']/@title",
                                                 document,
                                                 res,
                                                 nsIDOMXPathResult.STRING_TYPE,
                                                 null);
    nsIDOMXPathResult result = (nsIDOMXPathResult) obj.queryInterface(nsIDOMXPathResult.NS_IDOMXPATHRESULT_IID);
    System.out.println(result.getStringValue());
    return true;
}
</pre>
<p></code><br />
4. via a socket : by executing an XMLHTTPRequest with execute() method which call a socket and get the content.</p>
<pre>
private String getDataFromBrowser() {
	String javascript = "try {";
	javascript += "xhr_object = new ActiveXObject(\"Microsoft.XMLHTTP\"); ";
	javascript += "xhr_object.open(\"POST\", \"http://localhost:9091\", false);";
	javascript += "xhr_object.setRequestHeader(\"Content-type\", \"application/x-www-form-urlencoded\");";
	javascript += "xhr_param = generateXML();"; // appel d'une fonction retournant un contenu
	javascript += "xhr_object.send(xhr_param);";
	javascript += "} catch (ex) { alert(\"Failed to save document\"); }";

	String xml = null;
	XMLPicker e = new XMLPicker();
	Thread t = new Thread(e);
	t.start();

	// wait threa run
	try {
		Thread.sleep(10);
	} catch (InterruptedException eee) {
	}
	// ask browser
	boolean ok = browser.execute(javascript);

	int wait = 0;
	while (xml == null &#038;&#038; wait < 10)
		try {
			Thread.sleep(10);
			wait++;
			xml = e.getXML();
		} catch (InterruptedException eeee) {
		}
	System.out.println(xml);
	return xml;
}

private class XMLPicker implements Runnable {
	private String xml;
	public String getXML() {
		return xml;
	}

	public void run() {
		ServerSocket server = null;
		try {
			server = new ServerSocket(9091);
			server.setSoTimeout(5000);
			System.out.println("Waiting for response");
			Socket socket = server.accept();
			// stream treatment, i can give the HTTPServer class if you want
			xml = HttpServer.getXMLString(socket, "UTF-8"); 
			socket.close();
		} catch (IOException ee) {
			System.err.println(ee);
		} finally {
			if (server != null) {
				try {
					server.close();
				} catch (Exception e) {
				// Ignore.
				}
			}
		}
	}
}
</pre>
<p>5. running an HTTP server inside the Eclipse JVM : with Tomcat <a href="http://www.onjava.com/pub/a/onjava/2002/04/03/tomcat.html">embedded</a> for example or with WebObjects (<a href="http://developer.apple.com/documentation/WebObjects/Reference/API5.2.4/com/webobjects/appserver/WOApplication.html#primeApplication(java.lang.String,%20java.net.URL,%20java.lang.String)">Application.primeApplication()</a>). The objects in the same JVM can be shared but be carreful of classloaders.<br />
6. via <a href="http://www.terracotta.org/">terracota</a> : a JVM cluster offer an easy way to synchronize objects between JVM.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.itaware.eu/2007/07/15/interaction-between-web-and-desktop-application/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>GWT-Plugin CYPAL</title>
		<link>http://www.itaware.eu/2007/06/22/gwt-plugin-cypal-2/</link>
		<comments>http://www.itaware.eu/2007/06/22/gwt-plugin-cypal-2/#comments</comments>
		<pubDate>Fri, 22 Jun 2007 08:01:42 +0000</pubDate>
		<dc:creator>Cyril Balit</dc:creator>
				<category><![CDATA[Anglais]]></category>
		<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[RIA-RDA-RWA]]></category>

		<guid isPermaLink="false">http://www.itaware.eu/2007/06/22/gwt-plugin-cypal-2/</guid>
		<description><![CDATA[Ok the news is not hot (Didier was talking about it in onGWT on April) but i just try Cypal Studio plugin for eclipse and i found it really interresting. The features are the one you can expect for that kind of tool (project creation wizzard, compilation, creating module and remote service&#8230;). To have if [...]]]></description>
			<content:encoded><![CDATA[<p>Ok the news is not hot (Didier was talking about it in <a href="http://www.ongwt.com/post/2007/04/26/Googlipse-is-dead-long-live-Cypal-Studio-for-GWT">onGWT</a> on April) but i just try <a href="http://www.cypal.in/studio">Cypal Studio</a> plugin for eclipse and i found it really interresting. The features are the one you can expect for that kind of tool (project creation wizzard, compilation, creating module and remote service&#8230;). To have if you start  GWT project.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.itaware.eu/2007/06/22/gwt-plugin-cypal-2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
