Class CardinalityLeafSpec

java.lang.Object
com.bazaarvoice.jolt.cardinality.CardinalitySpec
com.bazaarvoice.jolt.cardinality.CardinalityLeafSpec
All Implemented Interfaces:
BaseSpec

public class CardinalityLeafSpec extends CardinalitySpec
Leaf level CardinalitySpec object.

If this CardinalitySpec's PathElement matches the input (successful parallel tree walk) this CardinalitySpec has the information needed to write the given data to the output object.

  • Constructor Details

    • CardinalityLeafSpec

      public CardinalityLeafSpec(String rawKey, Object rhs)
  • Method Details

    • applyCardinality

      public boolean applyCardinality(String inputKey, Object input, WalkedPath walkedPath, Object parentContainer)
      If this CardinalitySpec matches the inputkey, then do the work of modifying the data and return true.
      Specified by:
      applyCardinality in class CardinalitySpec
      Returns:
      true if this this spec "handles" the inputkey such that no sibling specs need to see it
    • applyToParentContainer

      public Object applyToParentContainer(String inputKey, Object input, WalkedPath walkedPath, Object parentContainer)
      This should only be used by composite specs with an '@' child
      Returns:
      null if no work was done, otherwise returns the re-parented data