Skip to content

nobody05/gdelay

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gdelay

Delayed execution function

Install

go get github.com/nobody05/gdelay

Used

delay := NewDelay(3)
delay.Start()


delay.DelayAdd(&DelayParam{
    Duration: time.Now().Add(time.Second * 3)).Unix(),
    Fun: func() {
        log.Println("hello world")
    },
})

// wait for delay execute 
for {

}

About

golang Deferred execution

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages