//----------------------------------------------------------------------- // // Copyright (c) Andrew Arnott. All rights reserved. // //----------------------------------------------------------------------- namespace DotNetOpenAuth.Test.Mocks { using System; using System.Collections.Generic; using System.Linq; using System.Text; using DotNetOpenAuth.Messaging; internal class CoordinatingOutgoingWebResponse : OutgoingWebResponse { private CoordinatingChannel receivingChannel; /// /// Initializes a new instance of the class. /// /// The direct response message to send to the remote channel. This message will be cloned. /// The receiving channel. internal CoordinatingOutgoingWebResponse(IProtocolMessage message, CoordinatingChannel receivingChannel) { ErrorUtilities.VerifyArgumentNotNull(message, "message"); ErrorUtilities.VerifyArgumentNotNull(receivingChannel, "receivingChannel"); this.receivingChannel = receivingChannel; this.OriginalMessage = message; } public override void Send() { this.receivingChannel.PostMessage(this.OriginalMessage); } } }