【删除无用方法】
This commit is contained in:
parent
672060a497
commit
b36040fc6f
|
@ -92,18 +92,3 @@ func RemoveTrainState(vs *VerifySimulation, id string) {
|
|||
panic(fmt.Sprintf("列车【%s】不存在", id))
|
||||
}
|
||||
}
|
||||
|
||||
// 获取移除列车ID并清空
|
||||
func GetRemovedTrainId(vs *VerifySimulation) []string {
|
||||
ids := vs.Memory.ChangeStatus.RemoveTrainId
|
||||
length := len(ids)
|
||||
if length > 0 {
|
||||
copyData := make([]string, length)
|
||||
// 将数据复制到新的切片空间中
|
||||
copy(copyData, ids)
|
||||
// 清空变更信息
|
||||
vs.Memory.ChangeStatus.RemoveTrainId = []string{}
|
||||
return copyData
|
||||
}
|
||||
return []string{}
|
||||
}
|
||||
|
|
|
@ -150,13 +150,3 @@ func FindSimulation(simulationId string) *memory.VerifySimulation {
|
|||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// 获取普通仿真数组
|
||||
func GetSimulationArr() []*memory.VerifySimulation {
|
||||
var result []*memory.VerifySimulation
|
||||
simulationMap.Range(func(_, v any) bool {
|
||||
result = append(result, v.(*memory.VerifySimulation))
|
||||
return true
|
||||
})
|
||||
return result
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue