图4.7实现模块中引擎类的类设计
2016-05-19 09:42:05 0 举报
在图4.7中,我们展示了引擎类的设计。这个类是一个实现模块的核心组件,负责处理各种任务和操作。它包含了多个属性和方法,以满足不同功能的需求。其中,属性包括引擎类型、状态、速度等,它们用于描述引擎的基本特征和当前状态。方法则涵盖了启动、停止、加速、减速等功能,以及一些辅助性的方法,如获取引擎信息、更新引擎状态等。通过这些方法,我们可以对引擎进行灵活的控制和管理。此外,引擎类还与其他相关类进行了交互,实现了数据的传递和共享。总之,引擎类的设计旨在提供一个高效、可靠的实现模块,为用户提供便捷的操作体验。
作者其他创作
大纲/内容
StreamTask
-mutex:sync.Mutex-subtasks:[]StreamTask-sched:StreamScheduler_masterType:bool-running:bool-isMaster:bool-ictxs:[]StreamInterfaceContext-ctx:context.Context
~close():error~master():error
InterfaceContext
1
drive
1..*
streamReadyPort
-ready:chan struct{}
~allocReady():chan struct{}
creates
sched
streamPipe
-ds:DataSet-oproc:int-output:OutputPort-iproc:int-input:InputPort
StreamEnigne
-ctx:context.Context-mutex:sync.Mutex-tasks:map[uuid.UUID]StreamTask-env:Environment
StreamInterfaceContext
-notifyCh:chan struct{}-dsm:DataSetMeta-task:StreamTask-infc:int-intf:Interface
~close():error
interfaces
Engine
OutputPort
StreamScheduler
-proc:[]Processor-pipes:[]streamPipe-relpipes:[][]int-barrierIndex:int-queue:[]int-queueHead:int-queueTail:int
pkg Stream.Engine
0 条评论
下一页