SoapHeaderAttribute.cs 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. //
  2. // System.Web.Services.Protocols.SoapHeaderAttribute.cs
  3. //
  4. // Author:
  5. // Tim Coleman ([email protected])
  6. //
  7. // Copyright (C) Tim Coleman, 2002
  8. //
  9. namespace System.Web.Services.Protocols {
  10. [AttributeUsage (AttributeTargets.Method, AllowMultiple = true, Inherited = true)]
  11. public sealed class SoapHeaderAttribute : Attribute {
  12. #region Fields
  13. SoapHeaderDirection direction;
  14. string memberName;
  15. bool required;
  16. #endregion // Fields
  17. #region Constructors
  18. public SoapHeaderAttribute (string memberName)
  19. {
  20. direction = SoapHeaderDirection.In;
  21. this.memberName = memberName;
  22. required = true;
  23. }
  24. #endregion // Constructors
  25. #region Properties
  26. public SoapHeaderDirection Direction {
  27. get { return direction; }
  28. set { direction = value; }
  29. }
  30. public string MemberName {
  31. get { return memberName; }
  32. set { memberName = value; }
  33. }
  34. public bool Required {
  35. get { return required; }
  36. set { required = value; }
  37. }
  38. #endregion // Properties
  39. }
  40. }