package et_print import ( "gitea.anxinyun.cn/container/common_models" "log" "node/stages" ) type PrintHandler struct { stage *stages.Stage } func (the *PrintHandler) GetStage() stages.Stage { return *the.stage } func NewPrintHandler() *PrintHandler { the := &PrintHandler{ stage: stages.NewStage("测试打印"), } the.stage.AddProcess(the.print) return the } func (the *PrintHandler) print(p *common_models.ProcessData) *common_models.ProcessData { log.Printf("处理设备[%s]数据", p.DeviceData.Name) return p }