Package org.jsoup.nodes
Class NodeInternals
java.lang.Object
org.jsoup.nodes.NodeInternals
public final class NodeInternals
extends Object
Internal hooks used by the parser and cleaner to attach source ranges to nodes and attributes.
This class is public only because jsoup's internal packages need to cross package boundaries; it is not a supported user API.
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidattributeRange(Attributes attributes, String key, org.jsoup.internal.LineMap lineMap, int nameStart, int nameEnd, int valueStart, int valueEnd) Sets parser-tracked source offsets for an attribute.static voidattributeRange(Attributes attributes, String key, Range.AttributeRange range) Copies an existing tracked attribute range onto another attribute set.static voidclearEndSourceRange(Element element) Clears a copied end-tag range so a parser-recreated element can track its own close.static voidendSourceRange(Element element, org.jsoup.internal.LineMap lineMap, int startPos, int endPos) Sets the source range for an element's end tag.static voidsourceRange(Node node, org.jsoup.internal.LineMap lineMap, int startPos, int endPos) Sets the source range for a node's start.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Method Details
-
sourceRange
public static void sourceRange(Node node, org.jsoup.internal.LineMap lineMap, int startPos, int endPos) Sets the source range for a node's start. -
endSourceRange
public static void endSourceRange(Element element, org.jsoup.internal.LineMap lineMap, int startPos, int endPos) Sets the source range for an element's end tag. -
clearEndSourceRange
Clears a copied end-tag range so a parser-recreated element can track its own close. -
attributeRange
public static void attributeRange(Attributes attributes, String key, org.jsoup.internal.LineMap lineMap, int nameStart, int nameEnd, int valueStart, int valueEnd) Sets parser-tracked source offsets for an attribute. -
attributeRange
Copies an existing tracked attribute range onto another attribute set.
-