HtmlExtractor

net.ruippeixotog.scalascraper.scraper.HtmlExtractor
See theHtmlExtractor companion trait

The companion object for HtmlExtractor, containing methods for creating new extractors.

Attributes

Companion
trait
Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Members list

Value members

Concrete methods

def apply[E <: Element, A](f: ElementQuery[E] => A): HtmlExtractor[E, A]

Creates a new HtmlExtractor from a function.

Creates a new HtmlExtractor from a function.

Type parameters

A

the type of the extracted content

E

the type of the elements needed by the HtmlExtractor

Value parameters

f

the function used to extract content from an ElementQuery

Attributes

Returns

a new HtmlExtractor that extracts content using f.

def forQuery[E <: Element](cssQuery: String): HtmlExtractor[E, ElementQuery[E]]

Creates a new HtmlExtractor that extracts the elements of the input that match a CSS query.

Creates a new HtmlExtractor that extracts the elements of the input that match a CSS query.

Type parameters

E

the type of the elements needed by the HtmlExtractor

Value parameters

cssQuery

the CSS query to apply

Attributes

Returns

a new HtmlExtractor that extracts the elements of the input that match a CSS query.

Implicits

Inherited implicits

implicit def extractorMonad[E <: Element]: Monad[<none>]

Attributes

Inherited from:
HtmlExtractorInstances