SoapDocumentMethodAttribute.cs 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114
  1. //
  2. // System.Web.Services.Protocols.SoapDocumentMethodAttribute.cs
  3. //
  4. // Author:
  5. // Tim Coleman ([email protected])
  6. //
  7. // Copyright (C) Tim Coleman, 2002
  8. //
  9. using System.Web.Services.Description;
  10. namespace System.Web.Services.Protocols {
  11. [AttributeUsage (AttributeTargets.Method, Inherited = true)]
  12. public sealed class SoapDocumentMethodAttribute : Attribute {
  13. #region Fields
  14. string action;
  15. string binding;
  16. bool oneWay;
  17. SoapParameterStyle parameterStyle;
  18. string requestElementName;
  19. string requestNamespace;
  20. string responseElementName;
  21. string responseNamespace;
  22. SoapBindingUse use;
  23. #endregion
  24. #region Constructors
  25. public SoapDocumentMethodAttribute ()
  26. {
  27. }
  28. public SoapDocumentMethodAttribute (string action)
  29. : this ()
  30. {
  31. this.action = action;
  32. }
  33. #endregion // Constructors
  34. #region Properties
  35. public string Action {
  36. get { return action; }
  37. set { action = value; }
  38. }
  39. public string Binding {
  40. get {
  41. if (binding != null)
  42. return binding;
  43. return "";
  44. }
  45. set { binding = value; }
  46. }
  47. public bool OneWay {
  48. get { return oneWay; }
  49. set { oneWay = value; }
  50. }
  51. public SoapParameterStyle ParameterStyle {
  52. get { return parameterStyle; }
  53. set { parameterStyle = value; }
  54. }
  55. public string RequestElementName {
  56. get {
  57. if (requestElementName == null)
  58. return "";
  59. return requestElementName;
  60. }
  61. set { requestElementName = value; }
  62. }
  63. public string RequestNamespace {
  64. get {
  65. if (requestNamespace == null)
  66. return "";
  67. return requestNamespace;
  68. }
  69. set { requestNamespace = value; }
  70. }
  71. public string ResponseElementName {
  72. get {
  73. if (responseElementName == null)
  74. return "";
  75. return responseElementName;
  76. }
  77. set { responseElementName = value; }
  78. }
  79. public string ResponseNamespace {
  80. get {
  81. if (responseNamespace == null)
  82. return "";
  83. return responseNamespace;
  84. }
  85. set { responseNamespace = value; }
  86. }
  87. public SoapBindingUse Use {
  88. get { return use; }
  89. set { use = value; }
  90. }
  91. #endregion // Properties
  92. }
  93. }