github.com/chenbh/concourse/v6@v6.4.2/atc/wrappa/concourse_version_wrappa.go (about) 1 package wrappa 2 3 import "github.com/tedsuo/rata" 4 5 type ConcourseVersionWrappa struct { 6 version string 7 } 8 9 func NewConcourseVersionWrappa(version string) Wrappa { 10 return ConcourseVersionWrappa{ 11 version: version, 12 } 13 } 14 15 func (wrappa ConcourseVersionWrappa) Wrap(handlers rata.Handlers) rata.Handlers { 16 wrapped := rata.Handlers{} 17 18 for name, handler := range handlers { 19 wrapped[name] = VersionedHandler{ 20 Version: wrappa.version, 21 Handler: handler, 22 } 23 } 24 25 return wrapped 26 }