Created
January 28, 2017 14:25
-
-
Save matthewmueller/42ec69752e992793e7de9e902ff79da2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package main | |
func main() { | |
task := model.NewTask() | |
err := task.Create(model.Task{ | |
Rate: "* * * * *", | |
Key: "hi world", | |
}) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package model | |
// T struct | |
type T struct{} | |
// Task struct | |
type Task struct { | |
Key string | |
Rate string | |
} | |
// NewTask create a new task instance | |
func NewTask() T { | |
return T{} | |
} | |
// Create events | |
func (T) Create(t Task) ([]Event, error) { | |
var events []Event | |
return events, nil | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment