Add DeleteSync() to generate/template.go.

This commit is contained in:
Greg 2018-08-09 16:15:00 -04:00
parent 9653dab9f4
commit d6f4920507

View File

@ -49,6 +49,11 @@ func (v *Var_N) Delete(t time.Time) {
ptr.Delete(t) ptr.Delete(t)
} }
func (v *Var_N) DeleteSync(t time.Time) {
ptr := (*persist.Var)(unsafe.Pointer(v))
ptr.Delete(t)
}
func (v *Var_N) History() ([]Var_N, error) { func (v *Var_N) History() ([]Var_N, error) {
ptr := (*persist.Var)(unsafe.Pointer(v)) ptr := (*persist.Var)(unsafe.Pointer(v))
h, err := ptr.History() h, err := ptr.History()