Eliofile Lister 2
This commit is contained in:
parent
e36a0cd13f
commit
d801fbca0b
|
|
@ -9,10 +9,11 @@ import (
|
||||||
|
|
||||||
type ElioDateiFoo struct {
|
type ElioDateiFoo struct {
|
||||||
process func(file string)
|
process func(file string)
|
||||||
|
dir string
|
||||||
}
|
}
|
||||||
|
|
||||||
func NewElioDateiFoo() *ElioDateiFoo {
|
func NewElioDateiFoo(dir string) *ElioDateiFoo {
|
||||||
df := ElioDateiFoo{
|
df := ElioDateiFoo{dir: dir,
|
||||||
process: func(file string) {
|
process: func(file string) {
|
||||||
fmt.Println(file)
|
fmt.Println(file)
|
||||||
},
|
},
|
||||||
|
|
@ -20,7 +21,7 @@ func NewElioDateiFoo() *ElioDateiFoo {
|
||||||
return &df
|
return &df
|
||||||
}
|
}
|
||||||
|
|
||||||
func (f *ElioDateiFoo) scanCsv() {
|
func (f *ElioDateiFoo) ScanCsv() {
|
||||||
files, err := os.ReadDir(".")
|
files, err := os.ReadDir(".")
|
||||||
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
@ -33,8 +34,3 @@ func (f *ElioDateiFoo) scanCsv() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
|
||||||
df := NewElioDateiFoo()
|
|
||||||
df.scanCsv()
|
|
||||||
}
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue