← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 20923: Renamed ADX* classes to Adx* according to java naming conventions.

 

------------------------------------------------------------
revno: 20923
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Mon 2015-11-02 12:05:15 -0500
message:
  Renamed ADX* classes to Adx* according to java naming conventions.
renamed:
  dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/ADXDataService.java => dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxDataService.java
  dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/ADXException.java => dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxException.java
  dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/ADXPeriod.java => dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxPeriod.java
  dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/DefaultADXDataService.java => dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/DefaultAdxDataService.java
  dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/adx/ADXPeriodTest.java => dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/adx/AdxPeriodTest.java
  dhis-2/dhis-web/dhis-web-ohie/src/main/java/org/hisp/dhis/web/ohie/adx/webapi/ADXController.java => dhis-2/dhis-web/dhis-web-ohie/src/main/java/org/hisp/dhis/web/ohie/adx/webapi/AdxController.java
modified:
  dhis-2/dhis-services/dhis-service-dxf2/src/main/resources/META-INF/dhis/beans.xml
  dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxDataService.java
  dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxException.java
  dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxPeriod.java
  dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/DefaultAdxDataService.java
  dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/adx/AdxPeriodTest.java
  dhis-2/dhis-web/dhis-web-ohie/src/main/java/org/hisp/dhis/web/ohie/adx/webapi/AdxController.java


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== renamed file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/ADXDataService.java' => 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxDataService.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/ADXDataService.java	2015-10-02 08:02:51 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxDataService.java	2015-11-02 17:05:15 +0000
@@ -1,34 +1,31 @@
 package org.hisp.dhis.dxf2.adx;
 
 /*
- * Copyright (c) 2004-2015, University of Oslo
+ * Copyright (c) 2015, UiO
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
  * modification, are permitted provided that the following conditions are met:
- * Redistributions of source code must retain the above copyright notice, this
- * list of conditions and the following disclaimer.
- *
- * Redistributions in binary form must reproduce the above copyright notice,
- * this list of conditions and the following disclaimer in the documentation
- * and/or other materials provided with the distribution.
- * Neither the name of the HISP project nor the names of its contributors may
- * be used to endorse or promote products derived from this software without
- * specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
- * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
- * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
- * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
- * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * * Redistributions of source code must retain the above copyright notice, this
+ *   list of conditions and the following disclaimer.
+ * * Redistributions in binary form must reproduce the above copyright notice,
+ *   this list of conditions and the following disclaimer in the documentation
+ *   and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
+ * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
  */
 
-import java.io.IOException;
 import java.io.InputStream;
 import java.io.OutputStream;
 
@@ -39,7 +36,7 @@
 /**
  * @author bobj
  */
-public interface ADXDataService
+public interface AdxDataService
 {
     //--------------------------------------------------------------------------
     // ADX standard constants
@@ -68,17 +65,14 @@
     //--------------------------------------------------------------------------
 
     /**
-     * Post data.
-     * 
-     * Takes ADX Data from input stream and saves a series of DXF2 DataValueSets
-     * 
-     * @param in  The InputStream - typically from servlet HTTP response
-     * @param importOptions  The importOptions - typically from the servlet request
-     * @return an ImportSummaries collection of ImportSummary for each DataValueSet
-     * @throws IOException
+     * Post data. Takes ADX Data from input stream and saves a series of DXF2 
+     * DataValueSets.
+     * 
+     * @param in the InputStream.
+     * @param importOptions the importOptions.
+     * @return an ImportSummaries collection of ImportSummary for each DataValueSet.
      */
-    ImportSummaries postData( InputStream in, ImportOptions importOptions )
-        throws IOException;
+    ImportSummaries postData( InputStream in, ImportOptions importOptions );
 
     void getData( DataExportParams params, OutputStream out );
 }

=== renamed file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/ADXException.java' => 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxException.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/ADXException.java	2015-09-13 21:54:23 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxException.java	2015-11-02 17:05:15 +0000
@@ -29,11 +29,11 @@
 import org.hisp.dhis.dxf2.importsummary.ImportConflict;
 
 /**
- * Simple class for ADX checked exceptions which can wrap an ImportConflict
+ * Simple class for ADX checked exceptions which can wrap an ImportConflict.
  * 
  * @author bobj
  */
-public class ADXException
+public class AdxException
     extends Exception
 {
     protected String object;
@@ -43,16 +43,16 @@
         return object;
     }
 
-    public ADXException()
+    public AdxException()
     {
     }
     
-    public ADXException( String msg )
+    public AdxException( String msg )
     {
         super( msg );
     }
 
-    public ADXException( String object, String msg )
+    public AdxException( String object, String msg )
     {
         super( msg );
         this.object = object;

=== renamed file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/ADXPeriod.java' => 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxPeriod.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/ADXPeriod.java	2015-09-13 21:54:23 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/AdxPeriod.java	2015-11-02 17:05:15 +0000
@@ -54,9 +54,8 @@
  *
  * @author bobj
  */
-public class ADXPeriod
+public class AdxPeriod
 {
-
     public static enum Duration
     {
         P1D, // daily
@@ -70,13 +69,14 @@
 
     private static final SimpleDateFormat DATE_FORMAT = new SimpleDateFormat( "yyyy-MM-dd" );
 
-    public static Period parse( String periodString ) throws ADXException
+    public static Period parse( String periodString ) 
+        throws AdxException
     {
         String[] tokens = periodString.split( "/" );
         
         if ( tokens.length != 2 )
         {
-            throw new ADXException( periodString + " not in valid <date>/<duration> format" );
+            throw new AdxException( periodString + " not in valid <date>/<duration> format" );
         }
 
         try
@@ -115,7 +115,7 @@
                             periodType = new SixMonthlyAprilPeriodType();
                             break;
                         default:
-                            throw new ADXException( periodString + "is invalid sixmonthly type" );
+                            throw new AdxException( periodString + "is invalid sixmonthly type" );
                     }
                 case P1Y:
                     switch ( cal.get( Calendar.MONTH ) )
@@ -133,7 +133,7 @@
                             periodType = new FinancialOctoberPeriodType();
                             break;
                         default:
-                            throw new ADXException( periodString + "is invalid yearly type" );
+                            throw new AdxException( periodString + "is invalid yearly type" );
                     }
             }
 
@@ -143,7 +143,7 @@
             } 
             else
             {
-                throw new ADXException( "Failed to create period type from " + duration );
+                throw new AdxException( "Failed to create period type from " + duration );
             }
 
             return period;
@@ -151,11 +151,11 @@
         } 
         catch ( ParseException ex )
         {
-            throw new ADXException( tokens[0] + "is not a valid date in YYYY-MM-dd format" );
+            throw new AdxException( tokens[0] + "is not a valid date in YYYY-MM-dd format" );
         } 
         catch ( IllegalArgumentException ex )
         {
-            throw new ADXException( tokens[1] + " is not a supported duration type" );
+            throw new AdxException( tokens[1] + " is not a supported duration type" );
         }
     }
 

=== renamed file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/DefaultADXDataService.java' => 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/DefaultAdxDataService.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/DefaultADXDataService.java	2015-10-02 08:28:58 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/adx/DefaultAdxDataService.java	2015-11-02 17:05:15 +0000
@@ -82,10 +82,10 @@
 /**
  * @author bobj
  */
