BUAA-Unit2-hw7
2022-04-30 16:44:04 0 举报
BUAA-Unit2-hw7
作者其他创作
大纲/内容
BuildingScheduler
- isEnd: boolean- queue: ArrayList<ProRequest>- elvList : ArrayList<Sche>
I/O类
MainClass
+ main(String[] args): void
MainOutput
+ println(String str): void
UnfinishedRequest
Sche
+ put(ProRequest personRequest) : void+ getStatus() : int+ getInElv() : int+ setEnd() : void+ getRequests() : int
横向/纵向 电梯内部二级调度
NextTargetBuilding
- targetBuilding: int- elevatorId: int
+ getTargetBuilding(): int+ getId(): int
LongitudinalScheduler
- FLOOR: static final int[]- up: ArrayList<ProRequest>[]- down: ArrayList<ProRequest>[]- status: int- upCall: int- downCall : int- inElv : int- isEnd : boolean- inElvNum : int- nowFloor : int- speed: int- capacity: int- requests: int
+ init(): void+ setEnd(): void+ isEnd(): boolean+ isEmpty(): boolean font color=\"#1976d2\
ProRequest
- request: PersonRequest- nextStage: int- lastStage: int- lastBuilding: int- BuildingList : ArrayList<NextTargetBuilding>
+ Getter and Setter
请求类
LongitudinalElevator
- id: int- building: char- scheduler: LongitudinalScheduler- nowFloor: int- nowDir: boolean- nowPersonNum: int- personList: ArrayList<ProRequest>[]- speed: int- capacity: int- requests: int- buildingHasScheduler : BuildingScheduler[] - floorHasScheduler : BuildingScheduler[]
+ run(): void
SchedulerThread
- buildingScheduler : BuildingScheduler
WidewiseElevator
- id: int- floor: int- scheduler: WidewiseScheduler- nowBuilding: int- nowDir: boolean- nowPersonNum: int- personList: ArrayList<ProRequest>[]- speed: int- capacity: int- info : int- floorHasScheduler : BuildingScheduler[]
WidewiseScheduler
- FLOOR: static final int[]- up: ArrayList<ProRequest>[]- down: ArrayList<ProRequest>[]- status: int- upCall: int- downCall : int- inElv : int- isEnd : boolean- inElvNum : int- nowBuilding : int- speed: int- capacity: int- info : int- requests: int
InputThread
- buildingHasScheduler : BuildingScheduler[] - floorHasScheduler : BuildingScheduler[]
+ run(): void+ addPersonReq(in request:ProRequest): void+ addElvReq(in request:ProRequest): void
0 条评论
下一页