ServiceSettingsResponseInfo.cs 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. //
  2. // ServiceSettingsResponseInfo.cs
  3. //
  4. // Author:
  5. // Marcos Cobena ([email protected])
  6. //
  7. // Copyright 2007 Marcos Cobena (http://www.youcannoteatbits.org/)
  8. //
  9. using System.Runtime.Serialization;
  10. namespace System.ServiceModel.PeerResolvers
  11. {
  12. [MessageContract (IsWrapped = false)]
  13. public class ServiceSettingsResponseInfo
  14. {
  15. [MessageBodyMember (Name = "ServiceSettings", Namespace = "http://schemas.microsoft.com/net/2006/05/peer")]
  16. ServiceSettingsResponseInfoDC Body {
  17. get {
  18. if (body == null)
  19. body = new ServiceSettingsResponseInfoDC ();
  20. return body;
  21. }
  22. }
  23. ServiceSettingsResponseInfoDC body;
  24. public ServiceSettingsResponseInfo ()
  25. {
  26. }
  27. public ServiceSettingsResponseInfo (bool control)
  28. {
  29. Body.ControlMeshShape = control;
  30. }
  31. public bool ControlMeshShape {
  32. get { return Body.ControlMeshShape; }
  33. set { Body.ControlMeshShape = value; }
  34. }
  35. public bool HasBody ()
  36. {
  37. return true; // FIXME: I have no idea when it returns false
  38. }
  39. }
  40. [DataContract (Name = "ServiceSettings", Namespace = "http://schemas.microsoft.com/net/2006/05/peer")]
  41. internal class ServiceSettingsResponseInfoDC
  42. {
  43. bool control_mesh_shape;
  44. public ServiceSettingsResponseInfoDC ()
  45. {
  46. }
  47. [DataMember]
  48. public bool ControlMeshShape {
  49. get { return control_mesh_shape; }
  50. set { control_mesh_shape = value; }
  51. }
  52. }
  53. }