<?xml version="1.0" encoding="UTF-8"?>

<xwikidoc>
<web>Main</web>
<name>Guidelines</name>
<language></language>
<defaultLanguage>en</defaultLanguage>
<translation>0</translation>
<parent>Main.Developers</parent>
<creator>xwiki:XWiki.donsez</creator>
<author>xwiki:XWiki.gabo_pedraza</author>
<contentAuthor>xwiki:XWiki.gabo_pedraza</contentAuthor>
<creationDate>1216847105000</creationDate>
<date>1276504561000</date>
<contentUpdateDate>1276504561000</contentUpdateDate>
<version>1.32</version>
<title>ASPIRE RFID Coding guidelines</title>
<template></template>
<content>1 Coding guidelines

----
#toc("" "" "")
----

1.1 Guideline summary

1.1 Namespaces
1.1.1 Trunk and branches
Sources must be prefixed by the following namespaces.

* Java : &lt;code&gt;org.ow2.aspirerfid&lt;/code&gt;
* Bundles symbolic names : &lt;code&gt;org.ow2.aspirerfid&lt;/code&gt;
* OSGi service.pid prefix: &lt;code&gt;org.ow2.aspirerfid&lt;/code&gt;
* JMX ObjectNames for end-to-end management: &lt;code&gt;org.ow2.aspirerfid:type=~~component~~,name=~~concern~~&lt;/code&gt;
* C# : &lt;code&gt;Org.Ow2.AspireRfid&lt;/code&gt;
* PHP : TODO
* XML (XML Schema) : TODO
* WebServices (WSDL, ...) : TODO
* ...

1.1.1 Sandboxes

* Java : &lt;code&gt;org.ow2.aspirerfid.sandbox&lt;/code&gt;
* Bundles symbolic names : &lt;code&gt;org.ow2.aspirerfid.sandbox&lt;/code&gt;
* C# : &lt;code&gt;org.ow2.aspirerfid.sandbox&lt;/code&gt;
* PHP : TODO
* XML (XML Schema) : TODO
* WebServices (WSDL, ...) : TODO
* ...

1.1 Sub project group and artifact ids 

Names and ids must be prefixed by the following namespaces.
* Artifact/bundle names : &lt;code&gt;OW2 :: AspireRFID ::&lt;/code&gt;
* Artifact ids : &lt;code&gt;org.ow2.aspirerfid.&lt;/code&gt;

1.1 Files
Two mandatory files (NOTICE and LICENSE) must be provided in each project directory
* &lt;code&gt;NOTICE&lt;/code&gt; contains the description of the dependencies and their licenses.
* &lt;code&gt;LICENSE&lt;/code&gt; contains the license text.

Those files are automatically added in the artifact after the package phase

1.1.1 NOTICE file
{pre}
&lt;pre&gt;
OW2 :: AspireRFID :: Foobar Reader
Copyright 2008-2010 OW2 AspireRFID Project http://wiki.aspire.ow2.org

I. Included Software

