From b933083d20b3db4a3d6a8134efe312eb6ff3d8e2 Mon Sep 17 00:00:00 2001 From: Keuin Date: Sat, 9 Mar 2024 20:19:35 +0800 Subject: initial version --- protocol/observe.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 protocol/observe.go (limited to 'protocol/observe.go') diff --git a/protocol/observe.go b/protocol/observe.go new file mode 100644 index 0000000..48d052a --- /dev/null +++ b/protocol/observe.go @@ -0,0 +1,14 @@ +package protocol + +import ( + "fmt" +) + +type Target struct { + Host string `json:"host"` + Port uint16 `json:"port"` +} + +func (t Target) String() string { + return fmt.Sprintf("%s:%d", t.Host, t.Port) +} -- cgit v1.2.3