2023-08-09 15:34:19 +08:00
|
|
|
package ref
|
|
|
|
|
2023-08-24 18:22:25 +08:00
|
|
|
import (
|
|
|
|
"fmt"
|
2023-08-25 15:14:37 +08:00
|
|
|
|
2023-08-24 18:22:25 +08:00
|
|
|
"joylink.club/bj-rtsts-server/ats/verify/simulation/wayside/face"
|
|
|
|
)
|
2023-08-09 15:34:19 +08:00
|
|
|
|
2023-08-24 18:22:25 +08:00
|
|
|
type DevicePosition[T face.DeviceModeller] struct {
|
|
|
|
Device T
|
2023-08-09 15:34:19 +08:00
|
|
|
Offset int32
|
|
|
|
}
|
2023-08-24 18:22:25 +08:00
|
|
|
|
|
|
|
func (dp *DevicePosition[T]) String() string {
|
|
|
|
return fmt.Sprintf("%s-%d", dp.Device.GetIndex(), dp.Offset)
|
|
|
|
}
|