internal bool LinkWith(IPlexBeaconPin <T> next)
        {
            if (HasNext)
            {
                return(false);
            }

            _Next   = next;
            HasNext = true;
            return(true);
        }
        internal bool LinkWith(IPlexBeaconPin <T> next)
        {
            if (HasNext)
            {
                return(false);
            }

            var mre = Interlocked.Exchange(ref _MRE, null);

            if (mre == null)
            {
                return(false);
            }

            _Next = next;
            mre.Set();

            return(true);
        }
Example #3
0
 public void Dispose()
 => _Held = null;
Example #4
0
 public bool MoveNext()
 => (_Held = _Held?.Next) != null;
Example #5
0
 public DoppelGanger(IPlexBeaconPin <T> held)
 {
     _Held = held;
 }
Example #6
0
 private void Advance(IPlexBeaconPin <byte[]> link)
 {
     _ArrLink  = link;
     _Data     = _ArrLink?.Message;
     _Position = 0;
 }
Example #7
0
 internal PlexStream(IPlexBeaconPin <byte[]> link, int position = 0)
 {
     _ArrLink  = link;
     _Position = position;
 }
Example #8
0
 protected override void Dispose(bool disposing)
 {
     _ArrLink  = null;
     _Data     = null;
     _Position = 0;
 }