Пример #1
0
        IdentifyResponse Identify(NetworkStream stream, FrameReader reader)
        {
            var identify = new Identify(_options);

            SendCommandToStream(stream, identify);
            var frame = reader.ReadFrame();

            if (frame.Type != FrameType.Result)
            {
                throw new InvalidOperationException("Unexpected frame type after IDENTIFY");
            }
            return(identify.ParseIdentifyResponse(frame.Data));
        }
Пример #2
0
 IdentifyResponse Identify(NetworkStream stream, FrameReader reader)
 {
     var identify = new Identify(_options);
     SendCommandToStream(stream, identify);
     var frame = reader.ReadFrame();
     if (frame.Type != FrameType.Result)
     {
         throw new InvalidOperationException("Unexpected frame type after IDENTIFY");
     }
     return identify.ParseIdentifyResponse(frame.Data);
 }