Exemplo n.º 1
0
        public async Task <EnvironmentResponse> WriteStartAsync(ISession session, ConnectionMode mode, string secret)
        {
            var response = await session.ReadAsync();

            RequestWriterAssert.Connected(response);

            await session.WriteAsync("START", mode.ToString().ToLowerInvariant(), secret);

            return(StartResponseParser.Parse(await session.ReadAsync()));
        }
Exemplo n.º 2
0
        public EnvironmentResponse WriteStart(ISession session, ConnectionMode mode, string secret)
        {
            var response = session.Read();

            RequestWriterAssert.Connected(response);

            session.Write("START", mode.ToString().ToLowerInvariant(), secret);

            return(StartResponseParser.Parse(session.Read()));
        }