Class AcceptSecondaryConflictStrategy

All Implemented Interfaces:
ConflictStrategy<JSONObject,​String>, JSONObjectConflictStrategy

public class AcceptSecondaryConflictStrategy
extends AbstractJSONObjectConflictStrategy
Author:
Jim Earley (jim.earley@fdiinc.com)
  • Constructor Details

    • AcceptSecondaryConflictStrategy

      public AcceptSecondaryConflictStrategy​(MergeProcess mergeProcessor)
      Parameters:
      mergeProcessor -
  • Method Details

    • apply

      public void apply​(JSONObject context, String propertyValue, JSONValue<?> primaryValue, JSONValue<?> secondaryValue)
      Description copied from interface: ConflictStrategy
      Apply a conflict strategy to a given JSONNode context
      Parameters:
      context - the JSONNode that receives the "resolved" value
      propertyValue - either the key or index position of the value
      primaryValue - the value from the Primary JSONNode
      secondaryValue - the value from the Secondary JSONNode