Class RemovrCompositeSpec

java.lang.Object
com.bazaarvoice.jolt.removr.spec.RemovrSpec
com.bazaarvoice.jolt.removr.spec.RemovrCompositeSpec

public class RemovrCompositeSpec extends RemovrSpec
Removr Spec that has children. In a removr spec, whenever the RHS is a Map, we build a RemovrCompositeSpec
  • Field Details

  • Constructor Details

  • Method Details

    • applyToMap

      public List<String> applyToMap(Map<String,Object> inputMap)
      Description copied from class: RemovrSpec
      Build a list of keys to remove from the input map, using the pathElement from the Spec.
      Specified by:
      applyToMap in class RemovrSpec
      Returns:
      the keys to remove, otherwise empty List.
    • applyToList

      public List<Integer> applyToList(List<Object> inputList)
      Description copied from class: RemovrSpec
      Build a list of indices to remove from the input list, using the pathElement from the Spec.
      Specified by:
      applyToList in class RemovrSpec
      Returns:
      the indicies to remove, otherwise empty List.
    • processChildren

      private void processChildren(List<RemovrSpec> children, Object subInput)
      Call our child nodes, build up the set of keys or indices to actually remove, and then remove them.