diff --git a/events/event_host.go b/events/event_host.go index b3adf69..c72807e 100644 --- a/events/event_host.go +++ b/events/event_host.go @@ -1 +1,43 @@ package events + +type HostStartEvent struct { + ZoneCount int + Zone int64 +} + +func (i HostStartEvent) GetUrl() string { + return HOST_START +} + +func NewHostStartEvent(zoneCount int, cidr int64) *DiscoveryStartEvent { + return &HostStartEvent{ZoneCount: zoneCount, Zone: cidr} +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// + +type HostFoundEvent struct { + Zone int64 + Host int64 +} + +func (i HostFoundEvent) GetUrl() string { + return HOST_FOUND +} + +func NewHostFoundEvent(zone int64, host int64) *DiscoveryStartEvent { + return &HostFoundEvent{Zone: zone, Host: host} +} + +/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// +type HostEndEvent struct { + Zone int64 + Host int64 +} + +func (i HostEndEvent) GetUrl() string { + return HOST_END +} + +func NewHostEndEvent(zone int64, host int64) *DiscoveryStartEvent { + return &HostEndEvent{Zone: zone, Host: host} +}