DebugUtil¶
-
public final class
DebugUtil
¶ Several utilities that are useful for troubleshooting of existing browser pages. The utilities assume the use of
com.github.loyada.jdollarx.singlebrowser.InBrowserSinglton
.
Methods¶
getDOM¶
-
public static Optional<Element>
getDOM
(Path el)¶ Same as
getDOMOfAll(Path)
, but returns an optional of the first match.Parameters: - el – the path we are looking for
Returns: the first Element that matches the path in the current page
getDOMOfAll¶
-
public static List<Element>
getDOMOfAll
(Path el)¶ Get all matches of the path as a list of
Element
. JSoupElement
are a nice, readable way to examine DOM objects. This is useful for troubleshooting. This method relies oncom.github.loyada.jdollarx.singlebrowser.InBrowserSinglton
, and on the library JSoup.Parameters: - el – the path we are looking for
Returns: all the elements that match it in the current page
getPageAsW3CDoc¶
-
public static org.w3c.dom.Document
getPageAsW3CDoc
()¶ Download the current page and convert it to a W3C Document, which can be inspected using the
com.github.loyada.jdollarx.PathParsers
methodsReturns: a W3C document