MCPcopy
hub / github.com/andeya/pholcus / Phantom

Struct Phantom

app/downloader/surfer/phantom.go:40–45  ·  view source on GitHub ↗

Phantom is a PhantomJS-based downloader, complementing Surf. Slower than Surf but better at bypassing anti-scraping due to browser simulation. Supports UserAgent, TryTimes, RetryPause, and custom JS.

Source from the content-addressed store, hash-verified

38 // Slower than Surf but better at bypassing anti-scraping due to browser simulation.
39 // Supports UserAgent, TryTimes, RetryPause, and custom JS.
40 Phantom struct {
41 PhantomjsFile string // full path to PhantomJS executable
42 TempJsDir string // directory for temporary JS files
43 jsFileMap map[string]string // existing JS files
44 CookieJar *cookiejar.Jar
45 }
46 // Response parses PhantomJS response content.
47 Response struct {
48 Cookies []string

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected