Remove unused GetEntry method, DataUnmarshaler struct and UnmarshalData method

This commit is contained in:
M. Mert Yildiran 2022-03-04 19:04:55 +03:00
parent b1b7462427
commit 0d4c65d19e
No known key found for this signature in database
GPG Key ID: D42ADB236521BF7A
2 changed files with 0 additions and 19 deletions

View File

@ -12,10 +12,6 @@ import (
"github.com/up9inc/mizu/tap"
)
func GetEntry(r *tapApi.Entry, v tapApi.DataUnmarshaler) error {
return v.UnmarshalData(r)
}
type TapConfig struct {
TappedNamespaces map[string]bool `json:"tappedNamespaces"`
}

View File

@ -188,21 +188,6 @@ type Contract struct {
Content string `json:"content"`
}
type DataUnmarshaler interface {
UnmarshalData(*Entry) error
}
func (bed *BaseEntry) UnmarshalData(entry *Entry) error {
bed.Protocol = entry.Protocol
bed.Id = entry.Id
bed.Timestamp = entry.Timestamp
bed.Source = entry.Source
bed.Destination = entry.Destination
bed.Latency = entry.ElapsedTime
bed.ContractStatus = entry.ContractStatus
return nil
}
const (
TABLE string = "table"
BODY string = "body"