Class RemovrSpec

    • Constructor Summary

      Constructors 
      Constructor Description
      RemovrSpec​(java.lang.String rawJsonKey)  
    • Method Summary

      All Methods Static Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      abstract java.util.List<java.lang.Integer> applyToList​(java.util.List<java.lang.Object> inputList)
      Build a list of indices to remove from the input list, using the pathElement from the Spec.
      abstract java.util.List<java.lang.String> applyToMap​(java.util.Map<java.lang.String,​java.lang.Object> inputMap)
      Build a list of keys to remove from the input map, using the pathElement from the Spec.
      protected java.lang.Integer getNonNegativeIntegerFromLiteralPathElement()
      Try to "interpret" the spec String value as a non-negative integer.
      static PathElement parse​(java.lang.String key)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • RemovrSpec

        public RemovrSpec​(java.lang.String rawJsonKey)
    • Method Detail

      • parse

        public static PathElement parse​(java.lang.String key)
      • getNonNegativeIntegerFromLiteralPathElement

        protected java.lang.Integer getNonNegativeIntegerFromLiteralPathElement()
        Try to "interpret" the spec String value as a non-negative integer.
        Returns:
        non-negative integer, otherwise null
      • applyToList

        public abstract java.util.List<java.lang.Integer> applyToList​(java.util.List<java.lang.Object> inputList)
        Build a list of indices to remove from the input list, using the pathElement from the Spec.
        Returns:
        the indicies to remove, otherwise empty List.
      • applyToMap

        public abstract java.util.List<java.lang.String> applyToMap​(java.util.Map<java.lang.String,​java.lang.Object> inputMap)
        Build a list of keys to remove from the input map, using the pathElement from the Spec.
        Returns:
        the keys to remove, otherwise empty List.