SoapClientMessage.cs 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. //
  2. // System.Web.Services.Protocols.SoapClientMessage.cs
  3. //
  4. // Authors:
  5. // Tim Coleman ([email protected])
  6. // Miguel de Icaza ([email protected])
  7. //
  8. // Copyright (C) Tim Coleman, 2002
  9. // Copyright (C) Ximian, Inc. 2003
  10. //
  11. using System.Web.Services;
  12. using System.Web.Services.Protocols;
  13. namespace System.Web.Services.Protocols {
  14. public sealed class SoapClientMessage : SoapMessage {
  15. #region Fields
  16. SoapHttpClientProtocol client;
  17. string url;
  18. LogicalMethodInfo client_method;
  19. internal SoapMethodStubInfo MethodStubInfo;
  20. //
  21. // Expose this one internally
  22. //
  23. internal object [] Parameters;
  24. #endregion
  25. #region Constructors
  26. //
  27. // Constructs the SoapClientMessage
  28. //
  29. internal SoapClientMessage (SoapHttpClientProtocol client, SoapMethodStubInfo msi, string url, object [] parameters)
  30. {
  31. this.MethodStubInfo = msi;
  32. this.client = client;
  33. this.client_method = client_method;
  34. this.url = url;
  35. Parameters = parameters;
  36. }
  37. #endregion
  38. #region Properties
  39. public override string Action {
  40. get { return MethodStubInfo.Action; }
  41. }
  42. public SoapHttpClientProtocol Client {
  43. get { return client; }
  44. }
  45. public override LogicalMethodInfo MethodInfo {
  46. get { return client_method; }
  47. }
  48. public override bool OneWay {
  49. get { return MethodStubInfo.OneWay; }
  50. }
  51. public override string Url {
  52. get { return url; }
  53. }
  54. #endregion // Properties
  55. #region Methods
  56. protected override void EnsureInStage ()
  57. {
  58. EnsureStage (SoapMessageStage.BeforeSerialize);
  59. }
  60. protected override void EnsureOutStage ()
  61. {
  62. EnsureStage (SoapMessageStage.AfterDeserialize);
  63. }
  64. #endregion // Methods
  65. }
  66. }