Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // EmbeddedFS Keep a reference to the embedded FileSystem holding our static files and templates EmbeddedFS http.FileSystem // TemplatesFSPrefix the path to template files *inside* the embedded FileSystem TemplatesFSPrefix = "/templates/" // TemplateFiles the list of template files to look for inside the embedded FileSystem TemplateFiles = [...]string{ "footer.html", "header.html", "home.html"} )
Functions ¶
func Logger ¶
func Logger() gin.HandlerFunc
Logger instances a Logger middleware that will write the logs, this is a slightly different version of the built-in gin Logger()
func LoggerWithWriter ¶
func LoggerWithWriter(out io.Writer, notlogged ...string) gin.HandlerFunc
LoggerWithWriter instance a Logger middleware with the specified writter buffer. Example: os.Stdout, a file opened in write mode, a socket...
Types ¶
type Credentials ¶
Credentials holds the json payload and for the login username and password
type JsonPayload ¶
type JsonPayload struct {
CrawlID uint64 `json:"crawlID,string"`
Mode string `json:"mode"`
Filter string `json:"filter"`
Order string `json:"order"`
Resume bool `json:"resume"`
Details bool `json:"details"`
Target string `json:"target"`
Output string `json:"output"`
Username string `json:"username"`
Password string `json:"password"`
}
type ProgressMessage ¶
type ProgressMessage struct {
ETA string `json:"ETA"`
ChunkSize uint64 `json:"chunkSize,string"`
TotalElements uint64 `json:"totalElements,string"`
DoneElements uint64 `json:"doneElements,string"`
Mode string `json:"mode"`
TimeoutsCount int `json:"timoutsCount,string"`
ErrorsCount int `json:"errorsCount,string"`
ProgressPercentage string `json:"progressPercentage"`
OutputFilename string `json:"outputFilename"`
LogMessage string `json:"logMessage"`
IsIngTargetMode bool `json:"isTargetMode"`
TotalIDsCount int `json:"totalIDsCount"`
CurrentIDOrderNumber int `json:"currentIDOrderNumber"`
Error string `json:"error"`
}
type WebDownloader ¶
type WebDownloader struct {
IsDone bool
IsStopped bool
APIDownloader *downloader.Downloader
JSONPayload JsonPayload
WebSocket *melody.Melody
// contains filtered or unexported fields
}
Click to show internal directories.
Click to hide internal directories.