eclipse

An eclipse is an astronomical event that occurs when an astronomical object is temporarily obscured, either by passing into the shadow of another body or by having another body pass between it and the viewer. read more at WikiPedia

    • "I format my code  like that",  yes but every developer format his code differently...
    • "Why having java collection if you can not use the directly", this speak of course against encapsulation and clear APIs...
    • "I put accessors at the end" "i want to see relevant code at the beginning of classes and in the same order as execution" simply b... and not object oriented at all, they do not think about object message but files
    • "I never  use the keywords this, it is not needed"

    At the end, You can discuss for hours, just for.... nothing, people don't like to change, just auto format code, sort methods and most of them are lost/complains/recommit their code on yours...
    In order to force them or remove  difference between coding practice, why not bringing Checkstylein your organization?

    Checkstyle is a development tool to help programmers write Java code that adheres to a coding standard. It automates the process of checking Java code to spare humans of this boring (but important) task. This makes it ideal for projects that want to enforce a coding standard. 
    Checkstyle is highly configurable and can be made to support almost any coding standard. An example configuration file is supplied supporting theSun Code Conventions. As well, other sample configuration files are supplied for other well known conventions.¨

    The best Eclipse plugin is available at  http://eclipse-cs.sourceforge.net/

    The only practicable way of  is either to 
    • Bring all developer in a room, and let them vote all together which features is a warning, an error, or if it should not be removed from the common set of rules, but the discussion will be quite loud. You will hear a lot of "I do not need it, I know how to develop..."
    • Force them to use the common SUN/Other standard without discussion. This may work in a bug company/team.


    Eclipse has a cleanupfunctionality (Windows - preferences - java - code styles - cleanup), which can be triggered at each save of a file (only in 3.3). I am personally using it since 2 months and refuse to live without. My settings are quite ambitious but reflect my intentions to keep my code as neutral as possible, it remove unneeded stuffs, format and add parenthesis where it is needed automatically.

    - Add 'this' qualifier to unqualified field accesses
    - Add 'this' qualifier to unqualified method accesses
    - Qualify accesses to static fields with declaring class
    - Qualify accesses to static methods with declaring class
    - Change non static accesses to static members using declaring type
    - Change indirect accesses to static members to direct accesses (accesses through subtypes)
    - Convert control statement bodies to block
    - Add paranoiac parentheses
    - Remove unused imports
    - Remove unused local variables
    - Add missing '@Override' annotations
    - Add missing '@Deprecated' annotations
    - Remove unnecessary casts
    - Remove unnecessary '$NON-NLS$' tags
    - Sort all members
    - Organize imports
    - Format source code

    About sorting method

    A quite interesting discussion at Javaworld can be read here.  A lot of users have post responses, and of course still do not get the point that the  object code is not linear, so manual human sorting based on this flawed assumption is only a failure. It is more than a failure also because every developer will sort code differently...so the more neutral behavior is Eclipse alphabetical sorting.
    Eclipse or any IDE have 3 magic keys: (F3) for opening declaration of the element, (F4) Open Type hierarchy and a back button (ALT - LEFT). You don't/can't have to read the code like a book, just to jump from one method to the other with F3 - back, use call hierarchy (CTRL -ALT - H).  If you want to understand the execution flow, it is better to look at the sequence diagram....
      Moreover, I do not often stay in an object very long, because I always try to spread responsibilities across objects.
     
  • eclipse&160;

    A very little trick that allow you to quickly run any operation involving a DOS command on an Eclipse project. Go to the external launcher, and create a new configuration.

    This trick may be useful for running your Maven set of command without any dependencies to M2Eclipse.

    &160;

    &160;

    Location:&160; {ENV_VAR:COMSPEC}
    Working Directory: {project_loc}

    eclipse.open.command.line

    {ENV_VAR}

    Returns the value of an environment variable. An environment variable name must be specified as an argument.

    command.line.prompt

  • phpstorm_header

    JetBrains PhpStorm is a commercial IDE for PHP built on JetBrains' IntelliJ IDEA platform.

    PhpStorm provides intelligent editor for PHP code, HTML and JavaScript with on-the-fly code analysis and automated refactoring for PHP and JavaScript code. Code completion supports PHP 5.3 including namespaces and closures.

  • Among the 1246 plugins (!) available for Eclipse, I found this one that I really like to use since it has immediately boost my productivity in Eclipse.

    InstaSearch is an Eclipse plug-in for doing fast text search in the workspace. The search is performed instantly as-you-type and resulting files are displayed in an Eclipse view. It is a lightweight plug-in based on Apache Lucene search engine. Each file then can be previewed using few most matching and relevant lines. A double-click on the match leads to the matching line in the file.

    It's really instant and it searches through all the files in the workspace, by default it index the following file extensions (but you can add your own)

    aj,ant,bat,bookmap,c,cfg,cmd,confluence,cpp,css,dbk,dita,ditamap,ditaval,dtd,ecore,ecore2ecore,
    ecore2xml,emof,ent,exsd,fo,genmodel,h,hpp,htm,html,htpl,inc,ini,java,js,jsf,json,jsp,jspf,jspx,jsv,jtpl,log,
    macrodef,mathml,mediawiki,meta,mf,mml,mod,ncx,nvdl,opf,php,php3,php4,php5,phps,phtml,pl,pom,prefs,
    product,properties,py,rnc,rng,sch,sh,shtm,shtml,sql,sqlj,svg,tag,tagf,tagx,tagxf,target,textile,tld,tracwiki,tsd,twiki,
    txt,vxml,wml,wsdd,wsdl,wsil,wsimsg,wssc,wssr,xhtml,xmi,xml,xpl,xproc,xq,xql,xqm,xquery,xqy,xsd,xsl,xslt,xtm,xu

    eclipse_instasearch

    As it use Apache Lucene internally you can build some nice queries:

    • Searching for icefacescould result in 35 hits (items contain the word icefaces)
    • Searching for web.xmlresults in 3 hits (items contain the word web.xml or file named web.xml)
    • Searching for icefacesweb.xml(without quotes) results in 148 hits (items contain the words icefacesor web.xmlor both)
    • Searching for icefaces and web.xmlresults in 3 hits (results contain both words icefacesand web.xml)
    eclipse_instasearch_01
    • To exclude search terms just add a “-” in front of it:&160; icefaces –application
    • To perform a single character wildcard search use the "?" symbol.
    • To perform a multiple character wildcard search use the "*" symbol (looks for 0 or more characters).
    • Finding words that are within a specific distance away. To do a proximity search use the tilde, "~", symbol at the end of a Phrase. For example to search for "Specifies" and "milliseconds" within 5 words of each other in a document use the search: "Specifies" "milliseconds" ~5

    eclipse_instasearch_02

    Main Features

    • Instantly shows search results
    • Shows suggestions using auto-completion
    • Shows a preview using relevant lines
    • Matches partial words
    • Opens and highlights matches in files
    • Searches jar source attachments

    You can install it from Eclipse Marketplace (Menu Help – then Select Eclipse Marketplace and search for InstaSearch)

    You can find a lot more plugin at Eclipse Marketplace

  • Introductiontom2eclipse

    The Eclipse IDE is the most widely used IDE for Java development today. At the same time, Apache Maven continues to mature, and has grown to be the industry standard for creating extensible and reliable enterprise builds. While it is certainly possible to develop applications in Eclipse and use Maven as a command-line build tool, most developers expect the IDE to know how to invoke and interact with the build tool they are using.

    Enter m2eclipse. Them2eclipse project provides support for Maven within the Eclipse IDE. It is a plugin which helps bridge the gaps between Maven and Eclipse. Using m2eclipse you can develop a large multi-module project with nested Maven modules and have this hierarchical structure reflected in your Eclipse IDE. Using m2eclipse, you can launch and manage your project's Maven build using editors, and your IDE will become aware of both the local and remote Maven repositories allowing you to quickly search for and locate any artifact made available in the Maven repository. m2eclipse will also change the way you create projects with a novel and easy-to-use interface for creating projects from Maven Archetypes.

    In this article, we will explore the features m2eclipse provides and help you start using an Eclipse plugin which provides real Maven integration for the best IDE platform available. After reading this article you should have enough information to install the m2eclipse plugin and start creating or importing existing Maven projects into your Eclipse workspace. You will also have an idea of some of the features provided the plugin. read more at ServerSide

  • Don't forget that the latest version of eclipse is due to be released tomorrow :-)

    &160;eclipse.ganymede&160;

    "The goal of the Ganymede Simultaneous Release is currently the same aslast year's goal for Europa: to release N major Eclipse
    projects at the same time. We are doing this simultaneous release to support the needs of the ecosystem members who integrate
    Eclipse frameworks into their own software and products. While those product producers naturally accept the ultimate responsibility
    for their customers' experiences, Ganymede's goal is to eliminate uncertainity about project version numbers, and thus to allow
    ecosystem members to start their own integration, cross-project, and cross-product testing efforts earlier. Ganymede is about
    improving the productivity of the developers working on top of Eclipse frameworks by providing a more transparent and predictable
    development cycle; Ganymede is about developers helping developers serve the whole Eclipse community."

    Download the latest eclipse Ganymede version

    NOTE:

    Ganymede is a natural satellite of Jupiter and the largest natural satellite in the Solar System. The next moon of Jupiter that may be use
    for the next release of Eclipse may be IO...

  • In order to better test the code I am giving You, I have now locally running...

    1. DEV: developing new PHP code, connected to CVS at Joomlaforge
    2. TEST to test component installation and code in a clean Joomla installation. If everything work, a binary version will be created at Joomla Forge in developer section.
    3. PROD is a copy of my production site (You are currently reading :-) )
    I have also set 2 machines with each time these 3 stages:
    1. WindowsXP - eclipse 3.1 - phpeclipse - mysql5 - php 4.1 - apache for DEV, TEST and PROD
    2. SuSE 10.0  - eclipse 3.1 - phpeclipse - mysql5 - php 4.1 - apache for DEV, TEST and PROD

    so i will be able to better test my components, You can still contact me and offer translations or beta testing....

    You want to have or see new functionnalities in one of these components?
    use my WIKI Order and priorities has to be discussed, a poll/vote can be open in a few days here as well.

    You have found bugs?

    Please, do not contact me and ask for support on my homepage, ALL Projects are now hosted at Joomlaforge and have each one their Tracker
    Project Report Bug here
    http://developer.joomla.org/sf/projects/com_securityimages   click on Tracker icon
    http://developer.joomla.org/sf/projects/com_hashcash   click on Tracker icon
    http://developer.joomla.org/sf/projects/com_bayesianspamfiltering   click on Tracker icon
    http://developer.joomla.org/sf/projects/com_log4php   click on Tracker icon
    http://developer.joomla.org/sf/projects/com_akocommentplus   click on Tracker icon
    http://developer.joomla.org/sf/projects/com_akobookplus   click on Tracker icon
  • Pollinate Milestone 3On March 2 the EclipsePollinate project release milestone 3. The goal of the Pollinate project is to build an Eclipse-based IDE and toolset that leverages the open source Apache Beehive application framework. The Pollinate project is led byInstantiations and is sponsored byBEA. Pollinate will provide a full-featured Java development environment that enables developers to visually build and assemble enterprise-scale web applications, JSPs, web services, and leverage the Java controls framework for creating and consuming J2EE
    components.

    BEA Joins Eclipse Foundation:
    BEA has joined the Eclipse Foundation as a Board Member and Strategic Developer. As part of this commitment, BEA offered to lead the Web Tools Platform (WTP) project, an offer that was accepted with the selection of a BEA senior architect to the WTP Project Management Committee as co-lead. In addition,BEA is proposing a new Language Development Tools project and is also merging its open source
    AspectWerkz project with the Eclipse AspectJ project.
     

  • When Eclipse meet Joomla
     

    Project: SolarJoomla
    The easiest way to develop component, modules, bots for Jooomla using best of the breed open source software.

    In order to speed up development of Joomla software, I am currently developing a developer package "start and ready to work". This package will be release at the beginning of next week (18.04.2006)

    Click read more...

    Content of package

    eclipse logo
    Eclipse 3.1.2
    www.eclipse.org
    Eclipse is an open source community whose projects are focused on providing a vendor-neutral open development platform and application frameworks for building software. The Eclipse Foundation is a not-for-profit corporation formed to advance the creation, evolution, promotion, and support of the Eclipse Platform and to cultivate both an open source community and an ecosystem of complementary products, capabilities, and services.
    php eclipse plugin
    PhpEclipse 1.1.8
    The PHPeclipse project aims to create a full featured PHP IDE with features like internal PHP parser, debugger, code formatter, outline view, templates and much more.
    apache http server
    Apache 1.3.33

    The Apache HTTP Server Project is an effort to develop and maintain an open-source HTTP server for modern operating systems including UNIX and Windows NT. The goal of this project is to provide a secure, efficient and extensible server that provides HTTP services in sync with the current HTTP standards.

    Apache has been the most popular web server on the Internet since April 1996.
    with mod_rewrite
    php logo
    PHP  4.3.1
    PHP is a popular open-source programming language used primarily for developing server-side applications and dynamic web content, and more recently, other software. The name is a recursive acronym for "PHP: Hypertext Preprocessor".

    with PHPdg debugger support
    with GD2 image manipulation library
    phpadmin
    PHPmyAdmin 2.8.0.3
    phpMyAdmin is a tool written in PHP intended to handle the administration of MySQL over the Web. Currently it can create and drop databases, create/drop/alter tables, delete/edit/add fields, execute any SQL statement, manage keys on fields.

    Accessible through:
    http://localhost/mysql/
    joomla logo
    Joomla 1.0.8 www.joomla.org
    Joomla! is one of the most powerful Open Source Content Management Systems on the planet. It is used all over the world for everything from simple websites to complex corporate applications. Joomla! is easy to install, simple to manage, and reliable.

    configured to access mysql dev10x database
    admin panel login: admin
    admin panel pwd: admin
    joomla logo
    Joomla 1.1alpha2 www.joomla.org
    configured to access mysql dev15x database
    admin panel login: admin
    admin panel pwd: admin
    mysql logo
    MySQL 4.1.19 
    root login: root
    root password: empty
    Eclipse Launcher Version 2.0.2A tool for java developers using eclipse IDE. The eclipse launcher provides developers to manage multiple workspaces and to start those. The program is shown in system tray from which it is possible to edit or start the workspace definition in an easy way.
    java
    Sun JDK 1.5
    Java Development Kit from Sun Microsystems that implements the basic set of tools needed to write, test and debug Java applications and applets. Needed to run Eclipse.



    Some figures

    • Distribution will be available as zip or setup.exe
    • You will have to accept and Read all licences in directory c:\SolarJoomla\licences\
    • start one program EclipseLauncher.exe to enjoy a running Joomla 1.X environment.
  • geeko I am a SUSE and OpenSuse user since the version 9.0 (back to 2003) and I
    decided to install the latest sequel, aka OpenSUSE 11.0 the same day it came out.

    You can read a lot of positive review below:

    What has impressed me after only 4 days,

    • Was the time it has took to install a full KDE4 desktop: no more than 25 minutes.
    • YAST auto detect the resolution of my ceiling projector a lot better (like any windows XP)
    • The number of 3rd party repository is huge and is just a few clicks away, so installing VLC,
      NVIDIA, ATI drivers and software (Google PICASA, Google Earth) has never been so easy.
    • KDE 4 has never crash (till now) even with COMPIZ activated as default.
    • KDE4 transparent icon surrounding is a bit disturbing at first, but I assume this feature can be switch off.
    • Software update are a lot faster and the tray icon checking for update is so fast that you'll
      forget all issues encountered with OpenSUSE 10.3

    All in all a very good operating system that I truly like using every day.

    Download your live CD or DVD here

    KDE 4.1 is getting better and better everyday and will soon look like any MAC or Vista,
    look here some astonishing screen shots

    kde4.1.preview

  • The file web.xml inside the WEB-INF folder is the Web Application Deployment Descriptor for your application. This is an XML file describing the servlets and other components that make up your application. The file below is what I use at work. It contains better settings than the default one, plus all descriptions of parameters.

    <?xml version="1.0" encoding="UTF-8"?>
    <web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee"
        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee   http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
     
    <context-param>
    <description>
    Comma separated list of URIs of (additional) faces             config files. (e.g. /WEB-INF/my-config.xml) See JSF             1.0 PRD2,
    10.3.2 Attention: You do not need to put
    /WEB-INF/faces-config.xml in here.
    </description>
    <param-name>javax.faces.CONFIG_FILES</param-name>
    <param-value>
     /WEB-INF/faces-configs/common-faces-config.xml,
     /WEB-INF/faces-configs/page1-faces-config.xml,
     /WEB-INF/faces-configs/page2-faces-config.xml
    </param-value>
    </context-param>
    Follow Divide and Conquer rule:
    Do not put all your managed beans, navigations rules in one big file. Consider one faces-config per functions or html page.
    <context-param>
    <description>State saving method: "client" or "server"          (= default) See JSF Specification 2.5.3
    </description>
    <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
    <param-value>server</param-value>
    </context-param>
    Server is recommended.
    Ive tried one day client, but HTML pages were 10Mb big!
    <context-param>
    <description>
    Only applicable if state saving method is "server"         (= default) and if
    org.apache.myfaces.SERIALIZE_STATE_IN_SESSION is           true (=default) If true (default) the serialized              state will be compressed before it is written to the session. If false the state will not be compressed.
    </description>
    <param-name>
      org.apache.myfaces.COMPRESS_STATE_IN_SESSION
    </param-name>
    <param-value>true</param-value>
    </context-param>
    You should always balanced cpu/memory usage.
    (Compressing state cost CPU but spare memory...obvious)


    <context-param>
    <description>
    Only applicable if state saving method is "server"             (= default). If true (default) the state will be               serialized to a byte stream before it is written to             the session. If false the state will not be                     serialized to a byte stream.
    </description>
    <param-name>
     org.apache.myfaces.SERIALIZE_STATE_IN_SESSION
    </param-name>
    <param-value>false</param-value>
    </context-param>
    Compressing data save memory bytes on server at the cost of more computational power.
    <context-param>
    <param-name>
    org.apache.myfaces.NUMBER_OF_VIEWS_IN_SESSION
    </param-name>
    <param-value>5</param-value>
    </context-param>
    Number of back button. Default is 20. far too much. reducing this value decrease memory size.
    <context-param>
    <description>
    This parameter tells MyFaces if javascript code               should be allowed in the rendered HTML output. If             javascript is allowed, command_link anchors will have javascript code that submits the corresponding form. If javascript is not allowed, the state saving info and nested parameters will beadded as url parameters. Default: "true"
    </description>
    <param-name>org.apache.myfaces.ALLOW_JAVASCRIPT</param-name>
    <param-value>true</param-value>
    </context-param>
    <context-param>
    <param-name>org.apache.myfaces.DETECT_JAVASCRIPT</param-name>
    <param-value>false</param-value>
    </context-param>
    Nothing special here. Most of the time, webpage are full of javascript.
    <context-param>
    <description>The buffer size to set on the response         when the  ResponseWriter is generated.
    By default the value is -1, which will not assign             a buffer size on the response.
    </description>
    <param-name>facelets.BUFFER_SIZE</param-name>
    <param-value>8192</param-value>
    </context-param> 
    Try to set the buffer size to the most common page size.
    <context-param>
    <param-name>facelets.SKIP_COMMENTS</param-name>
    <param-value>true</param-value>
    </context-param>
    In production, no need to let comment in rendered code
    <context-param>
    <description>
    If true, rendered HTML code will be formatted, so             that it is "human readable". i.e. additional line             separators and whitespace will be written, that do             not influence the HTML code. Default: "true"
    </description>
    <param-name>org.apache.myfaces.PRETTY_HTML</param-name>
    <param-value>false</param-value>
    </context-param>
    Cpu waste in production.
    Beautify your code in eclipse.
    Consider instead using Firefox source chart plugin which always beautify and color the source source
    <context-param>
    <description>
    If true, a javascript function will be rendered               that is able to restore the former vertical scroll             on every request.
    Convenient feature if you have pages with long                 lists and you do not want the browser page to                 always jump to the top if you trigger a link or               button action that stays on the same
    page. Default: "false"
    </description>
    <param-name>org.apache.myfaces.AUTO_SCROLL</param-name>
    <param-value>true</param-value>
    </context-param>
     
    <context-param>
    <description>
    Validate managed beans, navigation rules and                   ensure that forms are not nested.
    </description>
    <param-name>org.apache.myfaces.VALIDATE</param-name>
    <param-value>true</param-value>
    </context-param>
    Can be turned off in production, if you have a good testing team and many deployment stage This kind of errors should not go un noticed.
    <context-param>
     <param-name>facelets.LIBRARIES</param-name>
    <param-value>
     /WEB-INF/taglib/tomahawk.taglib.xml;
     /WEB-INF/taglib/aa.taglib.xml;
     /WEB-INF/taglib/your.taglib.xml
    </param-value>
    </context-param>
    List here all 3rd party and your own tag library
    <context-param>
    <param-name>facelets.REFRESH_PERIOD</param-name>
    <param-value>2</param-value>
    </context-param>
    <context-param>
    <description>Special Debug Output for Development
    </description>
     <param-name>facelets.DEVELOPMENT</param-name>
     <param-value>false</param-value>
    </context-param>
    <context-param>
     <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
     <param-value>.xhtml</param-value>
    </context-param>
    			Using a 
    			facelets.REFRESH_PERIOD >= 1 
    			means that templates 
    			will be reloaded after 
    			a given period if the
    			file has been modified 
    			on the file-system.
    			

     

     

     

     

    Obvious settings

    <filter>
    <filter-name>extensionsFilter</filter-name>
    <filter-class>
     org.apache.myfaces.webapp.filter.ExtensionsFilter
    </filter-class>
     <init-param>
      <param-name>uploadMaxFileSize</param-name>
      <param-value>100m</param-value>
    </init-param>
    <init-param>
     <param-name>uploadThresholdSize</param-name>
     <param-value>100k</param-value>
    </init-param>
    </filter>   
    Some security settings. Consider settings these values accordingly to your needs.
    <error-page>
     <error-code>404</error-code>
     <location>/error.jsp</location>
    </error-page>
           
    <error-page>
     <error-code>500</error-code>
     <location>/error.jsp</location>
    </error-page>
           
    <error-page>
     <exception-type>java.lang.Exception</exception-type>
     <location>/error.jsp</location>
    </error-page>
    Standard settings not related to JSF. Never reveal any useful informations in error pages!

       
  • SableVM is a highly-portable Java virtual machine written in C, and implementing the Java virtual machine specification, second edition.
    I ti s currently able to start and use Eclipse 3.1
    On the JVM side, Java on BeOs is making huge steps
  • Joomla! Doc has a great documentation online that explains how to set up your development environment

    This article provides detailed instructions for setting up your workstation for Joomla! development. Note that there are many possible configurations for doing Joomla! development. Any environment that supports Apache, MySql, PHP, and Subversion should work for writing Joomla! code and extensions.

    This document provides step-by-step instructions for setting up and working with the Eclipse IDE. The example used and screen shots are for Windows XP, but the basic steps are the same for Linux.

    The part 1 mainly explains how to install technical components

    The part 2 is even better as it explains how to create patches for Joomla! along with some eclipse tips and tricks.

  • apache_maven

    build.tools

     

     

     

     

     

    Even if the sample is quite small (600 responses), it still interesting going through these compiled data

    Some time ago we ran a survey asking a few questions about the build process, specifically the tools that are used to do incremental builds and how much time those builds take. We had over 600 responses, so now it’s time to count the results.

    This is the first time that we’ve published results on the incremental build process, so the information is more likely to serve as a guide than an authoritative information source.

    Read More here

  • The Graphical Editing Framework (GEF) from eclipseuses an SWT-based lightweight GUI toolkit to provide a feature-rich framework for creating graphical editors in Eclipse. GEF is application neutral and provides the groundwork to build almost any application, including, but not limited to, charts and graphs, reports, activity diagrams, GUI builders, UML diagram editors, and even WYSIWYG text editors like HTML.
  • The Web Tools Platform(WTP) project's mission is to provide a common framework for building Web tools for Eclipseand to provide both standard and Java Web tools that build upon the common framework.
  • section-java-testing A great thing about Eclipse is that you can easily extend it with additional functionality and there are plenty of add-on to choose from. We would like to highlight three free plug-ins that help our Java developers improve their code.
    &160;
    • Checkstyle improves the readability of Java code by helping developers adhere to coding conventions. Eclipse has powerful auto-formatting capabilities but lacks the ability to warn when coding conventions are not followed. Checkstyle provides configurable rule sets and adds warnings to files that break the rules. New members on a team and more experienced developers can both benefit from these reminders.
    • FindBugs helps developers detect common bugs by searching for bug patterns, pieces of code that are likely to cause bugs. The plug-in contains a list of over 200 bug patterns grouped into categories like correctness, performance and security.
    • EclEmma is an award winning code coverage tool for Eclipse. The plug-in is based on the EMMA Java code coverage tool, bringing its philosophy to Eclipse: fast develop/test cycles, rich code coverage and non-invasive tooling. The plug-in provides color highlighting of executed code. This allows developers to see at a glance which areas need more testing.
  • Beaucoup de personne me connaissant et qui m'écrivent me demande comment je developpe mes programmes java car je trouve toujours le moyen d'en faire des frameworks...ce qui est par définition plus dur.

    Eh bien j'applique plusieurs petite règles simples...

    1. Un bon tool: je ne travaille qu'avec eclipse (www.eclipse.org) car c'est un IDE de qualité et malgré la quantité de perspectives (j'en ai 16), views (j'en ai 64) et plugins (>20), je m'y sens à   l'aise. Je privilégie la vue hiérarchique "java browsing view" avec une vue supplementaire "hiérarchie" (F4) car cela facilite la navigation et le découpage sémantique losque je dévelope (projets<-> packages<->objets<->hiérarchie<->méthodes<->code)
    2. Un environnement de travail propice: Je travaille avec 2 écrans (un 21'' et un 15'4 LCD) car rien n'est plus ennuyeux de perdre son temps à   bouger/réduire/changer de tâches sans cesse. Cela me permet aussi de travailler en parallèle. C'est déroutant au début mais rien n'est plus malléable que le cerveau humain et vous vous surprendrez au bout de quelques semaines en passant d'un écran à   l'autre sans cesse. C'est simple si demain je trouve une méthode fiables et peu couteuse en temps CPU (pas avec une carte video USB svp) pour avoir un troisième écran, je saute sur l'occasion immédiatement.

    Ces 2 règles ne participent qu'a hauteur de 15% à   un travail de qualité...mais elle réduisent le stress au poste de travail. Le reste est plus standard...

    Quelques techniques de développement modernes, ont bouleversés ma vie (relativement courte) de developpeur:

    1. Les "design patterns" pour appliquer des élements d'architectures éprouvés à   des classes de problèmes.
      Il faut bien sur les comprendre (quand les appliquer et leurs bénéfices/inconvénients) sans pour autant savoir les implémenter. J'en place un maximum sans effort grà ¢ce à   un générateur de pattern (plugin eclipse).
      Je me débrouille pour avoir des hièrarchies la ou c'est évident (mais en général, elles apparaissent toute seule cf. Refactoring), j'ai rarement des super classes non abstraites et sans interface, je crée toujours des interfaces pour augmenter le niveau d'abstraction dans mon code à   chaque niveau (layer) et laisser à   l'utilisateur le droit d'insérer son code dans le mien.
      Rappeler vous: sans interfaces, vous n'avez pas de polymorphisme en java et un typage trop fort (pourquoi encore passer des types concrets à   vos objets alors que l'on peut jouer à   des niveaux plus abstraits avec les interfaces?)
      Les design patterns apportent, à   mon code, la flexibilité (pattern de créations), le dynamisme (pattern de comportements) ou améliore le design (pattern de structures)
      Je n'hésite pas non plus à   créer des objets en quantités et à   leur donner les droits et fonctions minimums qui leurs incombent, car peu m'inporte les pertes de performances: je privilégie le design quitte à   devoir profiler plus tard.
    2. Les "antipatterns" (www.antipatterns.com/) leur contraire, en général lorsque je récupère du code dans un mauvais état. Cela m'aide à   trouver quelle "design patterns" peut arranger la situation (en vue de la correction d'un bug, pour améliorer la maintenance etc...) 
    3. Je programme de plus en plus "par intentions" (lien-> informit), une idée centrale de l'extreme programming (XP voir  www.extremeprogramming.org ). Comment le client voudrait avoir à   utiliser mon code, en fait à   quoi doit ressembler idéalement le code (le nom des types, des méthodes, des mediateurs). Je les écrits (comme un squelette) et bien sur ils n'existent pas encore, (donc compile error). Je force donc eclipse à   les créer (Quick fix ou CTRL-1)  et remplis les blancs, à   savoir l'implémentation, ce qui est forcément une tache moins intéressante.

    4. l'UML (Unified Modelling Language) oui de plus en plus, mais uniquement pour observer l'évolution des dépendances entre les objects (les motifs et les relations) sur mon 2ème écran. Et toujours en reverse engineering: je modifie le code java et observe d'un oeil le diagramme UML. En fait cela rejoint la programmation par intention dans un sens sauf que normalement on part de l'UML par intention pour créer le squellete du code java et non l'inverse. Le sens que j'utilise permet cependant de compléter mon javadoc ou ma documentation efficacement.
    5. Les "metrics" (plugin eclipse metrics) ne me servent que rarement mais surtout pour auditter du code ne m'appartenant pas. J'utilise neanmoins le plugin Code analysys plugin(CAP) ou celui de IBM alphawork: Structural Analysis for Java (SA4j) néanmoins de temps en temps...

    Mais la véritable APOCALYPSE est survenue chez moi il y a trois ans:

    1. Avec le "Refactoring" ' www.refactoring.com ) il m'est impossible de tout prévoir et c'est la que trés rapidement, le refactoring tool de eclipse m'aide car j'itère des changes atomiques (dans le sens: élémentaire et rapide) très rapidement à   travers tout mon code et cela en permanence. Des méthodes bougent ou disparaissent, je renomme en permanence tout: variables, objects, packages (pour éviter des commentaires à   travers mon code). j'introduit aussi des design patterns.
      Je les utilisent tellement que j'ai définit des racourcis clavier dans le workspace de eclipse.
      Le code devient de plus en plus petit (donc moins de bugs/lignes) et fait de plus en plus de chose (par design). Il se bonnifie avec un risque minimum d'instabilité car
    2. J'utilise des "test unitaires" (Junit www.junit.org) qui m'assure aprés chaque gros refactoring que je n'ai pas perdu de fonctionnalitées, cela me sert aussi à   tester mes interfaces: comment mon code va ètre utilisé?, est ce que les signatures sont bien choisies? y a t'il assez de constructors et d'accessors, et sont t'il pertinents? La plupart du temps cela me force repasser par une étape de refactoring dans mon code.

    Est ce la bonne facon de developper? cela dépend des situations, du domaine ou vous travaillez et de vous bien sur.

    Est t'on forcément plus lent? oui et non, cette méthode est déroutante de prime abord mais elle respecte la théorie de l'évolution biologique, génération après génération (refactoring - design - refactoring - unit test) le code devient meilleur.

    Attention: on est pas forcément plus lent, mais cette méthode n'est pas très adaptée au problèmes pointues: on peut se prendre des murs sans cesse (et donc réimplémenter-refactorer) si on ne réflechit pas assez au préalable.

    D'un autre coté, ce qui est certain, c'est que écrire des frameworks est forcément plus long et plus dur que, en caricaturant, faire un main() de 150 lignes (mon dieu, cela se voit encore trop souvent). L'interèt de l'existence d'un framework est dans la réutilisation par d'autres personnes de votre code, et le fait que vous avez deja réalisés pour eux les taches les plus difficiles, mais tout en leur laissant la liberté de spécialiser votre code au besoin.

    Dans les composants java du coté serveur que je réalise pour l'ecommerce d'assurance vie, cela a toujours fonctionné. En tout cas pour moi....

  • The Eclipse Foundation is targeting release of Eclipse 3.1 for late June 2005. There have been seven milestone releases of version 3.1 dating back to August 2004. The Eclipse Requirement Council identified six major themes that the technical community will deliver on:

    • Scaling Up
    • Enterprise Ready
    • Design for Extensibility
    • Rich Client Platform
    • Simple to Use 
    • Appealing to the Broader Community

    As with previous releases, the Eclipse development team is committed to preserving backward compatibility with previous version of Eclipse. Eclipse 3.1 will be compatible with Eclipse 3.0 for API (contract), Binary (plug in), Source and Workspace. Most of the Eclipse SDK is "pure" Java code and has no direct dependence on the underlying operating system. The 3.1 release of the Eclipse Project is written and compiled against version 1.4 of the Java 2 Platform APIs, and targeted to run on version 1.4 of the Java 2 Runtime Environment, Standard Edition.
    Eclipse SDK 3.1 is tested and validated on the following platforms:

    • Microsoft Window XP (Win 32) on Intel x86
    • Red Hat Enterprise Linux WS 3 (GTK) on Intel x86
    • SUSE Linux Enterprise Server 9 (GTK) on Intel x86
    • Sun Solaris 8 (Motif) on SPARC
    • HP-UX 11i (Motif) on hp9000 PA-RISC
    • IBM AIX 5L v5.2 (Motif) on PowerPC
    • Apple Mac OS X 10.3 (Carbon) on PowerPC

    More information about Eclipse 3.1can be found Here