MCPcopy Create free account
hub / github.com/alecthomas/devtodo2 / fromMarshalableTask

Function fromMarshalableTask

jsonio.go:104–113  ·  view source on GitHub ↗
(node TaskNode, t []*marshalableTask)

Source from the content-addressed store, hash-verified

102}
103
104func fromMarshalableTask(node TaskNode, t []*marshalableTask) {
105 for _, j := range t {
106 task := node.Create(j.Text, PriorityFromString(j.Priority))
107 task.SetCreationTime(time.Unix(j.Creation, 0).UTC())
108 if j.Completion != 0 {
109 task.SetCompletionTime(time.Unix(j.Completion, 0).UTC())
110 }
111 fromMarshalableTask(task, j.Tasks)
112 }
113}

Callers 1

fromMarshalableTaskListFunction · 0.85

Calls 4

PriorityFromStringFunction · 0.85
CreateMethod · 0.65
SetCreationTimeMethod · 0.65
SetCompletionTimeMethod · 0.65

Tested by

no test coverage detected