← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 17547: minor cleanup, remove persisted/owner information from node annotations, not in use anymore

 

------------------------------------------------------------
revno: 17547
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2014-11-20 16:20:30 +0700
message:
  minor cleanup, remove persisted/owner information from node annotations, not in use anymore
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeCollection.java
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeComplex.java
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeRoot.java
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeSimple.java
  dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/schema/NodePropertyIntrospectorService.java
  dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldCollectionNodePropertyIntrospectorServiceTest.java
  dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldComplexNodePropertyIntrospectorServiceTest.java
  dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldSimpleNodePropertyIntrospectorServiceTest.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
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeCollection.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeCollection.java	2014-08-16 14:30:22 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeCollection.java	2014-11-20 09:20:30 +0000
@@ -51,10 +51,6 @@
 
     boolean useWrapping() default true;
 
-    boolean isPersisted() default true;
-
-    boolean isOwner() default false;
-
     boolean isWritable() default true;
 
     boolean isReadable() default true;

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeComplex.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeComplex.java	2014-08-16 14:30:22 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeComplex.java	2014-11-20 09:20:30 +0000
@@ -45,10 +45,6 @@
 
     String namespace() default "";
 
-    boolean isPersisted() default true;
-
-    boolean isOwner() default false;
-
     boolean isWritable() default true;
 
     boolean isReadable() default true;

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeRoot.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeRoot.java	2014-06-17 09:21:14 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeRoot.java	2014-11-20 09:20:30 +0000
@@ -45,8 +45,6 @@
 
     String namespace() default "";
 
-    boolean isPersisted() default true;
-
     boolean isWritable() default true;
 
     boolean isReadable() default true;

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeSimple.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeSimple.java	2014-08-16 14:30:22 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/node/annotation/NodeSimple.java	2014-11-20 09:20:30 +0000
@@ -47,8 +47,6 @@
 
     boolean isAttribute() default false;
 
-    boolean isPersisted() default true;
-
     boolean isWritable() default true;
 
     boolean isReadable() default true;

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/schema/NodePropertyIntrospectorService.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/schema/NodePropertyIntrospectorService.java	2014-08-20 05:24:14 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/schema/NodePropertyIntrospectorService.java	2014-11-20 09:20:30 +0000
@@ -149,7 +149,6 @@
     {
         property.setSimple( true );
         property.setAttribute( nodeSimple.isAttribute() );
-        property.setPersisted( nodeSimple.isPersisted() );
         property.setNamespace( nodeSimple.namespace() );
         property.setWritable( nodeSimple.isWritable() );
         property.setReadable( nodeSimple.isReadable() );
@@ -173,7 +172,6 @@
     private void handleNodeComplex( NodeComplex nodeComplex, Property property )
     {
         property.setSimple( false );
-        property.setPersisted( nodeComplex.isPersisted() );
         property.setNamespace( nodeComplex.namespace() );
         property.setWritable( nodeComplex.isWritable() );
         property.setReadable( nodeComplex.isReadable() );
@@ -198,7 +196,6 @@
     {
         property.setCollectionWrapping( nodeCollection.useWrapping() );
         property.setNamespace( nodeCollection.namespace() );
-        property.setPersisted( nodeCollection.isPersisted() );
         property.setWritable( nodeCollection.isWritable() );
         property.setReadable( nodeCollection.isReadable() );
 

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldCollectionNodePropertyIntrospectorServiceTest.java'
--- dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldCollectionNodePropertyIntrospectorServiceTest.java	2014-08-20 05:24:14 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldCollectionNodePropertyIntrospectorServiceTest.java	2014-11-20 09:20:30 +0000
@@ -60,9 +60,6 @@
     @NodeCollection( isReadable = false, isWritable = true )
     private List<String> writeOnly = new ArrayList<>();
 
-    @NodeCollection( isPersisted = false )
-    private List<String> notPersistedProperty = new ArrayList<>();
-
     @NodeCollection( namespace = "http://ns.example.org"; )
     private List<String> propertyWithNamespace = new ArrayList<>();
 
@@ -104,20 +101,12 @@
         assertTrue( propertyMap.containsKey( "renamedProperty" ) );
         assertTrue( propertyMap.containsKey( "readOnly" ) );
         assertTrue( propertyMap.containsKey( "writeOnly" ) );
-        assertTrue( propertyMap.containsKey( "notPersistedProperty" ) );
         assertTrue( propertyMap.containsKey( "propertyWithNamespace" ) );
         assertTrue( propertyMap.containsKey( "items1" ) );
         assertTrue( propertyMap.containsKey( "items" ) );
     }
 
     @Test
-    public void testPersisted()
-    {
-        assertTrue( propertyMap.get( "property" ).isPersisted() );
-        assertFalse( propertyMap.get( "notPersistedProperty" ).isPersisted() );
-    }
-
-    @Test
     public void testReadWrite()
     {
         assertTrue( propertyMap.get( "readOnly" ).isReadable() );

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldComplexNodePropertyIntrospectorServiceTest.java'
--- dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldComplexNodePropertyIntrospectorServiceTest.java	2014-08-17 13:37:34 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldComplexNodePropertyIntrospectorServiceTest.java	2014-11-20 09:20:30 +0000
@@ -57,9 +57,6 @@
     @NodeComplex( isReadable = false, isWritable = true )
     private Value writeOnly;
 
-    @NodeComplex( isPersisted = false )
-    private Value notPersistedProperty;
-
     @NodeComplex( namespace = "http://ns.example.org"; )
     private Value propertyWithNamespace;
 
@@ -95,18 +92,10 @@
         assertTrue( propertyMap.containsKey( "renamedProperty" ) );
         assertTrue( propertyMap.containsKey( "readOnly" ) );
         assertTrue( propertyMap.containsKey( "writeOnly" ) );
-        assertTrue( propertyMap.containsKey( "notPersistedProperty" ) );
         assertTrue( propertyMap.containsKey( "propertyWithNamespace" ) );
     }
 
     @Test
-    public void testPersisted()
-    {
-        assertTrue( propertyMap.get( "property" ).isPersisted() );
-        assertFalse( propertyMap.get( "notPersistedProperty" ).isPersisted() );
-    }
-
-    @Test
     public void testReadWrite()
     {
         assertTrue( propertyMap.get( "readOnly" ).isReadable() );

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldSimpleNodePropertyIntrospectorServiceTest.java'
--- dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldSimpleNodePropertyIntrospectorServiceTest.java	2014-08-17 13:37:34 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/test/java/org/hisp/dhis/schema/FieldSimpleNodePropertyIntrospectorServiceTest.java	2014-11-20 09:20:30 +0000
@@ -44,9 +44,6 @@
     @NodeSimple( value = "renamedProperty", isAttribute = true )
     private String propertyToBeRenamed;
 
-    @NodeSimple( isPersisted = false )
-    private String notPersistedProperty;
-
     @NodeSimple( isReadable = true, isWritable = false )
     private String readOnly;
 
@@ -98,13 +95,6 @@
     }
 
     @Test
-    public void testPersisted()
-    {
-        assertTrue( propertyMap.get( "property" ).isPersisted() );
-        assertFalse( propertyMap.get( "notPersistedProperty" ).isPersisted() );
-    }
-
-    @Test
     public void testReadWrite()
     {
         assertTrue( propertyMap.get( "readOnly" ).isReadable() );