Package net.sf.saxon.om
Interface SpaceStrippingRule
-
- All Known Implementing Classes:
AllElementsSpaceStrippingRule
,IgnorableSpaceStrippingRule
,NoElementsSpaceStrippingRule
,SelectedElementsSpaceStrippingRule
,StylesheetSpaceStrippingRule
public interface SpaceStrippingRule
Interface for deciding whether a particular element is to have whitespace text nodes stripped
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
export(ExpressionPresenter presenter)
Export this rule as part of an exported stylesheetint
isSpacePreserving(NodeName nodeName, SchemaType schemaType)
Decide whether an element is in the set of white-space preserving element typesProxyReceiver
makeStripper(Receiver next)
Make a filter to implement these space-stripping rules, or null if no filtering is necessary
-
-
-
Method Detail
-
isSpacePreserving
int isSpacePreserving(NodeName nodeName, SchemaType schemaType) throws XPathException
Decide whether an element is in the set of white-space preserving element types- Parameters:
nodeName
- Identifies the name of the element whose whitespace is (or is not) to be preservedschemaType
- The type annotation of the element whose whitespace is (or is not) to be preserved- Returns:
Stripper.ALWAYS_PRESERVE
if the element is in the set of white-space preserving element types,Stripper.ALWAYS_STRIP
if the element is to be stripped regardless of the xml:space setting, andStripper.STRIP_DEFAULT
otherwise- Throws:
XPathException
- if the rules are ambiguous and ambiguities are to be reported as errors
-
makeStripper
ProxyReceiver makeStripper(Receiver next)
Make a filter to implement these space-stripping rules, or null if no filtering is necessary- Parameters:
next
- the Receiver that is to receiver the filtered event stream- Returns:
- a filter in the form of a ProxyReceiver, or null
-
export
void export(ExpressionPresenter presenter) throws XPathException
Export this rule as part of an exported stylesheet- Parameters:
presenter
- the output handler- Throws:
XPathException
-
-