sort.go
func (s *SortFilter) RunFilter(arg Arg) error {
	state := sortState{s.cmp, nil}
	for item := range arg.In {
		state.data = append(state.data, item)
	}
	sort.Sort(state)
	for _, item := range state.data {
		arg.Out <- item
	}
	return nil
}
func (s *SortFilter) RunFilter(arg Arg) error {
	state := sortState{s.cmp, nil}
	for item := range arg.In {
		state.data = append(state.data, item)
	}
	sort.Sort(state)
	for _, item := range state.data {
		arg.Out <- item
	}
	return nil
}
func ( s * SortFilter ) RunFilter ( arg Arg ) error { state := sortState { s . cmp , nil } for item := range arg . In { state . data = append ( state . data , item ) } sort . Sort ( state ) for _ , item := range state . data { arg . Out <- item } return nil }
// RunFilter sorts items by the specified sorting keys. It implements
// the Filter interface.
RunFilter sorts items by the specified sorting keys . It implements the Filter interface .