This product includes software developed at
The OW2 Consortium (http://www.ow2.org/).
Licensed under the LGPL v2.1.

II. Used Software

This product uses software developed at
the FooBar project (http://code.foo.org/bar).
licensed under the Apache License 2.0.

This product uses software developed at
the TicTac project (http://code.tic.org/tac).
licensed under the LGPL v2.1.

III. License Summary
- LGPL v2.1
&lt;/pre&gt;
{/pre}


1.1.1 LICENSE file



1.1 Beginning comments
All source files (Java, XML, ...) must begin with the comments shown in the following code sample.

{pre}
&lt;pre&gt;
/**
 * Copyright (c) 2008-2010, AspireRFID
 *
 * This library is free software; you can redistribute it and/or
 * modify it either under the terms of the GNU Lesser General Public
 * License version 2.1 as published by the Free Software Foundation
 * (the "LGPL"). If you do not alter this
 * notice, a recipient may use your version of this file under the LGPL.
 *
 * You should have received a copy of the LGPL along with this library
 * in the file COPYING-LGPL-2.1; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 *
 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY
 * OF ANY KIND, either express or implied. See the LGPL  for
 * the specific language governing rights and limitations.
 *
 * Contact: AspireRFID mailto:aspirerfid@ow2.org
 */
&lt;/pre&gt;
{/pre}

1.1 Checkstyle

1.1 Dependencies license compatibility and tracking

[Open Source License Checker&gt;http://sourceforge.net/projects/oslc] (oslc) is a tool for inspection and analysis of licence information from open source packages. It audits a code base and provide licenses conflicts. USE IT !

The dependencies must be listed in the NOTICE file.

1.1 References
* Java Code Conventions - Sun Microsystems, Inc. No ref. number, only hyperlink: http://java.sun.com/docs/codeconv/ 

* How to Write Doc Comments for JavaDoc - Sun Microsystems, Inc. http://java.sun.com/products/jdk/javadoc/writingdoccomments.html 

* JavaDoc homepage - Sun Microsystems, Inc. http://java.sun.com/products/jdk/javadoc</content>
<renderedcontent>&lt;h2 class="heading-1"&gt;&lt;span id="HCodingguidelines"&gt;Coding guidelines&lt;/span&gt;&lt;/h2&gt;&lt;p class="paragraph"/&gt;&lt;hr class="line"/&gt;
            &lt;ul&gt;
          &lt;li&gt;&lt;a href="#HGuidelinesummary"&gt; Guideline summary&lt;/a&gt; 
      &lt;li&gt;&lt;a href="#HNamespaces"&gt; Namespaces&lt;/a&gt; 
        &lt;ul&gt;
          &lt;li&gt;&lt;a href="#HTrunkandbranches"&gt; Trunk and branches&lt;/a&gt; 
      &lt;li&gt;&lt;a href="#HSandboxes"&gt; Sandboxes&lt;/a&gt; 
        &lt;/ul&gt;
          &lt;li&gt;&lt;a href="#HSubprojectgroupandartifactids"&gt; Sub project group and artifact ids &lt;/a&gt; 
      &lt;li&gt;&lt;a href="#HFiles"&gt; Files&lt;/a&gt; 
        &lt;ul&gt;
          &lt;li&gt;&lt;a href="#HNOTICEfile"&gt; NOTICE file&lt;/a&gt; 
      &lt;li&gt;&lt;a href="#HLICENSEfile"&gt; LICENSE file&lt;/a&gt; 
        &lt;/ul&gt;
          &lt;li&gt;&lt;a href="#HBeginningcomments"&gt; Beginning comments&lt;/a&gt; 
      &lt;li&gt;&lt;a href="#HCheckstyle"&gt; Checkstyle&lt;/a&gt; 
      &lt;li&gt;&lt;a href="#HDependencieslicensecompatibilityandtracking"&gt; Dependencies license compatibility and tracking&lt;/a&gt; 
      &lt;li&gt;&lt;a href="#HReferences"&gt; References&lt;/a&gt; 
      &lt;/ul&gt; &lt;hr class="line"/&gt;
&lt;h3 class="heading-1-1"&gt;&lt;span id="HGuidelinesummary"&gt;Guideline summary&lt;/span&gt;&lt;/h3&gt; 
&lt;h3 class="heading-1-1"&gt;&lt;span id="HNamespaces"&gt;Namespaces&lt;/span&gt;&lt;/h3&gt; 
&lt;h4 class="heading-1-1-1"&gt;&lt;span id="HTrunkandbranches"&gt;Trunk and branches&lt;/span&gt;&lt;/h4&gt; 
Sources must be prefixed by the following namespaces.
&lt;ul class="star"&gt;
&lt;li&gt;Java : &lt;code&gt;org.ow2.aspirerfid&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Bundles symbolic names : &lt;code&gt;org.ow2.aspirerfid&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;OSGi service.pid prefix: &lt;code&gt;org.ow2.aspirerfid&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;JMX ObjectNames for end-to-end management: &lt;code&gt;org.ow2.aspirerfid:type=&lt;i class="italic"&gt;component&lt;/i&gt;,name=&lt;i class="italic"&gt;concern&lt;/i&gt;&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;C# : &lt;code&gt;Org.Ow2.AspireRfid&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;PHP : TODO&lt;/li&gt;
&lt;li&gt;XML (XML Schema) : TODO&lt;/li&gt;
&lt;li&gt;WebServices (WSDL, ...) : TODO&lt;/li&gt;
&lt;li&gt;...&lt;/li&gt;
&lt;/ul&gt;&lt;h4 class="heading-1-1-1"&gt;&lt;span id="HSandboxes"&gt;Sandboxes&lt;/span&gt;&lt;/h4&gt; 
&lt;ul class="star"&gt;
&lt;li&gt;Java : &lt;code&gt;org.ow2.aspirerfid.sandbox&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Bundles symbolic names : &lt;code&gt;org.ow2.aspirerfid.sandbox&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;C# : &lt;code&gt;org.ow2.aspirerfid.sandbox&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;PHP : TODO&lt;/li&gt;
&lt;li&gt;XML (XML Schema) : TODO&lt;/li&gt;
&lt;li&gt;WebServices (WSDL, ...) : TODO&lt;/li&gt;
&lt;li&gt;...&lt;/li&gt;
&lt;/ul&gt;&lt;h3 class="heading-1-1"&gt;&lt;span id="HSubprojectgroupandartifactids"&gt;Sub project group and artifact ids &lt;/span&gt;&lt;/h3&gt;&lt;p class="paragraph"/&gt;Names and ids must be prefixed by the following namespaces.
&lt;ul class="star"&gt;
&lt;li&gt;Artifact/bundle names : &lt;code&gt;OW2 :: AspireRFID ::&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;Artifact ids : &lt;code&gt;org.ow2.aspirerfid.&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;h3 class="heading-1-1"&gt;&lt;span id="HFiles"&gt;Files&lt;/span&gt;&lt;/h3&gt; 
Two mandatory files (NOTICE and LICENSE) must be provided in each project directory
&lt;ul class="star"&gt;
&lt;li&gt;&lt;code&gt;NOTICE&lt;/code&gt; contains the description of the dependencies and their licenses.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;LICENSE&lt;/code&gt; contains the license text.&lt;/li&gt;
&lt;/ul&gt;Those files are automatically added in the artifact after the package phase
&lt;h4 class="heading-1-1-1"&gt;&lt;span id="HNOTICEfile"&gt;NOTICE file&lt;/span&gt;&lt;/h4&gt; 

&lt;pre&gt;
OW2 :: AspireRFID :: Foobar Reader
Copyright 2008-2010 OW2 AspireRFID Project http://wiki.aspire.ow2.org

I. Included Software

This product includes software developed at
The OW2 Consortium (http://www.ow2.org/).
Licensed under the LGPL v2.1.

II. Used Software

This product uses software developed at
the FooBar project (http://code.foo.org/bar).
licensed under the Apache License 2.0.

This product uses software developed at
the TicTac project (http://code.tic.org/tac).
licensed under the LGPL v2.1.

III. License Summary
- LGPL v2.1
&lt;/pre&gt;

&lt;h4 class="heading-1-1-1"&gt;&lt;span id="HLICENSEfile"&gt;LICENSE file&lt;/span&gt;&lt;/h4&gt; 
&lt;h3 class="heading-1-1"&gt;&lt;span id="HBeginningcomments"&gt;Beginning comments&lt;/span&gt;&lt;/h3&gt; 
All source files (Java, XML, ...) must begin with the comments shown in the following code sample.&lt;p class="paragraph"/&gt;
&lt;pre&gt;
/**
 * Copyright (c) 2008-2010, AspireRFID
 *
 * This library is free software; you can redistribute it and/or
 * modify it either under the terms of the GNU Lesser General Public
 * License version 2.1 as published by the Free Software Foundation
 * (the "LGPL"). If you do not alter this
 * notice, a recipient may use your version of this file under the LGPL.
 *
 * You should have received a copy of the LGPL along with this library
 * in the file COPYING-LGPL-2.1; if not, write to the Free Software
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 *
 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY
 * OF ANY KIND, either express or implied. See the LGPL  for
 * the specific language governing rights and limitations.
 *
 * Contact: AspireRFID mailto:aspirerfid@ow2.org
 */
&lt;/pre&gt;

&lt;h3 class="heading-1-1"&gt;&lt;span id="HCheckstyle"&gt;Checkstyle&lt;/span&gt;&lt;/h3&gt; 
&lt;h3 class="heading-1-1"&gt;&lt;span id="HDependencieslicensecompatibilityandtracking"&gt;Dependencies license compatibility and tracking&lt;/span&gt;&lt;/h3&gt;&lt;p class="paragraph"/&gt;&lt;span class="wikiexternallink"&gt;&lt;a href="http://sourceforge.net/projects/oslc"&gt;&amp;#79;pen Source License Checker&lt;/a&gt;&lt;/span&gt; (oslc) is a tool for inspection and analysis of licence information from open source packages. It audits a code base and provide licenses conflicts. USE IT !&lt;p class="paragraph"/&gt;The dependencies must be listed in the NOTICE file.
&lt;h3 class="heading-1-1"&gt;&lt;span id="HReferences"&gt;References&lt;/span&gt;&lt;/h3&gt; 
&lt;ul class="star"&gt;
&lt;li&gt;Java Code Conventions - Sun Microsystems, Inc. No ref. number, only hyperlink: &lt;span class="nobr"&gt;&lt;a href="http://java.sun.com/docs/codeconv/"&gt;&amp;#104;ttp://java.sun.com/docs/codeconv/&lt;/a&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;How to Write Doc Comments for JavaDoc - Sun Microsystems, Inc. &lt;span class="nobr"&gt;&lt;a href="http://java.sun.com/products/jdk/javadoc/writingdoccomments.html"&gt;&amp;#104;ttp://java.sun.com/products/jdk/javadoc/writingdoccomments.html&lt;/a&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li&gt;JavaDoc homepage - Sun Microsystems, Inc. &lt;span class="nobr"&gt;&lt;a href="http://java.sun.com/products/jdk/javadoc"&gt;&amp;#104;ttp://java.sun.com/products/jdk/javadoc&lt;/a&gt;&lt;/span&gt;&lt;/li&gt;
&lt;/ul&gt;
</renderedcontent>
</xwikidoc>