selenium

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 11, 2020 License: GPL-3.0 Imports: 17 Imported by: 0

Documentation

Overview

Package selenium implements linkedin data scraping with selenium automatisation.

Index

Constants

View Source
const (
	LITTLE_WAIT = time.Millisecond * 100
	MEDIUM_WAIT = time.Second
	BIG_WAIT    = time.Second * 3
)

Variables

This section is empty.

Functions

func CloseHandler

func CloseHandler(wd selenium.WebDriver)

CloseHandler handle program Interruption and perform a clean exit

func CreateSeleniumServer

func CreateSeleniumServer(threadNumber int, initialPort int) []*os.Process

CreateSeleniumServer Lauch selenium server for workers

func CreateWorker

func CreateWorker(currentWd selenium.WebDriver, threadNumber int, initialPort int) []selenium.WebDriver

CreateWorker Spawn "t" webdriver simulate multithreading and reduce runtime

func DecodeReconstruct

func DecodeReconstruct(searchURL string) (string, error)

DecodeReconstruct Decode the searchURL and build the search URL for the main company

func DecodeRetry

func DecodeRetry(wd selenium.WebDriver) string

DecodeRetry Attempt getting currentURL

func KillProcess

func KillProcess(proc []*os.Process)

KillProcess Kill process started by StartProcess()

func ReadFile

func ReadFile(f *os.File) []string

ReadFile Read a file and return the line as a []string

func SlicePrint

func SlicePrint(s []string)

SlicePrint Print String Slice

func Start

func Start(comp string, threadNumber int)

Start setup and start the main process

func StartProcess

func StartProcess(port int) *os.Process

StartProcess Start an OS Process : Used to start selenium standalone server on n port for multiple webdriver worker

func WriteFile

func WriteFile(fileName string, buff []string)

WriteFile Write []string to file "fileName" and line by line

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL