rts-sim-module/repo/model/impl/physical_section.go

34 lines
629 B
Go
Raw Normal View History

2023-12-27 09:15:26 +08:00
package impl
import (
"joylink.club/rtsssimulation/repo/model"
)
type PhysicalSection struct {
uid string
code string
apSection model.Model // A端关联区段/道岔
bpSection model.Model // B端关联区段/道岔
linkRanges []*LinkRange // 所属link范围(道岔物理区段为多个)
}
func NewPhysicalSection(uid string, code string) *PhysicalSection {
return &PhysicalSection{
uid: uid,
code: code,
}
}
func (s *PhysicalSection) Uid() string {
return s.uid
}
func (s *PhysicalSection) Type() model.ModelType {
return model.MT_Section
}
func (s *PhysicalSection) Code() string {
return s.code
}