Added Pointer to Map
This commit is contained in:
parent
a998aabb24
commit
c90924a4ef
|
|
@ -6,7 +6,7 @@ import (
|
|||
"strings"
|
||||
)
|
||||
|
||||
type ElioHandleFunc func(filename string)
|
||||
type ElioHandleFunc func(filename string, csvfilemap *map[string]string) bool
|
||||
|
||||
type ElioDateiFoo struct {
|
||||
process ElioHandleFunc
|
||||
|
|
@ -20,7 +20,7 @@ func NewElioDateiFoo(dir string, process ElioHandleFunc) *ElioDateiFoo {
|
|||
return &df
|
||||
}
|
||||
|
||||
func (f *ElioDateiFoo) ScanCsv() {
|
||||
func (f *ElioDateiFoo) ScanCsv(csvfilemap *map[string]string) {
|
||||
files, err := os.ReadDir(f.dir)
|
||||
|
||||
if err != nil {
|
||||
|
|
@ -29,7 +29,7 @@ func (f *ElioDateiFoo) ScanCsv() {
|
|||
|
||||
for _, file := range files {
|
||||
if strings.Contains(file.Name(), "csv") {
|
||||
f.process(file.Name())
|
||||
f.process(file.Name(), csvfilemap)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue