SegmentPointMesg.cs 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198
  1. #region Copyright
  2. ////////////////////////////////////////////////////////////////////////////////
  3. // The following FIT Protocol software provided may be used with FIT protocol
  4. // devices only and remains the copyrighted property of Dynastream Innovations Inc.
  5. // The software is being provided on an "as-is" basis and as an accommodation,
  6. // and therefore all warranties, representations, or guarantees of any kind
  7. // (whether express, implied or statutory) including, without limitation,
  8. // warranties of merchantability, non-infringement, or fitness for a particular
  9. // purpose, are specifically disclaimed.
  10. //
  11. // Copyright 2016 Dynastream Innovations Inc.
  12. ////////////////////////////////////////////////////////////////////////////////
  13. // ****WARNING**** This file is auto-generated! Do NOT edit this file.
  14. // Profile Version = 16.60Release
  15. // Tag = production-akw-16.60.00-0-g5d3d436
  16. ////////////////////////////////////////////////////////////////////////////////
  17. #endregion
  18. using System;
  19. using System.Collections.Generic;
  20. using System.Diagnostics;
  21. using System.Text;
  22. using System.IO;
  23. namespace Dynastream.Fit
  24. {
  25. /// <summary>
  26. /// Implements the SegmentPoint profile message.
  27. /// </summary>
  28. public class SegmentPointMesg : Mesg
  29. {
  30. #region Fields
  31. #endregion
  32. #region Constructors
  33. public SegmentPointMesg() : base(Profile.GetMesg(MesgNum.SegmentPoint))
  34. {
  35. }
  36. public SegmentPointMesg(Mesg mesg) : base(mesg)
  37. {
  38. }
  39. #endregion // Constructors
  40. #region Methods
  41. ///<summary>
  42. /// Retrieves the MessageIndex field</summary>
  43. /// <returns>Returns nullable ushort representing the MessageIndex field</returns>
  44. public ushort? GetMessageIndex()
  45. {
  46. return (ushort?)GetFieldValue(254, 0, Fit.SubfieldIndexMainField);
  47. }
  48. /// <summary>
  49. /// Set MessageIndex field</summary>
  50. /// <param name="messageIndex_">Nullable field value to be set</param>
  51. public void SetMessageIndex(ushort? messageIndex_)
  52. {
  53. SetFieldValue(254, 0, messageIndex_, Fit.SubfieldIndexMainField);
  54. }
  55. ///<summary>
  56. /// Retrieves the PositionLat field
  57. /// Units: semicircles</summary>
  58. /// <returns>Returns nullable int representing the PositionLat field</returns>
  59. public int? GetPositionLat()
  60. {
  61. return (int?)GetFieldValue(1, 0, Fit.SubfieldIndexMainField);
  62. }
  63. /// <summary>
  64. /// Set PositionLat field
  65. /// Units: semicircles</summary>
  66. /// <param name="positionLat_">Nullable field value to be set</param>
  67. public void SetPositionLat(int? positionLat_)
  68. {
  69. SetFieldValue(1, 0, positionLat_, Fit.SubfieldIndexMainField);
  70. }
  71. ///<summary>
  72. /// Retrieves the PositionLong field
  73. /// Units: semicircles</summary>
  74. /// <returns>Returns nullable int representing the PositionLong field</returns>
  75. public int? GetPositionLong()
  76. {
  77. return (int?)GetFieldValue(2, 0, Fit.SubfieldIndexMainField);
  78. }
  79. /// <summary>
  80. /// Set PositionLong field
  81. /// Units: semicircles</summary>
  82. /// <param name="positionLong_">Nullable field value to be set</param>
  83. public void SetPositionLong(int? positionLong_)
  84. {
  85. SetFieldValue(2, 0, positionLong_, Fit.SubfieldIndexMainField);
  86. }
  87. ///<summary>
  88. /// Retrieves the Distance field
  89. /// Units: m
  90. /// Comment: Accumulated distance along the segment at the described point</summary>
  91. /// <returns>Returns nullable float representing the Distance field</returns>
  92. public float? GetDistance()
  93. {
  94. return (float?)GetFieldValue(3, 0, Fit.SubfieldIndexMainField);
  95. }
  96. /// <summary>
  97. /// Set Distance field
  98. /// Units: m
  99. /// Comment: Accumulated distance along the segment at the described point</summary>
  100. /// <param name="distance_">Nullable field value to be set</param>
  101. public void SetDistance(float? distance_)
  102. {
  103. SetFieldValue(3, 0, distance_, Fit.SubfieldIndexMainField);
  104. }
  105. ///<summary>
  106. /// Retrieves the Altitude field
  107. /// Units: m
  108. /// Comment: Accumulated altitude along the segment at the described point</summary>
  109. /// <returns>Returns nullable float representing the Altitude field</returns>
  110. public float? GetAltitude()
  111. {
  112. return (float?)GetFieldValue(4, 0, Fit.SubfieldIndexMainField);
  113. }
  114. /// <summary>
  115. /// Set Altitude field
  116. /// Units: m
  117. /// Comment: Accumulated altitude along the segment at the described point</summary>
  118. /// <param name="altitude_">Nullable field value to be set</param>
  119. public void SetAltitude(float? altitude_)
  120. {
  121. SetFieldValue(4, 0, altitude_, Fit.SubfieldIndexMainField);
  122. }
  123. /// <summary>
  124. ///
  125. /// </summary>
  126. /// <returns>returns number of elements in field LeaderTime</returns>
  127. public int GetNumLeaderTime()
  128. {
  129. return GetNumFieldValues(5, Fit.SubfieldIndexMainField);
  130. }
  131. ///<summary>
  132. /// Retrieves the LeaderTime field
  133. /// Units: s
  134. /// Comment: Accumualted time each leader board member required to reach the described point. This value is zero for all leader board members at the starting point of the segment. </summary>
  135. /// <param name="index">0 based index of LeaderTime element to retrieve</param>
  136. /// <returns>Returns nullable float representing the LeaderTime field</returns>
  137. public float? GetLeaderTime(int index)
  138. {
  139. return (float?)GetFieldValue(5, index, Fit.SubfieldIndexMainField);
  140. }
  141. /// <summary>
  142. /// Set LeaderTime field
  143. /// Units: s
  144. /// Comment: Accumualted time each leader board member required to reach the described point. This value is zero for all leader board members at the starting point of the segment. </summary>
  145. /// <param name="index">0 based index of leader_time</param>
  146. /// <param name="leaderTime_">Nullable field value to be set</param>
  147. public void SetLeaderTime(int index, float? leaderTime_)
  148. {
  149. SetFieldValue(5, index, leaderTime_, Fit.SubfieldIndexMainField);
  150. }
  151. #endregion // Methods
  152. } // Class
  153. } // namespace