mirror of
https://github.com/crawlab-team/crawlab.git
synced 2026-01-26 17:49:15 +01:00
feat: added modules
This commit is contained in:
23
core/interfaces/model_task.go
Normal file
23
core/interfaces/model_task.go
Normal file
@@ -0,0 +1,23 @@
|
||||
package interfaces
|
||||
|
||||
import "go.mongodb.org/mongo-driver/bson/primitive"
|
||||
|
||||
type Task interface {
|
||||
Model
|
||||
GetNodeId() (id primitive.ObjectID)
|
||||
SetNodeId(id primitive.ObjectID)
|
||||
GetNodeIds() (ids []primitive.ObjectID)
|
||||
GetStatus() (status string)
|
||||
SetStatus(status string)
|
||||
GetError() (error string)
|
||||
SetError(error string)
|
||||
GetPid() (pid int)
|
||||
SetPid(pid int)
|
||||
GetSpiderId() (id primitive.ObjectID)
|
||||
GetType() (ty string)
|
||||
GetCmd() (cmd string)
|
||||
GetParam() (param string)
|
||||
GetPriority() (p int)
|
||||
GetUserId() (id primitive.ObjectID)
|
||||
SetUserId(id primitive.ObjectID)
|
||||
}
|
||||
Reference in New Issue
Block a user