github.com/daixiang0/gci@v0.13.0/pkg/section/dot.go (about) 1 package section 2 3 import ( 4 "github.com/daixiang0/gci/pkg/parse" 5 "github.com/daixiang0/gci/pkg/specificity" 6 ) 7 8 type Dot struct{} 9 10 const DotType = "dot" 11 12 func (d Dot) MatchSpecificity(spec *parse.GciImports) specificity.MatchSpecificity { 13 if spec.Name == "." { 14 return specificity.NameMatch{} 15 } 16 return specificity.MisMatch{} 17 } 18 19 func (d Dot) String() string { 20 return DotType 21 } 22 23 func (d Dot) Type() string { 24 return DotType 25 }