-public class DefaultADXDataService
-    implements ADXDataService
+public class DefaultAdxDataService
+    implements AdxDataService
 {
-    private static final Log log = LogFactory.getLog( DefaultADXDataService.class );
+    private static final Log log = LogFactory.getLog( DefaultAdxDataService.class );
 
     // -------------------------------------------------------------------------
     // Constants
@@ -129,14 +129,14 @@
 
         ImportSummaries importSummaries = new ImportSummaries();
 
-        adxReader.moveToStartElement( ADXDataService.ROOT, ADXDataService.NAMESPACE );
+        adxReader.moveToStartElement( AdxDataService.ROOT, AdxDataService.NAMESPACE );
 
         ExecutorService executor = Executors.newSingleThreadExecutor();
 
         int count = 0;
         
         // submit each ADX group to DXF importer as a datavalueSet
-        while ( adxReader.moveToStartElement( ADXDataService.GROUP, ADXDataService.NAMESPACE ) )
+        while ( adxReader.moveToStartElement( AdxDataService.GROUP, AdxDataService.NAMESPACE ) )
         {
             try ( PipedOutputStream pipeOut = new PipedOutputStream() )
             {
@@ -160,7 +160,7 @@
                 }
                 importSummaries.addImportSummary( summary );
             }
-            catch ( ADXException ex)
+            catch ( AdxException ex)
             {
                 ImportSummary importSummary = new ImportSummary();
                 importSummary.setStatus( ImportStatus.ERROR );
@@ -190,7 +190,7 @@
     // -------------------------------------------------------------------------
 
     private List<ImportConflict> parseADXGroupToDxf( XMLReader adxReader, XMLStreamWriter dxfWriter, ImportOptions importOptions )
-        throws XMLStreamException, ADXException
+        throws XMLStreamException, AdxException
     {
         List<ImportConflict> adxConflicts = new LinkedList<>();
         
@@ -202,38 +202,39 @@
 
         Map<String, String> groupAttributes = readAttributes( adxReader );
 
-        if ( !groupAttributes.containsKey( ADXDataService.PERIOD ) )
+        if ( !groupAttributes.containsKey( AdxDataService.PERIOD ) )
         {
-            throw new ADXException( ADXDataService.PERIOD + " attribute is required on 'group'" );
+            throw new AdxException( AdxDataService.PERIOD + " attribute is required on 'group'" );
         }
 
-        if ( !groupAttributes.containsKey( ADXDataService.ORGUNIT ) )
+        if ( !groupAttributes.containsKey( AdxDataService.ORGUNIT ) )
         {
-            throw new ADXException( ADXDataService.ORGUNIT + " attribute is required on 'group'" );
+            throw new AdxException( AdxDataService.ORGUNIT + " attribute is required on 'group'" );
         }
 
         // translate ADX period to dxf2
-        String periodStr = groupAttributes.get( ADXDataService.PERIOD );
-        groupAttributes.remove( ADXDataService.PERIOD );
-        Period period = ADXPeriod.parse( periodStr );
-        groupAttributes.put( ADXDataService.PERIOD, period.getIsoDate());
+        String periodStr = groupAttributes.get( AdxDataService.PERIOD );
+        groupAttributes.remove( AdxDataService.PERIOD );
+        Period period = AdxPeriod.parse( periodStr );
+        groupAttributes.put( AdxDataService.PERIOD, period.getIsoDate());
 
         // process ADX group attributes
-        if ( !groupAttributes.containsKey( ADXDataService.ATTOPTCOMBO )
-            && groupAttributes.containsKey( ADXDataService.DATASET ) )
+        if ( !groupAttributes.containsKey( AdxDataService.ATTOPTCOMBO )
+            && groupAttributes.containsKey( AdxDataService.DATASET ) )
         {
             log.debug( "No attributeOptionCombo present.  Check dataSet for attribute categorycombo" );
 
             DataSet dataSet = identifiableObjectManager.getObject( DataSet.class, dataElementIdScheme,
-                groupAttributes.get( ADXDataService.DATASET ) );
+                groupAttributes.get( AdxDataService.DATASET ) );
             
             if (dataSet == null)
             {
-                throw new ADXException("No dataSet matching identifier: " + groupAttributes.get( ADXDataService.DATASET ));
+                throw new AdxException("No dataSet matching identifier: " + groupAttributes.get( AdxDataService.DATASET ));
             }
-            groupAttributes.put( ADXDataService.DATASET, dataSet.getUid() );
+            
+            groupAttributes.put( AdxDataService.DATASET, dataSet.getUid() );
             DataElementCategoryCombo attributeCombo = dataSet.getCategoryCombo();
-            attributesToDXF( ADXDataService.ATTOPTCOMBO, attributeCombo, groupAttributes, dataElementIdScheme );
+            attributesToDXF( AdxDataService.ATTOPTCOMBO, attributeCombo, groupAttributes, dataElementIdScheme );
         }
 
         // write the remaining attributes through to DXF stream
@@ -243,13 +244,13 @@
         }
 
         // process the dataValues
-        while ( adxReader.moveToStartElement( ADXDataService.DATAVALUE, ADXDataService.GROUP ) )
+        while ( adxReader.moveToStartElement( AdxDataService.DATAVALUE, AdxDataService.GROUP ) )
         {
             try 
             {
                 parseADXDataValueToDxf( adxReader, dxfWriter, importOptions );
             }
-            catch (ADXException ex)
+            catch (AdxException ex)
             {
                 adxConflicts.add( ex.getImportConflict() );
                 log.info("ADX datavalue conflict: " + ex.getImportConflict());
@@ -263,52 +264,52 @@
     }
 
     private void parseADXDataValueToDxf( XMLReader adxReader, XMLStreamWriter dxfWriter, ImportOptions importOptions )
-        throws XMLStreamException, ADXException
+        throws XMLStreamException, AdxException
     {
         Map<String, String> dvAttributes = readAttributes( adxReader );
         
         log.debug("Processing datavalue: " + dvAttributes );
         
-        if ( !dvAttributes.containsKey( ADXDataService.DATAELEMENT ) )
+        if ( !dvAttributes.containsKey( AdxDataService.DATAELEMENT ) )
         {
-            throw new ADXException( ADXDataService.DATAELEMENT + " attribute is required on 'dataValue'" );
+            throw new AdxException( AdxDataService.DATAELEMENT + " attribute is required on 'dataValue'" );
         }
 
-        if ( !dvAttributes.containsKey( ADXDataService.VALUE ) )
+        if ( !dvAttributes.containsKey( AdxDataService.VALUE ) )
         {
-            throw new ADXException( ADXDataService.VALUE + " attribute is required on 'dataValue'" );
+            throw new AdxException( AdxDataService.VALUE + " attribute is required on 'dataValue'" );
         }
 
         IdentifiableProperty dataElementIdScheme = importOptions.getDataElementIdScheme();
 
-        DataElement dataElement = identifiableObjectManager.getObject( DataElement.class, dataElementIdScheme,dvAttributes.get( ADXDataService.DATAELEMENT));
+        DataElement dataElement = identifiableObjectManager.getObject( DataElement.class, dataElementIdScheme,dvAttributes.get( AdxDataService.DATAELEMENT));
         
         if ( dataElement == null )
         {
-            throw new ADXException(dvAttributes.get( ADXDataService.DATAELEMENT), "No matching dataelement");
+            throw new AdxException(dvAttributes.get( AdxDataService.DATAELEMENT), "No matching dataelement");
         }
         
         // process ADX data value attributes
-        if ( !dvAttributes.containsKey( ADXDataService.CATOPTCOMBO ) )
+        if ( !dvAttributes.containsKey( AdxDataService.CATOPTCOMBO ) )
         {
             log.debug( "No categoryOptionCombo present." );
             DataElementCategoryCombo categoryCombo = dataElement.getCategoryCombo();
 
-            attributesToDXF( ADXDataService.CATOPTCOMBO, categoryCombo, dvAttributes, dataElementIdScheme );
+            attributesToDXF( AdxDataService.CATOPTCOMBO, categoryCombo, dvAttributes, dataElementIdScheme );
         }
         
         // if data element type is string we need to pick out the 'annotation' element
         if ( dataElement.getValueType().isText() )
         {
-            adxReader.moveToStartElement( ADXDataService.ANNOTATION, ADXDataService.DATAVALUE );
-            if ( adxReader.isStartElement( ADXDataService.ANNOTATION ) )
+            adxReader.moveToStartElement( AdxDataService.ANNOTATION, AdxDataService.DATAVALUE );
+            if ( adxReader.isStartElement( AdxDataService.ANNOTATION ) )
             {
                 String textValue = adxReader.getElementValue();
-                dvAttributes.put( ADXDataService.VALUE, textValue );
+                dvAttributes.put( AdxDataService.VALUE, textValue );
             }
             else
             {
-                throw new ADXException( dvAttributes.get( ADXDataService.DATAELEMENT),"Dataelement expects text annotation" );
+                throw new AdxException( dvAttributes.get( AdxDataService.DATAELEMENT),"Dataelement expects text annotation" );
             }
         }
         
@@ -325,7 +326,7 @@
     }
 
     private Map<String, DataElementCategory> createCategoryMap( DataElementCategoryCombo catcombo )
-        throws ADXException
+        throws AdxException
     {
         Map<String, DataElementCategory> categoryMap = new HashMap<>();
 
@@ -337,7 +338,7 @@
             
             if ( categoryCode == null || !XMLChar.isValidName( categoryCode ) )
             {
-                throw new ADXException( "Category code for " + category.getName() + " is missing or invalid: "
+                throw new AdxException( "Category code for " + category.getName() + " is missing or invalid: "
                     + categoryCode );
             }
             
@@ -349,7 +350,7 @@
 
     private DataElementCategoryOptionCombo getCatOptComboFromAttributes( Map<String, String> attributes,
         DataElementCategoryCombo catcombo, IdentifiableProperty scheme )
-        throws ADXException
+        throws AdxException
     {
         CategoryComboMap catcomboMap;
         
@@ -362,7 +363,7 @@
         catch ( CategoryComboMapException ex )
         {
             log.info( "Failed to create catcomboMap from " + catcombo );
-            throw new ADXException( ex.getMessage() );
+            throw new AdxException( ex.getMessage() );
         }
 
         String compositeIdentifier = StringUtils.EMPTY;
@@ -373,14 +374,14 @@
             
             if ( catCode == null )
             {
-                throw new ADXException( "No category matching " + catCode );
+                throw new AdxException( "No category matching " + catCode );
             }
             
             String catAttribute = attributes.get( catCode );
             
             if ( catAttribute == null )
             {
-                throw new ADXException( "Missing required attribute from catcombo: " + catCode );
+                throw new AdxException( "Missing required attribute from catcombo: " + catCode );
             }
             
             compositeIdentifier += "\"" + catAttribute + "\"";
@@ -390,7 +391,7 @@
 
         if ( catoptcombo == null )
         {
-            throw new ADXException( "Invalid attributes:" + attributes );
+            throw new AdxException( "Invalid attributes:" + attributes );
         }
         
         return catoptcombo;
@@ -398,7 +399,7 @@
 
     private void attributesToDXF( String optionComboName, DataElementCategoryCombo catCombo,
         Map<String, String> attributes, IdentifiableProperty scheme )
-        throws ADXException
+        throws AdxException
     {
         log.debug( "adx attributes: " + attributes );
 
@@ -420,7 +421,7 @@
             }
             else
             {
-                throw new ADXException( "catcombo " + catCombo.getName() + " must have " + categoryMap.get( category ).getName() );
+                throw new AdxException( "catcombo " + catCombo.getName() + " must have " + categoryMap.get( category ).getName() );
             }
         }
 

=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/resources/META-INF/dhis/beans.xml'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/resources/META-INF/dhis/beans.xml	2015-11-02 04:27:25 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/resources/META-INF/dhis/beans.xml	2015-11-02 17:05:15 +0000
@@ -326,9 +326,6 @@
 
   <bean id="inputUtils" class="org.hisp.dhis.dxf2.utils.InputUtils" />
   
-  <!-- ADX Service -->
-
-  <bean id="org.hisp.dhis.dxf2.ADXDataService"
-    class="org.hisp.dhis.dxf2.adx.DefaultADXDataService" />    
+  <bean id="org.hisp.dhis.dxf2.AdxDataService" class="org.hisp.dhis.dxf2.adx.DefaultAdxDataService" />    
 
 </beans>

=== renamed file 'dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/adx/ADXPeriodTest.java' => 'dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/adx/AdxPeriodTest.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/adx/ADXPeriodTest.java	2015-09-13 21:54:23 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/adx/AdxPeriodTest.java	2015-11-02 17:05:15 +0000
@@ -37,11 +37,11 @@
  *
  * @author bobj
  */
-public class ADXPeriodTest
+public class AdxPeriodTest
 {
     private Period period;
 
-    public ADXPeriodTest()
+    public AdxPeriodTest()
     {
     }
 
@@ -50,22 +50,22 @@
     {
         try 
         {
-            period = ADXPeriod.parse( "2015-01-01/P1Y" );
+            period = AdxPeriod.parse( "2015-01-01/P1Y" );
             assertEquals( "2015", period.getIsoDate() );
-            period = ADXPeriod.parse( "2015-01-01/P1M" );
+            period = AdxPeriod.parse( "2015-01-01/P1M" );
             assertEquals( "201501", period.getIsoDate() );
-            period = ADXPeriod.parse( "2015-01-01/P1D" );
+            period = AdxPeriod.parse( "2015-01-01/P1D" );
             assertEquals( "20150101", period.getIsoDate() );
-            period = ADXPeriod.parse( "2015-01-01/P1Q" );
+            period = AdxPeriod.parse( "2015-01-01/P1Q" );
             assertEquals( "2015Q1", period.getIsoDate() );
-            period = ADXPeriod.parse( "2015-04-01/P1Q" );
+            period = AdxPeriod.parse( "2015-04-01/P1Q" );
             assertEquals( "2015Q2", period.getIsoDate() );
-            period = ADXPeriod.parse( "2015-01-01/P7D" );
+            period = AdxPeriod.parse( "2015-01-01/P7D" );
             assertEquals( "2015W1", period.getIsoDate() );
-            period = ADXPeriod.parse( "2015-01-05/P7D" );
+            period = AdxPeriod.parse( "2015-01-05/P7D" );
             assertEquals( "2015W2", period.getIsoDate() );
         }
-        catch (ADXException ex)
+        catch ( AdxException ex)
         {
             fail(ex.getMessage());
         }
@@ -76,12 +76,12 @@
     {
         try
         {
-            period = ADXPeriod.parse( "2014-01-01/P1" );
+            period = AdxPeriod.parse( "2014-01-01/P1" );
             fail( "Should have thrown exception parsing 2015-01-01/P1" );
         } 
         catch ( Exception ex )
         {
-            assertEquals( ADXException.class, ex.getClass() );
+            assertEquals( AdxException.class, ex.getClass() );
         }
     }
 
@@ -90,16 +90,16 @@
     {
         try
         {
-            period = ADXPeriod.parse( "2015-01-01/P1Y" );
+            period = AdxPeriod.parse( "2015-01-01/P1Y" );
             assertEquals( "2015", period.getIsoDate() );
-            period = ADXPeriod.parse( "2015-04-01/P1Y" );
+            period = AdxPeriod.parse( "2015-04-01/P1Y" );
             assertEquals( "2015April", period.getIsoDate() );
-            period = ADXPeriod.parse( "2015-07-01/P1Y" );
+            period = AdxPeriod.parse( "2015-07-01/P1Y" );
             assertEquals( "2015July", period.getIsoDate() );
-            period = ADXPeriod.parse( "2015-10-01/P1Y" );
+            period = AdxPeriod.parse( "2015-10-01/P1Y" );
             assertEquals( "2015Oct", period.getIsoDate() );
         }
-        catch (ADXException ex)
+        catch ( AdxException ex)
         {
             fail(ex.getMessage());
         }
@@ -110,12 +110,12 @@
     {
         try
         {
-            period = ADXPeriod.parse( "2014-02-01/P1Y" );
+            period = AdxPeriod.parse( "2014-02-01/P1Y" );
             fail( "Should have thrown exception parsing 2014-02-01/P1Y" );
         } 
         catch ( Exception ex )
         {
-            assertEquals( ADXException.class, ex.getClass() );
+            assertEquals( AdxException.class, ex.getClass() );
         }
     }
 
@@ -123,18 +123,18 @@
     public void testSerialize()
     {
         period = PeriodType.getPeriodFromIsoString( "2015" );
-        assertEquals( "2015-01-01/P1Y", ADXPeriod.serialize( period ) );
+        assertEquals( "2015-01-01/P1Y", AdxPeriod.serialize( period ) );
         period = PeriodType.getPeriodFromIsoString( "201503" );
-        assertEquals( "2015-03-01/P1M", ADXPeriod.serialize( period ) );
+        assertEquals( "2015-03-01/P1M", AdxPeriod.serialize( period ) );
         period = PeriodType.getPeriodFromIsoString( "2015W1" );
-        assertEquals( "2014-12-29/P7D", ADXPeriod.serialize( period ) );
+        assertEquals( "2014-12-29/P7D", AdxPeriod.serialize( period ) );
         period = PeriodType.getPeriodFromIsoString( "2015Q2" );
-        assertEquals( "2015-04-01/P1Q", ADXPeriod.serialize( period ) );
+        assertEquals( "2015-04-01/P1Q", AdxPeriod.serialize( period ) );
         period = PeriodType.getPeriodFromIsoString( "2015April" );
-        assertEquals( "2015-04-01/P1Y", ADXPeriod.serialize( period ) );
+        assertEquals( "2015-04-01/P1Y", AdxPeriod.serialize( period ) );
         period = PeriodType.getPeriodFromIsoString( "2015S2" );
-        assertEquals( "2015-07-01/P6M", ADXPeriod.serialize( period ) );
+        assertEquals( "2015-07-01/P6M", AdxPeriod.serialize( period ) );
         period = PeriodType.getPeriodFromIsoString( "2015AprilS2" );
-        assertEquals( "2015-10-01/P6M", ADXPeriod.serialize( period ) );
+        assertEquals( "2015-10-01/P6M", AdxPeriod.serialize( period ) );
     }
 }

=== renamed file 'dhis-2/dhis-web/dhis-web-ohie/src/main/java/org/hisp/dhis/web/ohie/adx/webapi/ADXController.java' => 'dhis-2/dhis-web/dhis-web-ohie/src/main/java/org/hisp/dhis/web/ohie/adx/webapi/AdxController.java'
--- dhis-2/dhis-web/dhis-web-ohie/src/main/java/org/hisp/dhis/web/ohie/adx/webapi/ADXController.java	2015-07-03 16:31:04 +0000
+++ dhis-2/dhis-web/dhis-web-ohie/src/main/java/org/hisp/dhis/web/ohie/adx/webapi/AdxController.java	2015-11-02 17:05:15 +0000
@@ -41,7 +41,7 @@
 import javax.servlet.http.HttpServletResponse;
 import java.io.IOException;
 import java.io.InputStream;
-import org.hisp.dhis.dxf2.adx.ADXDataService;
+import org.hisp.dhis.dxf2.adx.AdxDataService;
 import org.hisp.dhis.dxf2.common.JacksonUtils;
 import org.hisp.dhis.dxf2.importsummary.ImportSummaries;
 
@@ -53,15 +53,15 @@
  */
 
 @Controller
-@RequestMapping( value = ADXController.RESOURCE_PATH )
-public class ADXController
+@RequestMapping( value = AdxController.RESOURCE_PATH )
+public class AdxController
 {
     public static final String RESOURCE_PATH = "/dataValueSets";
 
-    private static final Log log = LogFactory.getLog( ADXController.class );
+    private static final Log log = LogFactory.getLog( AdxController.class );
 
     @Autowired
-    private ADXDataService adxService;
+    private AdxDataService adxService;
 
     @RequestMapping( method = RequestMethod.POST, consumes = "application/xml" )
     @PreAuthorize( "hasRole('ALL') or hasRole('F_DATAVALUE_ADD')" )