BikeProfileMesg.cs 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772
  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 BikeProfile profile message.
  27. /// </summary>
  28. public class BikeProfileMesg : Mesg
  29. {
  30. #region Fields
  31. #endregion
  32. #region Constructors
  33. public BikeProfileMesg() : base(Profile.GetMesg(MesgNum.BikeProfile))
  34. {
  35. }
  36. public BikeProfileMesg(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 Name field</summary>
  57. /// <returns>Returns byte[] representing the Name field</returns>
  58. public byte[] GetName()
  59. {
  60. return (byte[])GetFieldValue(0, 0, Fit.SubfieldIndexMainField);
  61. }
  62. ///<summary>
  63. /// Retrieves the Name field</summary>
  64. /// <returns>Returns String representing the Name field</returns>
  65. public String GetNameAsString()
  66. {
  67. return Encoding.UTF8.GetString((byte[])GetFieldValue(0, 0, Fit.SubfieldIndexMainField));
  68. }
  69. ///<summary>
  70. /// Set Name field</summary>
  71. /// <param name="name_"> field value to be set</param>
  72. public void SetName(String name_)
  73. {
  74. SetFieldValue(0, 0, System.Text.Encoding.UTF8.GetBytes(name_), Fit.SubfieldIndexMainField);
  75. }
  76. /// <summary>
  77. /// Set Name field</summary>
  78. /// <param name="name_">field value to be set</param>
  79. public void SetName(byte[] name_)
  80. {
  81. SetFieldValue(0, 0, name_, Fit.SubfieldIndexMainField);
  82. }
  83. ///<summary>
  84. /// Retrieves the Sport field</summary>
  85. /// <returns>Returns nullable Sport enum representing the Sport field</returns>
  86. public Sport? GetSport()
  87. {
  88. object obj = GetFieldValue(1, 0, Fit.SubfieldIndexMainField);
  89. Sport? value = obj == null ? (Sport?)null : (Sport)obj;
  90. return value;
  91. }
  92. /// <summary>
  93. /// Set Sport field</summary>
  94. /// <param name="sport_">Nullable field value to be set</param>
  95. public void SetSport(Sport? sport_)
  96. {
  97. SetFieldValue(1, 0, sport_, Fit.SubfieldIndexMainField);
  98. }
  99. ///<summary>
  100. /// Retrieves the SubSport field</summary>
  101. /// <returns>Returns nullable SubSport enum representing the SubSport field</returns>
  102. public SubSport? GetSubSport()
  103. {
  104. object obj = GetFieldValue(2, 0, Fit.SubfieldIndexMainField);
  105. SubSport? value = obj == null ? (SubSport?)null : (SubSport)obj;
  106. return value;
  107. }
  108. /// <summary>
  109. /// Set SubSport field</summary>
  110. /// <param name="subSport_">Nullable field value to be set</param>
  111. public void SetSubSport(SubSport? subSport_)
  112. {
  113. SetFieldValue(2, 0, subSport_, Fit.SubfieldIndexMainField);
  114. }
  115. ///<summary>
  116. /// Retrieves the Odometer field
  117. /// Units: m</summary>
  118. /// <returns>Returns nullable float representing the Odometer field</returns>
  119. public float? GetOdometer()
  120. {
  121. return (float?)GetFieldValue(3, 0, Fit.SubfieldIndexMainField);
  122. }
  123. /// <summary>
  124. /// Set Odometer field
  125. /// Units: m</summary>
  126. /// <param name="odometer_">Nullable field value to be set</param>
  127. public void SetOdometer(float? odometer_)
  128. {
  129. SetFieldValue(3, 0, odometer_, Fit.SubfieldIndexMainField);
  130. }
  131. ///<summary>
  132. /// Retrieves the BikeSpdAntId field</summary>
  133. /// <returns>Returns nullable ushort representing the BikeSpdAntId field</returns>
  134. public ushort? GetBikeSpdAntId()
  135. {
  136. return (ushort?)GetFieldValue(4, 0, Fit.SubfieldIndexMainField);
  137. }
  138. /// <summary>
  139. /// Set BikeSpdAntId field</summary>
  140. /// <param name="bikeSpdAntId_">Nullable field value to be set</param>
  141. public void SetBikeSpdAntId(ushort? bikeSpdAntId_)
  142. {
  143. SetFieldValue(4, 0, bikeSpdAntId_, Fit.SubfieldIndexMainField);
  144. }
  145. ///<summary>
  146. /// Retrieves the BikeCadAntId field</summary>
  147. /// <returns>Returns nullable ushort representing the BikeCadAntId field</returns>
  148. public ushort? GetBikeCadAntId()
  149. {
  150. return (ushort?)GetFieldValue(5, 0, Fit.SubfieldIndexMainField);
  151. }
  152. /// <summary>
  153. /// Set BikeCadAntId field</summary>
  154. /// <param name="bikeCadAntId_">Nullable field value to be set</param>
  155. public void SetBikeCadAntId(ushort? bikeCadAntId_)
  156. {
  157. SetFieldValue(5, 0, bikeCadAntId_, Fit.SubfieldIndexMainField);
  158. }
  159. ///<summary>
  160. /// Retrieves the BikeSpdcadAntId field</summary>
  161. /// <returns>Returns nullable ushort representing the BikeSpdcadAntId field</returns>
  162. public ushort? GetBikeSpdcadAntId()
  163. {
  164. return (ushort?)GetFieldValue(6, 0, Fit.SubfieldIndexMainField);
  165. }
  166. /// <summary>
  167. /// Set BikeSpdcadAntId field</summary>
  168. /// <param name="bikeSpdcadAntId_">Nullable field value to be set</param>
  169. public void SetBikeSpdcadAntId(ushort? bikeSpdcadAntId_)
  170. {
  171. SetFieldValue(6, 0, bikeSpdcadAntId_, Fit.SubfieldIndexMainField);
  172. }
  173. ///<summary>
  174. /// Retrieves the BikePowerAntId field</summary>
  175. /// <returns>Returns nullable ushort representing the BikePowerAntId field</returns>
  176. public ushort? GetBikePowerAntId()
  177. {
  178. return (ushort?)GetFieldValue(7, 0, Fit.SubfieldIndexMainField);
  179. }
  180. /// <summary>
  181. /// Set BikePowerAntId field</summary>
  182. /// <param name="bikePowerAntId_">Nullable field value to be set</param>
  183. public void SetBikePowerAntId(ushort? bikePowerAntId_)
  184. {
  185. SetFieldValue(7, 0, bikePowerAntId_, Fit.SubfieldIndexMainField);
  186. }
  187. ///<summary>
  188. /// Retrieves the CustomWheelsize field
  189. /// Units: m</summary>
  190. /// <returns>Returns nullable float representing the CustomWheelsize field</returns>
  191. public float? GetCustomWheelsize()
  192. {
  193. return (float?)GetFieldValue(8, 0, Fit.SubfieldIndexMainField);
  194. }
  195. /// <summary>
  196. /// Set CustomWheelsize field
  197. /// Units: m</summary>
  198. /// <param name="customWheelsize_">Nullable field value to be set</param>
  199. public void SetCustomWheelsize(float? customWheelsize_)
  200. {
  201. SetFieldValue(8, 0, customWheelsize_, Fit.SubfieldIndexMainField);
  202. }
  203. ///<summary>
  204. /// Retrieves the AutoWheelsize field
  205. /// Units: m</summary>
  206. /// <returns>Returns nullable float representing the AutoWheelsize field</returns>
  207. public float? GetAutoWheelsize()
  208. {
  209. return (float?)GetFieldValue(9, 0, Fit.SubfieldIndexMainField);
  210. }
  211. /// <summary>
  212. /// Set AutoWheelsize field
  213. /// Units: m</summary>
  214. /// <param name="autoWheelsize_">Nullable field value to be set</param>
  215. public void SetAutoWheelsize(float? autoWheelsize_)
  216. {
  217. SetFieldValue(9, 0, autoWheelsize_, Fit.SubfieldIndexMainField);
  218. }
  219. ///<summary>
  220. /// Retrieves the BikeWeight field
  221. /// Units: kg</summary>
  222. /// <returns>Returns nullable float representing the BikeWeight field</returns>
  223. public float? GetBikeWeight()
  224. {
  225. return (float?)GetFieldValue(10, 0, Fit.SubfieldIndexMainField);
  226. }
  227. /// <summary>
  228. /// Set BikeWeight field
  229. /// Units: kg</summary>
  230. /// <param name="bikeWeight_">Nullable field value to be set</param>
  231. public void SetBikeWeight(float? bikeWeight_)
  232. {
  233. SetFieldValue(10, 0, bikeWeight_, Fit.SubfieldIndexMainField);
  234. }
  235. ///<summary>
  236. /// Retrieves the PowerCalFactor field
  237. /// Units: %</summary>
  238. /// <returns>Returns nullable float representing the PowerCalFactor field</returns>
  239. public float? GetPowerCalFactor()
  240. {
  241. return (float?)GetFieldValue(11, 0, Fit.SubfieldIndexMainField);
  242. }
  243. /// <summary>
  244. /// Set PowerCalFactor field
  245. /// Units: %</summary>
  246. /// <param name="powerCalFactor_">Nullable field value to be set</param>
  247. public void SetPowerCalFactor(float? powerCalFactor_)
  248. {
  249. SetFieldValue(11, 0, powerCalFactor_, Fit.SubfieldIndexMainField);
  250. }
  251. ///<summary>
  252. /// Retrieves the AutoWheelCal field</summary>
  253. /// <returns>Returns nullable Bool enum representing the AutoWheelCal field</returns>
  254. public Bool? GetAutoWheelCal()
  255. {
  256. object obj = GetFieldValue(12, 0, Fit.SubfieldIndexMainField);
  257. Bool? value = obj == null ? (Bool?)null : (Bool)obj;
  258. return value;
  259. }
  260. /// <summary>
  261. /// Set AutoWheelCal field</summary>
  262. /// <param name="autoWheelCal_">Nullable field value to be set</param>
  263. public void SetAutoWheelCal(Bool? autoWheelCal_)
  264. {
  265. SetFieldValue(12, 0, autoWheelCal_, Fit.SubfieldIndexMainField);
  266. }
  267. ///<summary>
  268. /// Retrieves the AutoPowerZero field</summary>
  269. /// <returns>Returns nullable Bool enum representing the AutoPowerZero field</returns>
  270. public Bool? GetAutoPowerZero()
  271. {
  272. object obj = GetFieldValue(13, 0, Fit.SubfieldIndexMainField);
  273. Bool? value = obj == null ? (Bool?)null : (Bool)obj;
  274. return value;
  275. }
  276. /// <summary>
  277. /// Set AutoPowerZero field</summary>
  278. /// <param name="autoPowerZero_">Nullable field value to be set</param>
  279. public void SetAutoPowerZero(Bool? autoPowerZero_)
  280. {
  281. SetFieldValue(13, 0, autoPowerZero_, Fit.SubfieldIndexMainField);
  282. }
  283. ///<summary>
  284. /// Retrieves the Id field</summary>
  285. /// <returns>Returns nullable byte representing the Id field</returns>
  286. public byte? GetId()
  287. {
  288. return (byte?)GetFieldValue(14, 0, Fit.SubfieldIndexMainField);
  289. }
  290. /// <summary>
  291. /// Set Id field</summary>
  292. /// <param name="id_">Nullable field value to be set</param>
  293. public void SetId(byte? id_)
  294. {
  295. SetFieldValue(14, 0, id_, Fit.SubfieldIndexMainField);
  296. }
  297. ///<summary>
  298. /// Retrieves the SpdEnabled field</summary>
  299. /// <returns>Returns nullable Bool enum representing the SpdEnabled field</returns>
  300. public Bool? GetSpdEnabled()
  301. {
  302. object obj = GetFieldValue(15, 0, Fit.SubfieldIndexMainField);
  303. Bool? value = obj == null ? (Bool?)null : (Bool)obj;
  304. return value;
  305. }
  306. /// <summary>
  307. /// Set SpdEnabled field</summary>
  308. /// <param name="spdEnabled_">Nullable field value to be set</param>
  309. public void SetSpdEnabled(Bool? spdEnabled_)
  310. {
  311. SetFieldValue(15, 0, spdEnabled_, Fit.SubfieldIndexMainField);
  312. }
  313. ///<summary>
  314. /// Retrieves the CadEnabled field</summary>
  315. /// <returns>Returns nullable Bool enum representing the CadEnabled field</returns>
  316. public Bool? GetCadEnabled()
  317. {
  318. object obj = GetFieldValue(16, 0, Fit.SubfieldIndexMainField);
  319. Bool? value = obj == null ? (Bool?)null : (Bool)obj;
  320. return value;
  321. }
  322. /// <summary>
  323. /// Set CadEnabled field</summary>
  324. /// <param name="cadEnabled_">Nullable field value to be set</param>
  325. public void SetCadEnabled(Bool? cadEnabled_)
  326. {
  327. SetFieldValue(16, 0, cadEnabled_, Fit.SubfieldIndexMainField);
  328. }
  329. ///<summary>
  330. /// Retrieves the SpdcadEnabled field</summary>
  331. /// <returns>Returns nullable Bool enum representing the SpdcadEnabled field</returns>
  332. public Bool? GetSpdcadEnabled()
  333. {
  334. object obj = GetFieldValue(17, 0, Fit.SubfieldIndexMainField);
  335. Bool? value = obj == null ? (Bool?)null : (Bool)obj;
  336. return value;
  337. }
  338. /// <summary>
  339. /// Set SpdcadEnabled field</summary>
  340. /// <param name="spdcadEnabled_">Nullable field value to be set</param>
  341. public void SetSpdcadEnabled(Bool? spdcadEnabled_)
  342. {
  343. SetFieldValue(17, 0, spdcadEnabled_, Fit.SubfieldIndexMainField);
  344. }
  345. ///<summary>
  346. /// Retrieves the PowerEnabled field</summary>
  347. /// <returns>Returns nullable Bool enum representing the PowerEnabled field</returns>
  348. public Bool? GetPowerEnabled()
  349. {
  350. object obj = GetFieldValue(18, 0, Fit.SubfieldIndexMainField);
  351. Bool? value = obj == null ? (Bool?)null : (Bool)obj;
  352. return value;
  353. }
  354. /// <summary>
  355. /// Set PowerEnabled field</summary>
  356. /// <param name="powerEnabled_">Nullable field value to be set</param>
  357. public void SetPowerEnabled(Bool? powerEnabled_)
  358. {
  359. SetFieldValue(18, 0, powerEnabled_, Fit.SubfieldIndexMainField);
  360. }
  361. ///<summary>
  362. /// Retrieves the CrankLength field
  363. /// Units: mm</summary>
  364. /// <returns>Returns nullable float representing the CrankLength field</returns>
  365. public float? GetCrankLength()
  366. {
  367. return (float?)GetFieldValue(19, 0, Fit.SubfieldIndexMainField);
  368. }
  369. /// <summary>
  370. /// Set CrankLength field
  371. /// Units: mm</summary>
  372. /// <param name="crankLength_">Nullable field value to be set</param>
  373. public void SetCrankLength(float? crankLength_)
  374. {
  375. SetFieldValue(19, 0, crankLength_, Fit.SubfieldIndexMainField);
  376. }
  377. ///<summary>
  378. /// Retrieves the Enabled field</summary>
  379. /// <returns>Returns nullable Bool enum representing the Enabled field</returns>
  380. public Bool? GetEnabled()
  381. {
  382. object obj = GetFieldValue(20, 0, Fit.SubfieldIndexMainField);
  383. Bool? value = obj == null ? (Bool?)null : (Bool)obj;
  384. return value;
  385. }
  386. /// <summary>
  387. /// Set Enabled field</summary>
  388. /// <param name="enabled_">Nullable field value to be set</param>
  389. public void SetEnabled(Bool? enabled_)
  390. {
  391. SetFieldValue(20, 0, enabled_, Fit.SubfieldIndexMainField);
  392. }
  393. ///<summary>
  394. /// Retrieves the BikeSpdAntIdTransType field</summary>
  395. /// <returns>Returns nullable byte representing the BikeSpdAntIdTransType field</returns>
  396. public byte? GetBikeSpdAntIdTransType()
  397. {
  398. return (byte?)GetFieldValue(21, 0, Fit.SubfieldIndexMainField);
  399. }
  400. /// <summary>
  401. /// Set BikeSpdAntIdTransType field</summary>
  402. /// <param name="bikeSpdAntIdTransType_">Nullable field value to be set</param>
  403. public void SetBikeSpdAntIdTransType(byte? bikeSpdAntIdTransType_)
  404. {
  405. SetFieldValue(21, 0, bikeSpdAntIdTransType_, Fit.SubfieldIndexMainField);
  406. }
  407. ///<summary>
  408. /// Retrieves the BikeCadAntIdTransType field</summary>
  409. /// <returns>Returns nullable byte representing the BikeCadAntIdTransType field</returns>
  410. public byte? GetBikeCadAntIdTransType()
  411. {
  412. return (byte?)GetFieldValue(22, 0, Fit.SubfieldIndexMainField);
  413. }
  414. /// <summary>
  415. /// Set BikeCadAntIdTransType field</summary>
  416. /// <param name="bikeCadAntIdTransType_">Nullable field value to be set</param>
  417. public void SetBikeCadAntIdTransType(byte? bikeCadAntIdTransType_)
  418. {
  419. SetFieldValue(22, 0, bikeCadAntIdTransType_, Fit.SubfieldIndexMainField);
  420. }
  421. ///<summary>
  422. /// Retrieves the BikeSpdcadAntIdTransType field</summary>
  423. /// <returns>Returns nullable byte representing the BikeSpdcadAntIdTransType field</returns>
  424. public byte? GetBikeSpdcadAntIdTransType()
  425. {
  426. return (byte?)GetFieldValue(23, 0, Fit.SubfieldIndexMainField);
  427. }
  428. /// <summary>
  429. /// Set BikeSpdcadAntIdTransType field</summary>
  430. /// <param name="bikeSpdcadAntIdTransType_">Nullable field value to be set</param>
  431. public void SetBikeSpdcadAntIdTransType(byte? bikeSpdcadAntIdTransType_)
  432. {
  433. SetFieldValue(23, 0, bikeSpdcadAntIdTransType_, Fit.SubfieldIndexMainField);
  434. }
  435. ///<summary>
  436. /// Retrieves the BikePowerAntIdTransType field</summary>
  437. /// <returns>Returns nullable byte representing the BikePowerAntIdTransType field</returns>
  438. public byte? GetBikePowerAntIdTransType()
  439. {
  440. return (byte?)GetFieldValue(24, 0, Fit.SubfieldIndexMainField);
  441. }
  442. /// <summary>
  443. /// Set BikePowerAntIdTransType field</summary>
  444. /// <param name="bikePowerAntIdTransType_">Nullable field value to be set</param>
  445. public void SetBikePowerAntIdTransType(byte? bikePowerAntIdTransType_)
  446. {
  447. SetFieldValue(24, 0, bikePowerAntIdTransType_, Fit.SubfieldIndexMainField);
  448. }
  449. ///<summary>
  450. /// Retrieves the OdometerRollover field
  451. /// Comment: Rollover counter that can be used to extend the odometer</summary>
  452. /// <returns>Returns nullable byte representing the OdometerRollover field</returns>
  453. public byte? GetOdometerRollover()
  454. {
  455. return (byte?)GetFieldValue(37, 0, Fit.SubfieldIndexMainField);
  456. }
  457. /// <summary>
  458. /// Set OdometerRollover field
  459. /// Comment: Rollover counter that can be used to extend the odometer</summary>
  460. /// <param name="odometerRollover_">Nullable field value to be set</param>
  461. public void SetOdometerRollover(byte? odometerRollover_)
  462. {
  463. SetFieldValue(37, 0, odometerRollover_, Fit.SubfieldIndexMainField);
  464. }
  465. ///<summary>
  466. /// Retrieves the FrontGearNum field
  467. /// Comment: Number of front gears</summary>
  468. /// <returns>Returns nullable byte representing the FrontGearNum field</returns>
  469. public byte? GetFrontGearNum()
  470. {
  471. return (byte?)GetFieldValue(38, 0, Fit.SubfieldIndexMainField);
  472. }
  473. /// <summary>
  474. /// Set FrontGearNum field
  475. /// Comment: Number of front gears</summary>
  476. /// <param name="frontGearNum_">Nullable field value to be set</param>
  477. public void SetFrontGearNum(byte? frontGearNum_)
  478. {
  479. SetFieldValue(38, 0, frontGearNum_, Fit.SubfieldIndexMainField);
  480. }
  481. /// <summary>
  482. ///
  483. /// </summary>
  484. /// <returns>returns number of elements in field FrontGear</returns>
  485. public int GetNumFrontGear()
  486. {
  487. return GetNumFieldValues(39, Fit.SubfieldIndexMainField);
  488. }
  489. ///<summary>
  490. /// Retrieves the FrontGear field
  491. /// Comment: Number of teeth on each gear 0 is innermost</summary>
  492. /// <param name="index">0 based index of FrontGear element to retrieve</param>
  493. /// <returns>Returns nullable byte representing the FrontGear field</returns>
  494. public byte? GetFrontGear(int index)
  495. {
  496. return (byte?)GetFieldValue(39, index, Fit.SubfieldIndexMainField);
  497. }
  498. /// <summary>
  499. /// Set FrontGear field
  500. /// Comment: Number of teeth on each gear 0 is innermost</summary>
  501. /// <param name="index">0 based index of front_gear</param>
  502. /// <param name="frontGear_">Nullable field value to be set</param>
  503. public void SetFrontGear(int index, byte? frontGear_)
  504. {
  505. SetFieldValue(39, index, frontGear_, Fit.SubfieldIndexMainField);
  506. }
  507. ///<summary>
  508. /// Retrieves the RearGearNum field
  509. /// Comment: Number of rear gears</summary>
  510. /// <returns>Returns nullable byte representing the RearGearNum field</returns>
  511. public byte? GetRearGearNum()
  512. {
  513. return (byte?)GetFieldValue(40, 0, Fit.SubfieldIndexMainField);
  514. }
  515. /// <summary>
  516. /// Set RearGearNum field
  517. /// Comment: Number of rear gears</summary>
  518. /// <param name="rearGearNum_">Nullable field value to be set</param>
  519. public void SetRearGearNum(byte? rearGearNum_)
  520. {
  521. SetFieldValue(40, 0, rearGearNum_, Fit.SubfieldIndexMainField);
  522. }
  523. /// <summary>
  524. ///
  525. /// </summary>
  526. /// <returns>returns number of elements in field RearGear</returns>
  527. public int GetNumRearGear()
  528. {
  529. return GetNumFieldValues(41, Fit.SubfieldIndexMainField);
  530. }
  531. ///<summary>
  532. /// Retrieves the RearGear field
  533. /// Comment: Number of teeth on each gear 0 is innermost</summary>
  534. /// <param name="index">0 based index of RearGear element to retrieve</param>
  535. /// <returns>Returns nullable byte representing the RearGear field</returns>
  536. public byte? GetRearGear(int index)
  537. {
  538. return (byte?)GetFieldValue(41, index, Fit.SubfieldIndexMainField);
  539. }
  540. /// <summary>
  541. /// Set RearGear field
  542. /// Comment: Number of teeth on each gear 0 is innermost</summary>
  543. /// <param name="index">0 based index of rear_gear</param>
  544. /// <param name="rearGear_">Nullable field value to be set</param>
  545. public void SetRearGear(int index, byte? rearGear_)
  546. {
  547. SetFieldValue(41, index, rearGear_, Fit.SubfieldIndexMainField);
  548. }
  549. ///<summary>
  550. /// Retrieves the ShimanoDi2Enabled field</summary>
  551. /// <returns>Returns nullable Bool enum representing the ShimanoDi2Enabled field</returns>
  552. public Bool? GetShimanoDi2Enabled()
  553. {
  554. object obj = GetFieldValue(44, 0, Fit.SubfieldIndexMainField);
  555. Bool? value = obj == null ? (Bool?)null : (Bool)obj;
  556. return value;
  557. }
  558. /// <summary>
  559. /// Set ShimanoDi2Enabled field</summary>
  560. /// <param name="shimanoDi2Enabled_">Nullable field value to be set</param>
  561. public void SetShimanoDi2Enabled(Bool? shimanoDi2Enabled_)
  562. {
  563. SetFieldValue(44, 0, shimanoDi2Enabled_, Fit.SubfieldIndexMainField);
  564. }
  565. #endregion // Methods
  566. } // Class
  567. } // namespace