Enum Class IgnorableSpaceStrippingRule

java.lang.Object
java.lang.Enum<IgnorableSpaceStrippingRule>
net.sf.saxon.om.IgnorableSpaceStrippingRule
All Implemented Interfaces:
Serializable, Comparable<IgnorableSpaceStrippingRule>, Constable, SpaceStrippingRule

public enum IgnorableSpaceStrippingRule extends Enum<IgnorableSpaceStrippingRule> implements SpaceStrippingRule
A whitespace stripping rule that strips whitespace text node children from all elements having an element-only content model, regardless of the value of the xml:space attribute
  • Enum Constant Details

  • Method Details

    • values

      public static IgnorableSpaceStrippingRule[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static IgnorableSpaceStrippingRule valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • getInstance

      public static IgnorableSpaceStrippingRule getInstance()
    • isSpacePreserving

      public int isSpacePreserving(NodeName name, SchemaType schemaType)
      Decide whether an element is in the set of white-space preserving element types
      Specified by:
      isSpacePreserving in interface SpaceStrippingRule
      Parameters:
      name - identifies the name of the element being tested
      schemaType - the type annotation of the element being tested
      Returns:
      STRIP_DEFAULT: strip spaces unless xml:space tells you not to.
    • makeStripper

      public ProxyReceiver makeStripper(Receiver next)
      Make a filter to implement these space-stripping rules, or null if no filtering is necessary
      Specified by:
      makeStripper in interface SpaceStrippingRule
      Parameters:
      next - the Receiver that is to receive the filtered event stream
      Returns:
      a filter in the form of a ProxyReceiver, or null
    • export

      public void export(ExpressionPresenter presenter)
      Export this rule as part of an exported stylesheet
      Specified by:
      export in interface SpaceStrippingRule
      Parameters:
      presenter - the output handler