Class EnumUnionCoercionPlan


public class EnumUnionCoercionPlan extends UnionCoercionPlan
Coercion plan for use with 4.0 when the required item type is an enum type
  • Field Details

  • Constructor Details

    • EnumUnionCoercionPlan

      protected EnumUnionCoercionPlan()
  • Method Details

    • coerceItem

      public GroundedValue coerceItem(Item item, ItemType requiredType, CoercionRequest request) throws XPathException
      Apply the coercion rules (function conversion rules) to a value, given a required type.
      Overrides:
      coerceItem in class UnionCoercionPlan
      Parameters:
      item - the value to be converted
      requiredType - the required type
      request - the input to the coercion
      Returns:
      the converted value (possibly as a lazily-evaluated sequence)
      Throws:
      XPathException - if the value cannot be converted to the required type