dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #43200
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 21946: renamed MergeStrategy => MergeMode, adds MergeMode to ObjectBundleParams/ObjectBundle
------------------------------------------------------------
revno: 21946
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2016-02-11 16:13:07 +0700
message:
renamed MergeStrategy => MergeMode, adds MergeMode to ObjectBundleParams/ObjectBundle
removed:
dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/MergeStrategy.java
added:
dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/MergeMode.java
dhis-2/dhis-services/dhis-service-dxf2/src/test/resources/dxf2/de_validate3.json
modified:
dhis-2/dhis-api/src/main/java/org/hisp/dhis/attribute/Attribute.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/BaseChart.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/Chart.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/color/Color.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/color/ColorSet.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseAnalyticalObject.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseDimensionalItemObject.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseDimensionalObject.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseIdentifiableObject.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseNameableObject.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/Mergeable.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/constant/Constant.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/Dashboard.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardItem.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataapproval/DataApprovalWorkflow.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/CategoryOptionGroup.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/CategoryOptionGroupSet.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElement.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategory.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryCombo.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOption.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOptionCombo.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementGroup.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementGroupSet.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSet.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/Section.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/document/Document.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/eventchart/EventChart.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/eventreport/EventReport.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/Indicator.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorGroup.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorGroupSet.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorType.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/legend/Legend.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/legend/LegendSet.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/Map.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/MapLayer.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/MapView.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/message/MessageConversation.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/option/OptionSet.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnit.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitGroup.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitGroupSet.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitLevel.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/Program.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramIndicator.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStage.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStageDataElement.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStageSection.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramTrackedEntityAttribute.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramValidation.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRule.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRuleAction.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRuleVariable.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/relationship/RelationshipType.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/report/Report.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/security/oauth2/OAuth2Client.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/sqlview/SqlView.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityAttribute.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityAttributeGroup.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityInstance.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityInstanceReminder.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/translation/Translation.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/User.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserAuthorityGroup.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserCredentials.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserGroup.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/validation/ValidationRule.java
dhis-2/dhis-api/src/main/java/org/hisp/dhis/validation/ValidationRuleGroup.java
dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dimension/DefaultDimensionService.java
dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/common/ImportOptions.java
dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/gml/DefaultGmlImportService.java
dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata/DefaultMergeService.java
dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata/MergeService.java
dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/DefaultObjectBundleService.java
dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundle.java
dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundleParams.java
dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/metadata/MergeServiceTest.java
dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundleServiceTest.java
dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/AbstractCrudController.java
dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/ReportTableController.java
dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/user/UserController.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/attribute/Attribute.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/attribute/Attribute.java 2016-01-25 05:47:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/attribute/Attribute.java 2016-02-11 09:13:07 +0000
@@ -36,7 +36,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.ValueType;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -522,7 +522,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/BaseChart.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/BaseChart.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/BaseChart.java 2016-02-11 09:13:07 +0000
@@ -43,7 +43,7 @@
import org.hisp.dhis.common.Grid;
import org.hisp.dhis.common.IdentifiableObject;
import org.hisp.dhis.common.IdentifiableObjectUtils;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.DimensionalView;
import org.hisp.dhis.common.view.ExportView;
@@ -493,7 +493,7 @@
// -------------------------------------------------------------------------
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/Chart.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/Chart.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/chart/Chart.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.DimensionalObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
import org.hisp.dhis.i18n.I18nFormat;
@@ -228,7 +228,7 @@
// -------------------------------------------------------------------------
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/color/Color.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/color/Color.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/color/Color.java 2016-02-11 09:13:07 +0000
@@ -31,7 +31,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -80,7 +80,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/color/ColorSet.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/color/ColorSet.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/color/ColorSet.java 2016-02-11 09:13:07 +0000
@@ -34,7 +34,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -91,7 +91,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseAnalyticalObject.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseAnalyticalObject.java 2016-01-14 12:24:11 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseAnalyticalObject.java 2016-02-11 09:13:07 +0000
@@ -834,7 +834,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseDimensionalItemObject.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseDimensionalItemObject.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseDimensionalItemObject.java 2016-02-11 09:13:07 +0000
@@ -158,7 +158,7 @@
// -------------------------------------------------------------------------
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseDimensionalObject.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseDimensionalObject.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseDimensionalObject.java 2016-02-11 09:13:07 +0000
@@ -330,7 +330,7 @@
//--------------------------------------------------------------------------
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseIdentifiableObject.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseIdentifiableObject.java 2016-01-25 05:47:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseIdentifiableObject.java 2016-02-11 09:13:07 +0000
@@ -573,7 +573,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
Validate.notNull( other );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseNameableObject.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseNameableObject.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/BaseNameableObject.java 2016-02-11 09:13:07 +0000
@@ -239,7 +239,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== added file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/MergeMode.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/MergeMode.java 1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/MergeMode.java 2016-02-11 09:13:07 +0000
@@ -0,0 +1,48 @@
+package org.hisp.dhis.common;
+
+/*
+ * Copyright (c) 2004-2016, University of Oslo
+ * 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.
+ */
+
+/**
+ * @author Morten Olav Hansen <mortenoh@xxxxxxxxx>
+ */
+public enum MergeMode
+{
+ MERGE_ALWAYS, MERGE_IF_NOT_NULL,
+ MERGE, REPLACE;
+
+ public boolean isMerge()
+ {
+ return this == MERGE_IF_NOT_NULL || this == MERGE;
+ }
+
+ public boolean isReplace()
+ {
+ return this == MERGE_ALWAYS || this == REPLACE;
+ }
+}
=== removed file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/MergeStrategy.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/MergeStrategy.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/MergeStrategy.java 1970-01-01 00:00:00 +0000
@@ -1,48 +0,0 @@
-package org.hisp.dhis.common;
-
-/*
- * Copyright (c) 2004-2016, University of Oslo
- * 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.
- */
-
-/**
- * @author Morten Olav Hansen <mortenoh@xxxxxxxxx>
- */
-public enum MergeStrategy
-{
- MERGE_ALWAYS, MERGE_IF_NOT_NULL,
- MERGE, REPLACE;
-
- public boolean isMerge()
- {
- return this == MERGE_IF_NOT_NULL || this == MERGE;
- }
-
- public boolean isReplace()
- {
- return this == MERGE_ALWAYS || this == REPLACE;
- }
-}
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/Mergeable.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/Mergeable.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/common/Mergeable.java 2016-02-11 09:13:07 +0000
@@ -36,7 +36,7 @@
*/
public interface Mergeable<T>
{
- void mergeWith( T other, MergeStrategy strategy );
+ void mergeWith( T other, MergeMode strategy );
void mergeSharingWith( T other );
}
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/constant/Constant.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/constant/Constant.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/constant/Constant.java 2016-02-11 09:13:07 +0000
@@ -31,7 +31,7 @@
import org.hisp.dhis.common.BaseNameableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -90,7 +90,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/Dashboard.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/Dashboard.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/Dashboard.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -178,7 +178,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardItem.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardItem.java 2016-01-27 09:25:20 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dashboard/DashboardItem.java 2016-02-11 09:13:07 +0000
@@ -38,7 +38,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -410,7 +410,7 @@
// -------------------------------------------------------------------------
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataapproval/DataApprovalWorkflow.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataapproval/DataApprovalWorkflow.java 2016-01-12 00:42:41 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataapproval/DataApprovalWorkflow.java 2016-02-11 09:13:07 +0000
@@ -38,7 +38,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.adapter.JacksonPeriodTypeDeserializer;
import org.hisp.dhis.common.adapter.JacksonPeriodTypeSerializer;
import org.hisp.dhis.common.annotation.Scanned;
@@ -157,7 +157,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/CategoryOptionGroup.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/CategoryOptionGroup.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/CategoryOptionGroup.java 2016-02-11 09:13:07 +0000
@@ -40,7 +40,7 @@
import org.hisp.dhis.common.DataDimensionType;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -140,7 +140,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/CategoryOptionGroupSet.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/CategoryOptionGroupSet.java 2016-01-14 10:57:58 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/CategoryOptionGroupSet.java 2016-02-11 09:13:07 +0000
@@ -45,7 +45,7 @@
import org.hisp.dhis.common.DimensionalItemObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.DimensionalView;
@@ -185,7 +185,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElement.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElement.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElement.java 2016-02-11 09:13:07 +0000
@@ -43,7 +43,7 @@
import org.hisp.dhis.common.DimensionType;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.ValueType;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.DimensionalView;
@@ -662,7 +662,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategory.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategory.java 2016-02-03 03:30:21 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategory.java 2016-02-11 09:13:07 +0000
@@ -43,7 +43,7 @@
import org.hisp.dhis.common.DimensionalItemObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.DimensionalView;
@@ -251,7 +251,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryCombo.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryCombo.java 2016-02-10 15:44:56 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryCombo.java 2016-02-11 09:13:07 +0000
@@ -39,7 +39,7 @@
import org.hisp.dhis.common.DataDimensionType;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -331,7 +331,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOption.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOption.java 2016-01-14 13:21:43 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOption.java 2016-02-11 09:13:07 +0000
@@ -39,7 +39,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -250,7 +250,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOptionCombo.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOptionCombo.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOptionCombo.java 2016-02-11 09:13:07 +0000
@@ -41,7 +41,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -379,7 +379,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementGroup.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementGroup.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementGroup.java 2016-02-11 09:13:07 +0000
@@ -39,7 +39,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.ValueType;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
@@ -177,7 +177,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementGroupSet.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementGroupSet.java 2016-01-14 10:57:58 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementGroupSet.java 2016-02-11 09:13:07 +0000
@@ -43,7 +43,7 @@
import org.hisp.dhis.common.DimensionalItemObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
import org.hisp.dhis.common.view.DetailedView;
@@ -257,7 +257,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSet.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSet.java 2016-01-12 00:42:41 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/DataSet.java 2016-02-11 09:13:07 +0000
@@ -40,7 +40,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.VersionedObject;
import org.hisp.dhis.common.adapter.JacksonPeriodTypeDeserializer;
import org.hisp.dhis.common.adapter.JacksonPeriodTypeSerializer;
@@ -751,7 +751,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/Section.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/Section.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataset/Section.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -267,7 +267,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/document/Document.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/document/Document.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/document/Document.java 2016-02-11 09:13:07 +0000
@@ -35,7 +35,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
import org.hisp.dhis.schema.PropertyType;
@@ -128,7 +128,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/eventchart/EventChart.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/eventchart/EventChart.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/eventchart/EventChart.java 2016-02-11 09:13:07 +0000
@@ -43,7 +43,7 @@
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.EventAnalyticalObject;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.DimensionalView;
import org.hisp.dhis.common.view.ExportView;
@@ -402,7 +402,7 @@
// -------------------------------------------------------------------------
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/eventreport/EventReport.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/eventreport/EventReport.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/eventreport/EventReport.java 2016-02-11 09:13:07 +0000
@@ -43,7 +43,7 @@
import org.hisp.dhis.common.EventAnalyticalObject;
import org.hisp.dhis.common.FontSize;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.DimensionalView;
import org.hisp.dhis.common.view.ExportView;
@@ -570,7 +570,7 @@
// -------------------------------------------------------------------------
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/Indicator.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/Indicator.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/Indicator.java 2016-02-11 09:13:07 +0000
@@ -40,7 +40,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
import org.hisp.dhis.dataset.DataSet;
@@ -321,7 +321,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorGroup.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorGroup.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorGroup.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -153,7 +153,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorGroupSet.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorGroupSet.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorGroupSet.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
import org.hisp.dhis.common.view.DetailedView;
@@ -229,7 +229,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorType.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorType.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/indicator/IndicatorType.java 2016-02-11 09:13:07 +0000
@@ -31,7 +31,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -98,7 +98,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/legend/Legend.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/legend/Legend.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/legend/Legend.java 2016-02-11 09:13:07 +0000
@@ -31,7 +31,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -131,7 +131,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/legend/LegendSet.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/legend/LegendSet.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/legend/LegendSet.java 2016-02-11 09:13:07 +0000
@@ -36,7 +36,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -121,7 +121,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/Map.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/Map.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/Map.java 2016-02-11 09:13:07 +0000
@@ -36,7 +36,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.DimensionalView;
@@ -140,7 +140,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/MapLayer.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/MapLayer.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/MapLayer.java 2016-02-11 09:13:07 +0000
@@ -35,7 +35,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
import org.hisp.dhis.schema.PropertyType;
@@ -194,7 +194,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/MapView.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/MapView.java 2016-01-06 13:45:38 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/mapping/MapView.java 2016-02-11 09:13:07 +0000
@@ -41,7 +41,7 @@
import org.hisp.dhis.common.DimensionalObjectUtils;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.DimensionalView;
import org.hisp.dhis.common.view.ExportView;
@@ -462,7 +462,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/message/MessageConversation.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/message/MessageConversation.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/message/MessageConversation.java 2016-02-11 09:13:07 +0000
@@ -39,7 +39,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -485,7 +485,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/option/OptionSet.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/option/OptionSet.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/option/OptionSet.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.ValueType;
import org.hisp.dhis.common.VersionedObject;
import org.hisp.dhis.common.annotation.Scanned;
@@ -170,7 +170,7 @@
// -------------------------------------------------------------------------
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnit.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnit.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnit.java 2016-02-11 09:13:07 +0000
@@ -42,7 +42,7 @@
import org.hisp.dhis.common.DisplayProperty;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.adapter.JacksonOrganisationUnitChildrenSerializer;
import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
import org.hisp.dhis.common.view.DetailedView;
@@ -1153,7 +1153,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitGroup.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitGroup.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitGroup.java 2016-02-11 09:13:07 +0000
@@ -39,7 +39,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -169,7 +169,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitGroupSet.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitGroupSet.java 2016-01-14 10:57:58 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitGroupSet.java 2016-02-11 09:13:07 +0000
@@ -41,7 +41,7 @@
import org.hisp.dhis.common.DimensionalItemObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.adapter.JacksonOrganisationUnitGroupSymbolSerializer;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
@@ -241,7 +241,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitLevel.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitLevel.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/organisationunit/OrganisationUnitLevel.java 2016-02-11 09:13:07 +0000
@@ -36,7 +36,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
import org.hisp.dhis.schema.annotation.PropertyRange;
@@ -150,7 +150,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/Program.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/Program.java 2016-01-06 02:56:45 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/Program.java 2016-02-11 09:13:07 +0000
@@ -39,7 +39,7 @@
import org.hisp.dhis.common.BaseNameableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.VersionedObject;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
@@ -696,7 +696,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramIndicator.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramIndicator.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramIndicator.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.DimensionType;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.RegexUtils;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -229,7 +229,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStage.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStage.java 2016-01-12 00:42:41 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStage.java 2016-02-11 09:13:07 +0000
@@ -38,7 +38,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.adapter.JacksonPeriodTypeDeserializer;
import org.hisp.dhis.common.adapter.JacksonPeriodTypeSerializer;
import org.hisp.dhis.common.annotation.Scanned;
@@ -501,7 +501,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStageDataElement.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStageDataElement.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStageDataElement.java 2016-02-11 09:13:07 +0000
@@ -36,7 +36,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
import org.hisp.dhis.dataelement.DataElement;
@@ -230,7 +230,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStageSection.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStageSection.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramStageSection.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -154,7 +154,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramTrackedEntityAttribute.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramTrackedEntityAttribute.java 2016-01-15 00:36:28 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramTrackedEntityAttribute.java 2016-02-11 09:13:07 +0000
@@ -38,7 +38,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.ValueType;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -233,7 +233,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramValidation.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramValidation.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/program/ProgramValidation.java 2016-02-11 09:13:07 +0000
@@ -36,7 +36,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
import org.hisp.dhis.expression.Operator;
@@ -140,7 +140,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRule.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRule.java 2016-01-05 09:31:36 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRule.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -194,7 +194,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRuleAction.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRuleAction.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRuleAction.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.DimensionalView;
import org.hisp.dhis.common.view.ExportView;
@@ -313,7 +313,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRuleVariable.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRuleVariable.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/programrule/ProgramRuleVariable.java 2016-02-11 09:13:07 +0000
@@ -36,7 +36,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.DimensionalView;
import org.hisp.dhis.common.view.ExportView;
@@ -194,7 +194,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/relationship/RelationshipType.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/relationship/RelationshipType.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/relationship/RelationshipType.java 2016-02-11 09:13:07 +0000
@@ -35,7 +35,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
import org.hisp.dhis.schema.annotation.PropertyRange;
@@ -115,7 +115,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/report/Report.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/report/Report.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/report/Report.java 2016-02-11 09:13:07 +0000
@@ -36,7 +36,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.cache.CacheStrategy;
import org.hisp.dhis.common.cache.Cacheable;
import org.hisp.dhis.common.view.DetailedView;
@@ -223,7 +223,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java 2016-01-14 12:24:11 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/reporttable/ReportTable.java 2016-02-11 09:13:07 +0000
@@ -53,7 +53,7 @@
import org.hisp.dhis.common.GridHeader;
import org.hisp.dhis.common.IdentifiableObject;
import org.hisp.dhis.common.IdentifiableObjectUtils;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.DimensionalView;
import org.hisp.dhis.common.view.ExportView;
@@ -1028,7 +1028,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/security/oauth2/OAuth2Client.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/security/oauth2/OAuth2Client.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/security/oauth2/OAuth2Client.java 2016-02-11 09:13:07 +0000
@@ -35,7 +35,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.schema.PropertyType;
import org.hisp.dhis.schema.annotation.Property;
import org.hisp.dhis.schema.annotation.PropertyRange;
@@ -158,7 +158,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/sqlview/SqlView.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/sqlview/SqlView.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/sqlview/SqlView.java 2016-02-11 09:13:07 +0000
@@ -39,7 +39,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.cache.CacheStrategy;
import org.hisp.dhis.common.cache.Cacheable;
import org.hisp.dhis.common.view.DetailedView;
@@ -293,7 +293,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityAttribute.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityAttribute.java 2016-01-04 10:49:18 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityAttribute.java 2016-02-11 09:13:07 +0000
@@ -41,7 +41,7 @@
import org.hisp.dhis.common.DimensionType;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.ValueType;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -397,7 +397,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityAttributeGroup.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityAttributeGroup.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityAttributeGroup.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -112,7 +112,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityInstance.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityInstance.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityInstance.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
import org.hisp.dhis.organisationunit.OrganisationUnit;
@@ -180,7 +180,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityInstanceReminder.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityInstanceReminder.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/trackedentity/TrackedEntityInstanceReminder.java 2016-02-11 09:13:07 +0000
@@ -36,7 +36,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
import org.hisp.dhis.user.UserGroup;
@@ -239,7 +239,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/translation/Translation.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/translation/Translation.java 2016-01-15 08:41:57 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/translation/Translation.java 2016-02-11 09:13:07 +0000
@@ -35,7 +35,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import java.util.Objects;
@@ -207,7 +207,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/User.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/User.java 2016-01-25 03:56:13 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/User.java 2016-02-11 09:13:07 +0000
@@ -39,7 +39,7 @@
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
import org.hisp.dhis.common.IdentifiableObjectUtils;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.comparator.IdentifiableObjectNameComparator;
import org.hisp.dhis.common.view.DetailedView;
@@ -622,7 +622,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserAuthorityGroup.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserAuthorityGroup.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserAuthorityGroup.java 2016-02-11 09:13:07 +0000
@@ -40,7 +40,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -243,7 +243,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserCredentials.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserCredentials.java 2016-02-05 07:09:44 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserCredentials.java 2016-02-11 09:13:07 +0000
@@ -40,7 +40,7 @@
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
import org.hisp.dhis.common.IdentifiableObjectUtils;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -762,7 +762,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserGroup.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserGroup.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/user/UserGroup.java 2016-02-11 09:13:07 +0000
@@ -38,7 +38,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -214,7 +214,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/validation/ValidationRule.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/validation/ValidationRule.java 2016-01-13 12:54:38 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/validation/ValidationRule.java 2016-02-11 09:13:07 +0000
@@ -38,7 +38,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.adapter.JacksonPeriodTypeDeserializer;
import org.hisp.dhis.common.adapter.JacksonPeriodTypeSerializer;
import org.hisp.dhis.common.view.DetailedView;
@@ -435,7 +435,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/validation/ValidationRuleGroup.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/validation/ValidationRuleGroup.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/validation/ValidationRuleGroup.java 2016-02-11 09:13:07 +0000
@@ -37,7 +37,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.DxfNamespaces;
import org.hisp.dhis.common.IdentifiableObject;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.annotation.Scanned;
import org.hisp.dhis.common.view.DetailedView;
import org.hisp.dhis.common.view.ExportView;
@@ -171,7 +171,7 @@
}
@Override
- public void mergeWith( IdentifiableObject other, MergeStrategy strategy )
+ public void mergeWith( IdentifiableObject other, MergeMode strategy )
{
super.mergeWith( other, strategy );
=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dimension/DefaultDimensionService.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dimension/DefaultDimensionService.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dimension/DefaultDimensionService.java 2016-02-11 09:13:07 +0000
@@ -66,7 +66,7 @@
import org.hisp.dhis.common.EventAnalyticalObject;
import org.hisp.dhis.common.IdentifiableObject;
import org.hisp.dhis.common.IdentifiableObjectManager;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.commons.collection.UniqueArrayList;
import org.hisp.dhis.dataelement.CategoryOptionGroup;
import org.hisp.dhis.dataelement.CategoryOptionGroupSet;
@@ -335,7 +335,7 @@
DimensionalObject dimension = identifiableObjectManager.get( DimensionalObject.DYNAMIC_DIMENSION_CLASSES, uid );
BaseDimensionalObject copy = new BaseDimensionalObject();
- copy.mergeWith( dimension, MergeStrategy.MERGE_IF_NOT_NULL );
+ copy.mergeWith( dimension, MergeMode.MERGE_IF_NOT_NULL );
if ( filterCanRead )
{
=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/common/ImportOptions.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/common/ImportOptions.java 2016-02-04 15:46:58 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/common/ImportOptions.java 2016-02-11 09:13:07 +0000
@@ -30,7 +30,7 @@
import com.google.common.base.MoreObjects;
import org.hisp.dhis.common.IdSchemes;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.importexport.ImportStrategy;
/**
@@ -54,7 +54,7 @@
private ImportStrategy importStrategy = ImportStrategy.CREATE_AND_UPDATE;
- private MergeStrategy mergeStrategy = MergeStrategy.MERGE_IF_NOT_NULL;
+ private MergeMode mergeStrategy = MergeMode.MERGE_IF_NOT_NULL;
private boolean skipExistingCheck;
@@ -118,12 +118,12 @@
return importStrategy != null ? importStrategy : ImportStrategy.NEW_AND_UPDATES;
}
- public MergeStrategy getMergeStrategy()
+ public MergeMode getMergeStrategy()
{
return mergeStrategy;
}
- public void setMergeStrategy( MergeStrategy mergeStrategy )
+ public void setMergeStrategy( MergeMode mergeStrategy )
{
this.mergeStrategy = mergeStrategy;
}
=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/gml/DefaultGmlImportService.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/gml/DefaultGmlImportService.java 2016-02-02 06:34:22 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/gml/DefaultGmlImportService.java 2016-02-11 09:13:07 +0000
@@ -40,7 +40,7 @@
import org.hisp.dhis.common.IdentifiableObjectManager;
import org.hisp.dhis.common.IdentifiableObjectUtils;
import org.hisp.dhis.common.IdentifiableProperty;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.dxf2.common.ImportOptions;
import org.hisp.dhis.dxf2.metadata.ImportService;
import org.hisp.dhis.dxf2.metadata.Metadata;
@@ -290,7 +290,7 @@
String coordinates = target.getCoordinates();
FeatureType featureType = target.getFeatureType();
- target.mergeWith( source, MergeStrategy.MERGE );
+ target.mergeWith( source, MergeMode.MERGE );
target.setCoordinates( coordinates );
target.setFeatureType( featureType );
=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata/DefaultMergeService.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata/DefaultMergeService.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata/DefaultMergeService.java 2016-02-11 09:13:07 +0000
@@ -28,7 +28,7 @@
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.schema.Property;
import org.hisp.dhis.schema.Schema;
import org.hisp.dhis.schema.SchemaService;
@@ -47,7 +47,7 @@
@Override
@SuppressWarnings( { "rawtypes", "unchecked" } )
- public <T> void merge( T source, T target, MergeStrategy mergeStrategy )
+ public <T> void merge( T source, T target, MergeMode mergeStrategy )
{
if ( source == null || target == null )
{
=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata/MergeService.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata/MergeService.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata/MergeService.java 2016-02-11 09:13:07 +0000
@@ -28,7 +28,7 @@
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
/**
* @author Morten Olav Hansen <mortenoh@xxxxxxxxx>
@@ -42,5 +42,5 @@
* @param target Target object to merge into
* @param mergeStrategy Strategy to use
*/
- <T> void merge( T source, T target, MergeStrategy mergeStrategy );
+ <T> void merge( T source, T target, MergeMode mergeStrategy );
}
=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/DefaultObjectBundleService.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/DefaultObjectBundleService.java 2016-02-11 08:11:40 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/DefaultObjectBundleService.java 2016-02-11 09:13:07 +0000
@@ -33,7 +33,6 @@
import org.hisp.dhis.preheat.PreheatMode;
import org.hisp.dhis.preheat.PreheatParams;
import org.hisp.dhis.preheat.PreheatService;
-import org.hisp.dhis.schema.SchemaService;
import org.hisp.dhis.validation.ValidationViolation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
@@ -48,9 +47,6 @@
public class DefaultObjectBundleService implements ObjectBundleService
{
@Autowired
- private SchemaService schemaService;
-
- @Autowired
private PreheatService preheatService;
@Autowired
@@ -59,7 +55,7 @@
@Override
public ObjectBundle create( ObjectBundleParams params )
{
- ObjectBundle bundle = new ObjectBundle();
+ ObjectBundle bundle = new ObjectBundle( params );
bundle.putObjects( params.getObjects() );
PreheatParams preheatParams = params.getPreheatParams();
=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundle.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundle.java 2016-02-10 06:31:33 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundle.java 2016-02-11 09:13:07 +0000
@@ -29,8 +29,10 @@
*/
import org.hisp.dhis.common.IdentifiableObject;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.preheat.Preheat;
import org.hisp.dhis.preheat.PreheatIdentifier;
+import org.hisp.dhis.preheat.PreheatMode;
import java.util.ArrayList;
import java.util.HashMap;
@@ -42,16 +44,24 @@
*/
public class ObjectBundle
{
- private ObjectBundleMode objectBundleMode = ObjectBundleMode.COMMIT;
-
- private PreheatIdentifier preheatIdentifier = PreheatIdentifier.UID;
+ private final ObjectBundleMode objectBundleMode;
+
+ private final PreheatIdentifier preheatIdentifier;
+
+ private final PreheatMode preheatMode;
+
+ private final MergeMode mergeMode;
private Preheat preheat = new Preheat();
private Map<Class<? extends IdentifiableObject>, List<IdentifiableObject>> objects = new HashMap<>();
- public ObjectBundle()
+ public ObjectBundle( ObjectBundleParams params )
{
+ this.objectBundleMode = params.getObjectBundleMode();
+ this.preheatIdentifier = params.getPreheatIdentifier();
+ this.preheatMode = params.getPreheatMode();
+ this.mergeMode = params.getMergeMode();
}
public ObjectBundleMode getObjectBundleMode()
@@ -59,19 +69,19 @@
return objectBundleMode;
}
- public void setObjectBundleMode( ObjectBundleMode objectBundleMode )
- {
- this.objectBundleMode = objectBundleMode;
- }
-
public PreheatIdentifier getPreheatIdentifier()
{
return preheatIdentifier;
}
- public void setPreheatIdentifier( PreheatIdentifier preheatIdentifier )
- {
- this.preheatIdentifier = preheatIdentifier;
+ public PreheatMode getPreheatMode()
+ {
+ return preheatMode;
+ }
+
+ public MergeMode getMergeMode()
+ {
+ return mergeMode;
}
public Preheat getPreheat()
=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundleParams.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundleParams.java 2016-02-10 07:45:27 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/main/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundleParams.java 2016-02-11 09:13:07 +0000
@@ -29,6 +29,7 @@
*/
import org.hisp.dhis.common.IdentifiableObject;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.preheat.PreheatIdentifier;
import org.hisp.dhis.preheat.PreheatMode;
import org.hisp.dhis.preheat.PreheatParams;
@@ -49,6 +50,8 @@
private PreheatMode preheatMode = PreheatMode.REFERENCE;
+ private MergeMode mergeMode = MergeMode.MERGE;
+
private Map<Class<? extends IdentifiableObject>, List<IdentifiableObject>> objects = new HashMap<>();
public ObjectBundleParams()
@@ -87,6 +90,16 @@
this.preheatMode = preheatMode;
}
+ public MergeMode getMergeMode()
+ {
+ return mergeMode;
+ }
+
+ public void setMergeMode( MergeMode mergeMode )
+ {
+ this.mergeMode = mergeMode;
+ }
+
public Map<Class<? extends IdentifiableObject>, List<IdentifiableObject>> getObjects()
{
return objects;
=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/metadata/MergeServiceTest.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/metadata/MergeServiceTest.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/metadata/MergeServiceTest.java 2016-02-11 09:13:07 +0000
@@ -29,7 +29,7 @@
*/
import org.hisp.dhis.DhisSpringTest;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.dxf2.metadata.merge.Simple;
import org.hisp.dhis.dxf2.metadata.merge.SimpleCollection;
import org.junit.Test;
@@ -62,7 +62,7 @@
Simple source = new Simple( "string", 10, date, false, 123, 2.5f );
Simple target = new Simple();
- mergeService.merge( source, target, MergeStrategy.REPLACE );
+ mergeService.merge( source, target, MergeMode.REPLACE );
assertEquals( "string", target.getString() );
assertEquals( 10, (int) target.getInteger() );
@@ -78,7 +78,7 @@
Simple source = new Simple( null, 10, date, null, 123, 2.5f );
Simple target = new Simple( "hello", 20, date, true, 123, 2.5f );
- mergeService.merge( source, target, MergeStrategy.MERGE );
+ mergeService.merge( source, target, MergeMode.MERGE );
assertEquals( "hello", target.getString() );
assertEquals( 10, (int) target.getInteger() );
@@ -98,7 +98,7 @@
SimpleCollection target = new SimpleCollection( "target" );
- mergeService.merge( source, target, MergeStrategy.MERGE );
+ mergeService.merge( source, target, MergeMode.MERGE );
assertEquals( "name", target.getName() );
assertEquals( 3, target.getSimples().size() );
=== modified file 'dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundleServiceTest.java'
--- dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundleServiceTest.java 2016-02-11 08:11:40 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/test/java/org/hisp/dhis/dxf2/metadata2/objectbundle/ObjectBundleServiceTest.java 2016-02-11 09:13:07 +0000
@@ -31,6 +31,7 @@
import org.hisp.dhis.DhisSpringTest;
import org.hisp.dhis.common.IdentifiableObject;
import org.hisp.dhis.common.IdentifiableObjectManager;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.dataelement.DataElement;
import org.hisp.dhis.dataelement.DataElementCategoryCombo;
import org.hisp.dhis.dataelement.DataElementGroup;
@@ -225,6 +226,22 @@
assertEquals( 2, validate.getValidationViolations().get( DataElement.class ).size() );
}
+ @Test
+ public void testPreheatValidationsIncludingMerge() throws IOException
+ {
+ Map<Class<? extends IdentifiableObject>, List<IdentifiableObject>> metadata = renderService.fromMetadata(
+ new ClassPathResource( "dxf2/de_validate3.json" ).getInputStream(), RenderFormat.JSON );
+ defaultSetup();
+
+ ObjectBundleParams params = new ObjectBundleParams();
+ params.setObjectBundleMode( ObjectBundleMode.VALIDATE );
+ params.setMergeMode( MergeMode.REPLACE );
+ params.setObjects( metadata );
+
+ ObjectBundle bundle = objectBundleService.create( params );
+ ObjectBundleValidation validate = objectBundleService.validate( bundle );
+ }
+
private void defaultSetup()
{
DataElement de1 = createDataElement( 'A' );
=== added file 'dhis-2/dhis-services/dhis-service-dxf2/src/test/resources/dxf2/de_validate3.json'
--- dhis-2/dhis-services/dhis-service-dxf2/src/test/resources/dxf2/de_validate3.json 1970-01-01 00:00:00 +0000
+++ dhis-2/dhis-services/dhis-service-dxf2/src/test/resources/dxf2/de_validate3.json 2016-02-11 09:13:07 +0000
@@ -0,0 +1,40 @@
+{
+ "dataElements": [
+ {
+ "id": "cNkTt6mJQyO",
+ "userGroupAccesses": [],
+ "user": {
+ "id": "GOLswS44mh8"
+ },
+ "description": "Yebo",
+ "zeroIsSignificant": false,
+ "attributeValues": [
+ {
+ "lastUpdated": "2016-01-12T04:53:21.853+0000",
+ "attribute": {
+ "id": "Z4X3J7jMLYV"
+ },
+ "created": "2016-01-12T04:53:21.454+0000",
+ "value": "ACTIVITY"
+ }
+ ],
+ "shortName": "Yebo",
+ "lastUpdated": "2016-01-12T04:53:21.840+0000",
+ "created": "2016-01-12T04:53:21.826+0000",
+ "optionSet": {
+ "id": "pQYCiuosBnZ"
+ },
+ "valueType": "NUMBER",
+ "publicAccess": "rw------",
+ "formName": "Yebo",
+ "categoryCombo": {
+ "id": "p0KPaWEg3cf"
+ },
+ "code": "Yebo",
+ "aggregationType": "SUM",
+ "domainType": "TRACKER",
+ "aggregationLevels": [],
+ "name": "Yebo"
+ }
+ ]
+}
=== modified file 'dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/AbstractCrudController.java'
--- dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/AbstractCrudController.java 2016-02-03 03:39:31 +0000
+++ dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/AbstractCrudController.java 2016-02-11 09:13:07 +0000
@@ -39,7 +39,7 @@
import org.hisp.dhis.common.BaseIdentifiableObject;
import org.hisp.dhis.common.IdentifiableObject;
import org.hisp.dhis.common.IdentifiableObjectManager;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.Pager;
import org.hisp.dhis.common.PagerUtils;
import org.hisp.dhis.dxf2.common.ImportOptions;
@@ -314,7 +314,7 @@
ImportOptions importOptions = new ImportOptions();
importOptions.setStrategy( ImportStrategy.UPDATE );
- importOptions.setMergeStrategy( MergeStrategy.MERGE );
+ importOptions.setMergeStrategy( MergeMode.MERGE );
ImportTypeSummary importTypeSummary = importService.importObject( currentUserService.getCurrentUser().getUid(), persistedObject, importOptions );
@@ -389,7 +389,7 @@
ImportOptions importOptions = new ImportOptions();
importOptions.setStrategy( ImportStrategy.UPDATE );
- importOptions.setMergeStrategy( MergeStrategy.MERGE );
+ importOptions.setMergeStrategy( MergeMode.MERGE );
ImportTypeSummary importTypeSummary = importService.importObject( currentUserService.getCurrentUser().getUid(), persistedObject, importOptions );
webMessageService.send( WebMessageUtils.importTypeSummary( importTypeSummary ), response, request );
=== modified file 'dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/ReportTableController.java'
--- dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/ReportTableController.java 2016-01-04 02:27:49 +0000
+++ dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/ReportTableController.java 2016-02-11 09:13:07 +0000
@@ -30,7 +30,7 @@
import org.hisp.dhis.common.DimensionService;
import org.hisp.dhis.common.Grid;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.cache.CacheStrategy;
import org.hisp.dhis.dxf2.common.ImportOptions;
import org.hisp.dhis.dxf2.webmessage.WebMessageException;
@@ -124,7 +124,7 @@
mergeReportTable( newReportTable );
- reportTable.mergeWith( newReportTable, MergeStrategy.MERGE_IF_NOT_NULL );
+ reportTable.mergeWith( newReportTable, MergeMode.MERGE_IF_NOT_NULL );
reportTableService.updateReportTable( reportTable );
}
=== modified file 'dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/user/UserController.java'
--- dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/user/UserController.java 2016-02-03 02:48:50 +0000
+++ dhis-2/dhis-web/dhis-web-api/src/main/java/org/hisp/dhis/webapi/controller/user/UserController.java 2016-02-11 09:13:07 +0000
@@ -32,7 +32,7 @@
import org.apache.commons.lang3.StringUtils;
import org.hisp.dhis.common.CodeGenerator;
import org.hisp.dhis.common.IdentifiableObjectUtils;
-import org.hisp.dhis.common.MergeStrategy;
+import org.hisp.dhis.common.MergeMode;
import org.hisp.dhis.common.Pager;
import org.hisp.dhis.dxf2.common.ImportOptions;
import org.hisp.dhis.dxf2.importsummary.ImportStatus;
@@ -343,12 +343,12 @@
}
User userReplica = new User();
- userReplica.mergeWith( existingUser, MergeStrategy.MERGE_IF_NOT_NULL );
+ userReplica.mergeWith( existingUser, MergeMode.MERGE_IF_NOT_NULL );
userReplica.setUid( CodeGenerator.generateCode() );
userReplica.setCreated( new Date() );
UserCredentials credentialsReplica = new UserCredentials();
- credentialsReplica.mergeWith( existingUser.getUserCredentials(), MergeStrategy.MERGE_IF_NOT_NULL );
+ credentialsReplica.mergeWith( existingUser.getUserCredentials(), MergeMode.MERGE_IF_NOT_NULL );
credentialsReplica.setUsername( username );
userService.encodeAndSetPassword( credentialsReplica, password );
@@ -509,7 +509,7 @@
ImportOptions importOptions = new ImportOptions();
importOptions.setStrategy( ImportStrategy.CREATE );
- importOptions.setMergeStrategy( MergeStrategy.MERGE );
+ importOptions.setMergeStrategy( MergeMode.MERGE );
ImportTypeSummary importTypeSummary = importService.importObject( currentUserService.getCurrentUser().getUid(), user, importOptions );
if ( importTypeSummary.isStatus( ImportStatus.SUCCESS ) && importTypeSummary.getImportCount().getImported() == 1 )