public async Task StartTagStreamOld(IObserver <Tag> tags) { tagStreamListener?.Dispose(); await api.TagStreamKeepAliveTime(1800); await api.TagStreamFormat(ListFormat.Custom); await api.TagStreamCustomFormat(Tag.CustomFormat); await api.AutoModeReset(); await api.Clear(); await api.StreamHeader(true); await api.NotifyMode(false); var ep = new IPEndPoint(EndpointLookup.GetIpOnTheSameNet(IPAddress.Parse(host)), 0); tagStreamListener = new AlienTagStreamListener(ep, tags); await api.TagStreamAddress(tagStreamListener.EndPoint); await api.TagStreamMode(true); await api.AutoMode(true); }
//[Fact] public void Get_local_address_on_same_subnet() { var t = EndpointLookup.GetIpOnTheSameNet(IPAddress.Parse("10.0.0.41")); t.ToString().ShouldStartWith("10.0.0."); }