text:
require 'spec_helper'

describe "A PusherClient::Channels collection" do
  before do
    @channels = PusherClient::Channels.new
  end

  it "should initialize empty" do
    expect(@channels).to be_empty
    expect(@channels.size).to eq(0)
  end

  it "should instantiate new channels added to it by name" do
    @channels << 'TestChannel'
    expect(@channels.find('TestChannel').class).to eq(PusherClient::Channel)
  end

  it "should allow removal of channels by name" do
    @channels << 'TestChannel'
    expect(@channels['TestChannel'].class).to eq(PusherClient::Channel)
    @channels.remove('TestChannel')
    expect(@channels).to be_empty
  end

  it "should not allow two channels of the same name" do
    @channels << 'TestChannel'
    @channels << 'TestChannel'
    expect(@channels.size).to eq(1)
  end

end

describe "A PusherClient::Channel" do
  before do
    @channels = PusherClient::Channels.new
    @channel = @channels << "TestChannel"
  end

  it 'should not be subscribed by default' do
    expect(@channel.subscribed).to be_false
  end

  it 'should not be global by default' do
    expect(@channel.global).to be_false
  end

  it 'can have procs bound to an event' do
    @channel.bind('TestEvent') {}
    expect(@channel.callbacks.size).to eq(1)
  end

  it 'should run callbacks when an event is dispatched' do

    @channel.bind('TestEvent') do
      PusherClient.logger.test "Local callback running"
    end

    @channel.dispatch('TestEvent', {})
    expect(PusherClient.logger.test_messages).to include("Local callback running")
  end

end

describe "A PusherClient::Socket" do
  before do
    @socket = PusherClient::Socket.new(TEST_APP_KEY, :secret => 'secret')
  end

  it 'should not connect when instantiated' do
    expect(@socket.connected).to be_false
  end

  it 'should raise ArgumentError if TEST_APP_KEY is an empty string' do
    expect {
      @broken_socket = PusherClient::Socket.new('')
    }.to raise_error(ArgumentError)
    expect {
      @broken_socket = PusherClient::Socket.new(nil)
    }.to raise_error(ArgumentError)
  end

  describe "...when connected" do
    before do
      @socket.connect
    end

    it 'should know its connected' do
      expect(@socket.connected).to be_true
    end

    it 'should know its socket_id' do
      expect(@socket.socket_id).to eq('123abc')
    end

    it 'should not be subscribed to its global channel' do
      expect(@socket.global_channel.subscribed).to be_false
    end

    it 'should subscribe to a channel' do
      @channel = @socket.subscribe('testchannel')
      expect(@socket.channels['testchannel']).to eq(@channel)
      expect(@channel.subscribed).to be_true
    end

    it 'should unsubscribe from a channel' do
      @socket.subscribe('testchannel')
      @socket.unsubscribe('testchannel')
      expect(PusherClient.logger.test_messages.last).to include('pusher:unsubscribe')
      expect(@socket.channels['testchannel']).to be_nil
    end

    it 'should subscribe to a private channel' do
      @channel = @socket.subscribe('private-testchannel')
      expect(@socket.channels['private-testchannel']).to eq(@channel)
      expect(@channel.subscribed).to be_true
    end

    it 'should subscribe to a presence channel with user_id' do
      @channel = @socket.subscribe('presence-testchannel', '123')
      expect(@socket.channels['presence-testchannel']).to eq(@channel)
      expect(@channel.user_data).to eq('{"user_id":"123"}')
      expect(@channel.subscribed).to be_true
    end

    it 'should subscribe to a presence channel with custom channel_data' do
      @channel = @socket.subscribe('presence-testchannel', :user_id => '123', :user_name => 'john')
      expect(@socket.channels['presence-testchannel']).to eq(@channel)
      expect(@channel.user_data).to eq('{"user_id":"123","user_name":"john"}')
      expect(@channel.subscribed).to be_true
    end

    it 'should allow binding of global events' do
      @socket.bind('testevent') { |data| PusherClient.logger.test("testchannel received #{data}") }
      expect(@socket.global_channel.callbacks.has_key?('testevent')).to be_true
    end

    it 'should trigger callbacks for global events' do
      @socket.bind('globalevent') { |data| PusherClient.logger.test("Global event!") }
      expect(@socket.global_channel.callbacks.has_key?('globalevent')).to be_true

      @socket.simulate_received('globalevent', 'some data', '')
      expect(PusherClient.logger.test_messages.last).to include('Global event!')
    end

    it 'should kill the connection thread when disconnect is called' do
      @socket.disconnect
      expect(Thread.list.size).to eq(1)
    end

    it 'should not be connected after disconnecting' do
      @socket.disconnect
      expect(@socket.connected).to be_false
    end

    describe "when subscribed to a channel" do
      before do
        @channel = @socket.subscribe('testchannel')
      end

      it 'should allow binding of callbacks for the subscribed channel' do
        @socket['testchannel'].bind('testevent') { |data| PusherClient.logger.test(data) }
        expect(@socket['testchannel'].callbacks.has_key?('testevent')).to be_true
      end

      it "should trigger channel callbacks when a message is received" do
        # Bind 2 events for the channel
        @socket['testchannel'].bind('coming') { |data| PusherClient.logger.test(data) }
        @socket['testchannel'].bind('going')  { |data| PusherClient.logger.test(data) }

        # Simulate the first event
        @socket.simulate_received('coming', 'Hello!', 'testchannel')
        expect(PusherClient.logger.test_messages.last).to include('Hello!')

        # Simulate the second event
        @socket.simulate_received('going', 'Goodbye!', 'testchannel')
        expect(PusherClient.logger.test_messages.last).to include('Goodbye!')
      end

    end
  end
end


text:
require "rails_helper"

RSpec.describe VisitOrderType do
  let(:attributes) do
    {
      'type' => { 'code' => 'some code', 'desc' => 'some description' },
      'number' => '1234567890'
    }
  end

  let(:visit_order) { subject.cast(attributes) }

  it { expect(visit_order).to be_instance_of(Nomis::VisitOrder).and be_frozen }
  it { expect(visit_order).to have_attributes(number: 1_234_567_890, code: 'some code', desc: 'some description') }
end

redpajama_set_name: RedPajamaGithub


text:
import getCoordinateKeys from './getCoordinateKeys';

describe('getCoordinateKeys', () => {
    it('gets lat/lng[/alt]', () => {
        expect(getCoordinateKeys({ lat: 1, lng: 1 })).toEqual({
            longitude: 'lng',
            latitude: 'lat',
        });
        expect(getCoordinateKeys({ lat: 1, lng: 1, alt: 1 })).toEqual({
            longitude: 'lng',
            latitude: 'lat',
            altitude: 'alt',
        });
    });

    it('gets lat/lon[/alt]', () => {
        expect(getCoordinateKeys({ lat: 1, lon: 1 })).toEqual({
            longitude: 'lon',
            latitude: 'lat',
        });
        expect(getCoordinateKeys({ lat: 1, lon: 1, alt: 1 })).toEqual({
            longitude: 'lon',
            latitude: 'lat',
            altitude: 'alt',
        });
    });

    it('gets latitude/longitude[/altitude]', () => {
        expect(getCoordinateKeys({ latitude: 1, longitude: 1 })).toEqual({
            longitude: 'longitude',
            latitude: 'latitude',
        });
        expect(
            getCoordinateKeys({ latitude: 1, longitude: 1, altitude: 1 })
        ).toEqual({
            longitude: 'longitude',
            latitude: 'latitude',
            altitude: 'altitude',
        });
    });

    it('gets GeoJSON array', () => {
        expect(getCoordinateKeys([1, 2])).toEqual({
            longitude: 0,
            latitude: 1,
        });
        expect(getCoordinateKeys([1, 2, 3])).toEqual({
            longitude: 0,
            latitude: 1,
            altitude: 2,
        });
    });
});


text:
.. _exhale_function_namespacelibecpint_1_1qgen_1a23265e6ef8db8355d123e8ef88049d01:

Function libecpint::qgen::Q1_2_1
================================

- Defined in :ref:`file__Users_robertshaw_devfiles_libecpint_include_libecpint_qgen.hpp`

Function Documentation
----------------------

.. doxygenfunction:: libecpint::qgen::Q1_2_1(const ECP&, const GaussianShell&, const GaussianShell&, const FiveIndex<double>&, const FiveIndex<double>&, const TwoIndex<double>&, const TwoIndex<double>&, double, double, const RadialIntegral&, const AngularIntegral&, const RadialIntegral::Parameters&, ThreeIndex<double>&)


text:
// This file was generated by NxParameterized/scripts/GenModuleHelpers.pl
// Created: 2015.10.22 17:26:35

#include "ConvexHullParameters.h"
#include "DebugColorParams.h"
#include "DebugRenderParams.h"


text:
module RAutomation
  module Adapter
    module Win32
      class Window
        include WaitHelper
        include Locators
        extend ElementCollections

        has_many :controls

        class << self
          def oleacc_module_handle
            @oleacc_module_handle ||= begin
              oleacc = Functions.load_library "oleacc.dll"
              Functions.co_initialize nil
              oleacc
            end
          end
        end

        attr_reader :container

        # Locators of the window.
        attr_reader :locators

        # Possible locators are :title, :text, :hwnd, :pid, :class and :index.

        # Creates the window object.
        # @note this method is not meant to be accessed directly, but only through {RAutomation::Window#initialize}!
        # @param [Hash] locators for searching the window.
        # @option locators [String, Regexp] :title Title of the window
        # @option locators [String, Regexp] :text Visible text of the window
        # @option locators [String, Regexp] :class Internal class name of the window
        # @option locators [String, Fixnum] :hwnd Window handle in decimal format
        # @option locators [String, Fixnum] :pid Window process ID (PID)
        # @option locators [String, Fixnum] :index 0-based index to specify n-th window if all other criteria match
        #   all other criteria match
        # @see RAutomation::Window#initialize
        def initialize(container, locators)
          @container = container
          extract(locators)
        end

        # Retrieves handle of the window.
        # @note Searches only for visible windows.
        # @see RAutomation::Window#hwnd
        def hwnd
          @hwnd ||= Functions.window_hwnd(@locators)
        end

        # @see RAutomation::Window#pid
        def pid
          Functions.window_pid(hwnd)
        end

        # @see RAutomation::Window#title
        def title
          Functions.window_title(hwnd)
        end

        # @see RAutomation::Window#class_names
        def class_names
          classes = []
          controls.each do |control|
            classes << control.class_name
          end
          classes.sort
        end

        # @see RAutomation::Window#activate
        def activate
          return if !exists? || active?
          restore if minimized?
          Functions.activate_window(hwnd)
          sleep 0.1
        end

        # @see RAutomation::Window#active?
        def active?
          exists? && Functions.foreground_window == hwnd
        end

        # @see RAutomation::Window#text
        def text
          Functions.window_text(hwnd)
        end

        # @see RAutomation::Window#exists?
        def exists?
          result = hwnd && Functions.window_exists(hwnd)
          !!result
        end

        # @see RAutomation::Window#visible?
        def visible?
          Functions.window_visible(hwnd)
        end

        # @see RAutomation::Window#maximize
        def maximize
          Functions.show_window(hwnd, Constants::SW_MAXIMIZE)
          sleep 1
        end

        # @see RAutomation::Window#minimize
        def minimize
          Functions.show_window(hwnd, Constants::SW_MINIMIZE)
          sleep 1
        end

        # @see RAutomation::Window#minimized?
        def minimized?
          Functions.minimized(hwnd)
        end

        # @see RAutomation::Window#restore
        def restore
          Functions.show_window(hwnd, Constants::SW_RESTORE)
          sleep 1
        end

        # Moves/resizes the window.
        # @note All coordinates are optional and if not specified current coordinates will be used
        # @param [Hash] coords for specifying the coordinates.
        # @option coords [Fixnum] :left Window coordinate from the left side of screen
        # @option coords [Fixnum] :top Window coordinate from the top of the screen
        # @option coords [Fixnum] :width Width of window
        # @option coords [Fixnum] :height Height of window
        def move(coords={})
          @container.wait_until_present
          rect = dimensions.merge(coords)
          Functions.move_window(hwnd, rect[:left], rect[:top], rect[:width], rect[:height])
          sleep 1
        end

        # @return [Hash] Hash[:left, :top, :width, :height] with window coordinates
        def dimensions
          @container.wait_until_present
          left, top, right, bottom = Functions.window_rect(hwnd)
          {:left => left, :top => top, :width => right - left, :height => bottom - top}
        end

        # Activates the window and sends keys to it.
        #
        # @example
        #   RAutomation::Window.new(:title => //).send_keys "hello!"
        #   RAutomation::Window.new(:title => //).send_keys [:control, "a"], "world!"
        # Refer to {Keys::KEYS} for all the special keycodes.
        # @see RAutomation::Window#send_keys
        def send_keys(args)
          Keys.encode(args).each do |arg|
            wait_until do
              activate
              active?
            end

            if arg.is_a?(Array)
              arg.reduce([]) do |pressed_keys, k|
                if k == Keys[:null]
                  pressed_keys.each {|pressed_key| release_key pressed_key}
                  pressed_keys = []
                else
                  pressed_keys << press_key(k)
                end
                pressed_keys
              end
            else
              send_key arg
            end
          end
          sleep 1
        end

        # @see RAutomation::Window#close
        def close
          Functions.close_window(hwnd)
        end

        # Retrieves the {Mouse} object for automating mouse movements and clicks
        # @raise [UnknownWindowException] if the window doesn't exist.
        def mouse
          @container.wait_until_present
          Mouse.new(self)
        end

        # @see Button#initialize
        # @see RAutomation::Window#button
        def button(locator)
          Button.new(self, locator)
        end

        # @see TextField#initialize
        # @see RAutomation::Window#text_field
        def text_field(locator)
          TextField.new(self, locator)
        end

        # Redirects all method calls not part of the public API to the {Functions} directly.
        # @see RAutomation::Window#method_missing
        def method_missing(name, *args)
          Functions.respond_to?(name) ? Functions.send(name, *args) : super
        end

        # Win32 adapter specific API methods
        def label(locator={})
          @container.wait_until_present
          Label.new(self, locator)
        end

        def password_field(locator)
          @container.wait_until_present
          PasswordField.new(self, locator)
        end

        def control(locator={})
          @container.wait_until_present
          Control.new(self, locator)
        end

        def list_box(locator={})
          @container.wait_until_present
          ListBox.new(self, locator)
        end

        def select_list(locator={})
          @container.wait_until_present
          SelectList.new(self, locator)
        end

        def checkbox(locator={})
          @container.wait_until_present
          Checkbox.new(self, locator)
        end

        def radio(locator={})
          @container.wait_until_present
          Radio.new(self, locator)
        end

        def table(locator={})
          @container.wait_until_present
          Table.new(self, locator)
        end

        # Creates the child window object.
        # @note This is an Win32 adapter specific method, not part of the public API
        # @example
        #   RAutomation::Window.new(:title => /Windows Internet Explorer/i).
        #     child(:title => /some popup/)
        # @param (see Window#initialize)
        # @return [RAutomation::Window] child window, popup or regular window.
        def child(locators)
          RAutomation::Window.new Functions.child_window_locators(hwnd, locators)
        end

        private

        def press_key key
          Functions.send_key(key, 0, 0, nil)
          key
        end

        def release_key key
          Functions.send_key(key, 0, Constants::KEYEVENTF_KEYUP, nil)
          key
        end

        def send_key key
          press_key key
          release_key key
          key
        end
      end
    end
  end
end


text:
namespace FitFilePreviewer.Decode.Fit.Mesgs
{
   ///
   /// Implements the Session profile message.
   ///
   public class SessionMesg : Mesg
   {
      #region Fields
      static class TotalCyclesSubfield
      {
         public static ushort TotalStrides = 0;
         public static ushort Subfields = 1;
         public static ushort Active = Fit.SubfieldIndexActiveSubfield;
         public static ushort MainField = Fit.SubfieldIndexMainField;
      }
      static class AvgCadenceSubfield
      {
         public static ushort AvgRunningCadence = 0;
         public static ushort Subfields = 1;
         public static ushort Active = Fit.SubfieldIndexActiveSubfield;
         public static ushort MainField = Fit.SubfieldIndexMainField;
      }
      static class MaxCadenceSubfield
      {
         public static ushort MaxRunningCadence = 0;
         public static ushort Subfields = 1;
         public static ushort Active = Fit.SubfieldIndexActiveSubfield;
         public static ushort MainField = Fit.SubfieldIndexMainField;
      }
      #endregion

      #region Constructors
      public SessionMesg() : base((Mesg) Profile.mesgs[Profile.SessionIndex])
      {
      }

      public SessionMesg(Mesg mesg) : base(mesg)
      {
      }
      #endregion // Constructors

      #region Methods
      ///
      /// Retrieves the MessageIndex field
      /// Comment: Selected bit is set for the current session.
      /// <returns>Returns nullable ushort representing the MessageIndex field</returns>
      public ushort? GetMessageIndex()
      {
         return (ushort?)GetFieldValue(254, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MessageIndex field
      /// Comment: Selected bit is set for the current session.
      /// <param name="messageIndex_">Nullable field value to be set</param>
      public void SetMessageIndex(ushort? messageIndex_)
      {
         SetFieldValue(254, 0, messageIndex_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the Timestamp field
      /// Units: s
      /// Comment: Sesson end time.
      /// <returns>Returns DateTime representing the Timestamp field</returns>
      public Types.DateTime GetTimestamp()
      {
         return TimestampToDateTime((uint?)GetFieldValue(253, 0, Fit.SubfieldIndexMainField));
      }

      ///
      /// Set Timestamp field
      /// Units: s
      /// Comment: Sesson end time.
      /// <param name="timestamp_">Nullable field value to be set</param>
      public void SetTimestamp(Types.DateTime timestamp_)
      {
         SetFieldValue(253, 0, timestamp_.GetTimeStamp(), Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the Event field
      /// Comment: session
      /// <returns>Returns nullable Event enum representing the Event field</returns>
      public Types.Event? GetEvent()
      {
         object obj = GetFieldValue(0, 0, Fit.SubfieldIndexMainField);
         Types.Event? value = obj == null ? (Types.Event?)null : (Types.Event)obj;
         return value;
      }

      ///
      /// Set Event field
      /// Comment: session
      /// <param name="event_">Nullable field value to be set</param>
      public void SetEvent(Types.Event? event_)
      {
         SetFieldValue(0, 0, event_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the EventType field
      /// Comment: stop
      /// <returns>Returns nullable EventType enum representing the EventType field</returns>
      public Types.EventType? GetEventType()
      {
         object obj = GetFieldValue(1, 0, Fit.SubfieldIndexMainField);
         Types.EventType? value = obj == null ? (Types.EventType?)null : (Types.EventType)obj;
         return value;
      }

      ///
      /// Set EventType field
      /// Comment: stop
      /// <param name="eventType_">Nullable field value to be set</param>
      public void SetEventType(Types.EventType? eventType_)
      {
         SetFieldValue(1, 0, eventType_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the StartTime field
      /// <returns>Returns DateTime representing the StartTime field</returns>
      public Types.DateTime GetStartTime()
      {
         return TimestampToDateTime((uint?)GetFieldValue(2, 0, Fit.SubfieldIndexMainField));
      }

      ///
      /// Set StartTime field
      /// <param name="startTime_">Nullable field value to be set</param>
      public void SetStartTime(Types.DateTime startTime_)
      {
         SetFieldValue(2, 0, startTime_.GetTimeStamp(), Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the StartPositionLat field
      /// Units: semicircles
      /// <returns>Returns nullable int representing the StartPositionLat field</returns>
      public int? GetStartPositionLat()
      {
         return (int?)GetFieldValue(3, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set StartPositionLat field
      /// Units: semicircles
      /// <param name="startPositionLat_">Nullable field value to be set</param>
      public void SetStartPositionLat(int? startPositionLat_)
      {
         SetFieldValue(3, 0, startPositionLat_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the StartPositionLong field
      /// Units: semicircles
      /// <returns>Returns nullable int representing the StartPositionLong field</returns>
      public int? GetStartPositionLong()
      {
         return (int?)GetFieldValue(4, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set StartPositionLong field
      /// Units: semicircles
      /// <param name="startPositionLong_">Nullable field value to be set</param>
      public void SetStartPositionLong(int? startPositionLong_)
      {
         SetFieldValue(4, 0, startPositionLong_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the Sport field
      /// <returns>Returns nullable Sport enum representing the Sport field</returns>
      public Types.Sport? GetSport()
      {
         object obj = GetFieldValue(5, 0, Fit.SubfieldIndexMainField);
         Types.Sport? value = obj == null ? (Types.Sport?)null : (Types.Sport)obj;
         return value;
      }

      ///
      /// Set Sport field
      /// <param name="sport_">Nullable field value to be set</param>
      public void SetSport(Types.Sport? sport_)
      {
         SetFieldValue(5, 0, sport_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the SubSport field
      /// <returns>Returns nullable SubSport enum representing the SubSport field</returns>
      public Types.SubSport? GetSubSport()
      {
         object obj = GetFieldValue(6, 0, Fit.SubfieldIndexMainField);
         Types.SubSport? value = obj == null ? (Types.SubSport?)null : (Types.SubSport)obj;
         return value;
      }

      ///
      /// Set SubSport field
      /// <param name="subSport_">Nullable field value to be set</param>
      public void SetSubSport(Types.SubSport? subSport_)
      {
         SetFieldValue(6, 0, subSport_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalElapsedTime field
      /// Units: s
      /// Comment: Time (includes pauses)
      /// <returns>Returns nullable float representing the TotalElapsedTime field</returns>
      public float? GetTotalElapsedTime()
      {
         return (float?)GetFieldValue(7, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalElapsedTime field
      /// Units: s
      /// Comment: Time (includes pauses)
      /// <param name="totalElapsedTime_">Nullable field value to be set</param>
      public void SetTotalElapsedTime(float? totalElapsedTime_)
      {
         SetFieldValue(7, 0, totalElapsedTime_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalTimerTime field
      /// Units: s
      /// Comment: Timer Time (excludes pauses)
      /// <returns>Returns nullable float representing the TotalTimerTime field</returns>
      public float? GetTotalTimerTime()
      {
         return (float?)GetFieldValue(8, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalTimerTime field
      /// Units: s
      /// Comment: Timer Time (excludes pauses)
      /// <param name="totalTimerTime_">Nullable field value to be set</param>
      public void SetTotalTimerTime(float? totalTimerTime_)
      {
         SetFieldValue(8, 0, totalTimerTime_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalDistance field
      /// Units: m
      /// <returns>Returns nullable float representing the TotalDistance field</returns>
      public float? GetTotalDistance()
      {
         return (float?)GetFieldValue(9, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalDistance field
      /// Units: m
      /// <param name="totalDistance_">Nullable field value to be set</param>
      public void SetTotalDistance(float? totalDistance_)
      {
         SetFieldValue(9, 0, totalDistance_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalCycles field
      /// Units: cycles
      /// <returns>Returns nullable uint representing the TotalCycles field</returns>
      public uint? GetTotalCycles()
      {
         return (uint?)GetFieldValue(10, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalCycles field
      /// Units: cycles
      /// <param name="totalCycles_">Nullable field value to be set</param>
      public void SetTotalCycles(uint? totalCycles_)
      {
         SetFieldValue(10, 0, totalCycles_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalStrides subfield
      /// Units: strides
      /// <returns>Nullable uint representing the TotalStrides subfield</returns>
      public uint? GetTotalStrides()
      {
         return (uint?)GetFieldValue(10, 0, TotalCyclesSubfield.TotalStrides);
      }

      ///
      ///
      /// Set TotalStrides subfield
      /// Units: strides
      /// <param name="totalStrides">Subfield value to be set</param>
      public void SetTotalStrides(uint? totalStrides)
      {
         SetFieldValue(10, 0, totalStrides, TotalCyclesSubfield.TotalStrides);
      }
      ///
      /// Retrieves the TotalCalories field
      /// Units: kcal
      /// <returns>Returns nullable ushort representing the TotalCalories field</returns>
      public ushort? GetTotalCalories()
      {
         return (ushort?)GetFieldValue(11, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalCalories field
      /// Units: kcal
      /// <param name="totalCalories_">Nullable field value to be set</param>
      public void SetTotalCalories(ushort? totalCalories_)
      {
         SetFieldValue(11, 0, totalCalories_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalFatCalories field
      /// Units: kcal
      /// <returns>Returns nullable ushort representing the TotalFatCalories field</returns>
      public ushort? GetTotalFatCalories()
      {
         return (ushort?)GetFieldValue(13, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalFatCalories field
      /// Units: kcal
      /// <param name="totalFatCalories_">Nullable field value to be set</param>
      public void SetTotalFatCalories(ushort? totalFatCalories_)
      {
         SetFieldValue(13, 0, totalFatCalories_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgSpeed field
      /// Units: m/s
      /// Comment: total_distance / total_timer_time
      /// <returns>Returns nullable float representing the AvgSpeed field</returns>
      public float? GetAvgSpeed()
      {
         return (float?)GetFieldValue(14, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgSpeed field
      /// Units: m/s
      /// Comment: total_distance / total_timer_time
      /// <param name="avgSpeed_">Nullable field value to be set</param>
      public void SetAvgSpeed(float? avgSpeed_)
      {
         SetFieldValue(14, 0, avgSpeed_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxSpeed field
      /// Units: m/s
      /// <returns>Returns nullable float representing the MaxSpeed field</returns>
      public float? GetMaxSpeed()
      {
         return (float?)GetFieldValue(15, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxSpeed field
      /// Units: m/s
      /// <param name="maxSpeed_">Nullable field value to be set</param>
      public void SetMaxSpeed(float? maxSpeed_)
      {
         SetFieldValue(15, 0, maxSpeed_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgHeartRate field
      /// Units: bpm
      /// Comment: average heart rate (excludes pause time)
      /// <returns>Returns nullable byte representing the AvgHeartRate field</returns>
      public byte? GetAvgHeartRate()
      {
         return (byte?)GetFieldValue(16, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgHeartRate field
      /// Units: bpm
      /// Comment: average heart rate (excludes pause time)
      /// <param name="avgHeartRate_">Nullable field value to be set</param>
      public void SetAvgHeartRate(byte? avgHeartRate_)
      {
         SetFieldValue(16, 0, avgHeartRate_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxHeartRate field
      /// Units: bpm
      /// <returns>Returns nullable byte representing the MaxHeartRate field</returns>
      public byte? GetMaxHeartRate()
      {
         return (byte?)GetFieldValue(17, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxHeartRate field
      /// Units: bpm
      /// <param name="maxHeartRate_">Nullable field value to be set</param>
      public void SetMaxHeartRate(byte? maxHeartRate_)
      {
         SetFieldValue(17, 0, maxHeartRate_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgCadence field
      /// Units: rpm
      /// Comment: total_cycles / total_timer_time if non_zero_avg_cadence otherwise total_cycles / total_elapsed_time
      /// <returns>Returns nullable byte representing the AvgCadence field</returns>
      public byte? GetAvgCadence()
      {
         return (byte?)GetFieldValue(18, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgCadence field
      /// Units: rpm
      /// Comment: total_cycles / total_timer_time if non_zero_avg_cadence otherwise total_cycles / total_elapsed_time
      /// <param name="avgCadence_">Nullable field value to be set</param>
      public void SetAvgCadence(byte? avgCadence_)
      {
         SetFieldValue(18, 0, avgCadence_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgRunningCadence subfield
      /// Units: strides/min
      /// <returns>Nullable byte representing the AvgRunningCadence subfield</returns>
      public byte? GetAvgRunningCadence()
      {
         return (byte?)GetFieldValue(18, 0, AvgCadenceSubfield.AvgRunningCadence);
      }

      ///
      ///
      /// Set AvgRunningCadence subfield
      /// Units: strides/min
      /// <param name="avgRunningCadence">Subfield value to be set</param>
      public void SetAvgRunningCadence(byte? avgRunningCadence)
      {
         SetFieldValue(18, 0, avgRunningCadence, AvgCadenceSubfield.AvgRunningCadence);
      }
      ///
      /// Retrieves the MaxCadence field
      /// Units: rpm
      /// <returns>Returns nullable byte representing the MaxCadence field</returns>
      public byte? GetMaxCadence()
      {
         return (byte?)GetFieldValue(19, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxCadence field
      /// Units: rpm
      /// <param name="maxCadence_">Nullable field value to be set</param>
      public void SetMaxCadence(byte? maxCadence_)
      {
         SetFieldValue(19, 0, maxCadence_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxRunningCadence subfield
      /// Units: strides/min
      /// <returns>Nullable byte representing the MaxRunningCadence subfield</returns>
      public byte? GetMaxRunningCadence()
      {
         return (byte?)GetFieldValue(19, 0, MaxCadenceSubfield.MaxRunningCadence);
      }

      ///
      ///
      /// Set MaxRunningCadence subfield
      /// Units: strides/min
      /// <param name="maxRunningCadence">Subfield value to be set</param>
      public void SetMaxRunningCadence(byte? maxRunningCadence)
      {
         SetFieldValue(19, 0, maxRunningCadence, MaxCadenceSubfield.MaxRunningCadence);
      }
      ///
      /// Retrieves the AvgPower field
      /// Units: watts
      /// Comment: total_power / total_timer_time if non_zero_avg_power otherwise total_power / total_elapsed_time
      /// <returns>Returns nullable ushort representing the AvgPower field</returns>
      public ushort? GetAvgPower()
      {
         return (ushort?)GetFieldValue(20, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgPower field
      /// Units: watts
      /// Comment: total_power / total_timer_time if non_zero_avg_power otherwise total_power / total_elapsed_time
      /// <param name="avgPower_">Nullable field value to be set</param>
      public void SetAvgPower(ushort? avgPower_)
      {
         SetFieldValue(20, 0, avgPower_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxPower field
      /// Units: watts
      /// <returns>Returns nullable ushort representing the MaxPower field</returns>
      public ushort? GetMaxPower()
      {
         return (ushort?)GetFieldValue(21, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxPower field
      /// Units: watts
      /// <param name="maxPower_">Nullable field value to be set</param>
      public void SetMaxPower(ushort? maxPower_)
      {
         SetFieldValue(21, 0, maxPower_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalAscent field
      /// Units: m
      /// <returns>Returns nullable ushort representing the TotalAscent field</returns>
      public ushort? GetTotalAscent()
      {
         return (ushort?)GetFieldValue(22, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalAscent field
      /// Units: m
      /// <param name="totalAscent_">Nullable field value to be set</param>
      public void SetTotalAscent(ushort? totalAscent_)
      {
         SetFieldValue(22, 0, totalAscent_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalDescent field
      /// Units: m
      /// <returns>Returns nullable ushort representing the TotalDescent field</returns>
      public ushort? GetTotalDescent()
      {
         return (ushort?)GetFieldValue(23, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalDescent field
      /// Units: m
      /// <param name="totalDescent_">Nullable field value to be set</param>
      public void SetTotalDescent(ushort? totalDescent_)
      {
         SetFieldValue(23, 0, totalDescent_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalTrainingEffect field
      /// <returns>Returns nullable float representing the TotalTrainingEffect field</returns>
      public float? GetTotalTrainingEffect()
      {
         return (float?)GetFieldValue(24, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalTrainingEffect field
      /// <param name="totalTrainingEffect_">Nullable field value to be set</param>
      public void SetTotalTrainingEffect(float? totalTrainingEffect_)
      {
         SetFieldValue(24, 0, totalTrainingEffect_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the FirstLapIndex field
      /// <returns>Returns nullable ushort representing the FirstLapIndex field</returns>
      public ushort? GetFirstLapIndex()
      {
         return (ushort?)GetFieldValue(25, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set FirstLapIndex field
      /// <param name="firstLapIndex_">Nullable field value to be set</param>
      public void SetFirstLapIndex(ushort? firstLapIndex_)
      {
         SetFieldValue(25, 0, firstLapIndex_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the NumLaps field
      /// <returns>Returns nullable ushort representing the NumLaps field</returns>
      public ushort? GetNumLaps()
      {
         return (ushort?)GetFieldValue(26, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set NumLaps field
      /// <param name="numLaps_">Nullable field value to be set</param>
      public void SetNumLaps(ushort? numLaps_)
      {
         SetFieldValue(26, 0, numLaps_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the EventGroup field
      /// <returns>Returns nullable byte representing the EventGroup field</returns>
      public byte? GetEventGroup()
      {
         return (byte?)GetFieldValue(27, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set EventGroup field
      /// <param name="eventGroup_">Nullable field value to be set</param>
      public void SetEventGroup(byte? eventGroup_)
      {
         SetFieldValue(27, 0, eventGroup_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the Trigger field
      /// <returns>Returns nullable SessionTrigger enum representing the Trigger field</returns>
      public Types.SessionTrigger? GetTrigger()
      {
         object obj = GetFieldValue(28, 0, Fit.SubfieldIndexMainField);
         Types.SessionTrigger? value = obj == null ? (Types.SessionTrigger?)null : (Types.SessionTrigger)obj;
         return value;
      }

      ///
      /// Set Trigger field
      /// <param name="trigger_">Nullable field value to be set</param>
      public void SetTrigger(Types.SessionTrigger? trigger_)
      {
         SetFieldValue(28, 0, trigger_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the NecLat field
      /// Units: semicircles
      /// <returns>Returns nullable int representing the NecLat field</returns>
      public int? GetNecLat()
      {
         return (int?)GetFieldValue(29, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set NecLat field
      /// Units: semicircles
      /// <param name="necLat_">Nullable field value to be set</param>
      public void SetNecLat(int? necLat_)
      {
         SetFieldValue(29, 0, necLat_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the NecLong field
      /// Units: semicircles
      /// <returns>Returns nullable int representing the NecLong field</returns>
      public int? GetNecLong()
      {
         return (int?)GetFieldValue(30, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set NecLong field
      /// Units: semicircles
      /// <param name="necLong_">Nullable field value to be set</param>
      public void SetNecLong(int? necLong_)
      {
         SetFieldValue(30, 0, necLong_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the SwcLat field
      /// Units: semicircles
      /// <returns>Returns nullable int representing the SwcLat field</returns>
      public int? GetSwcLat()
      {
         return (int?)GetFieldValue(31, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set SwcLat field
      /// Units: semicircles
      /// <param name="swcLat_">Nullable field value to be set</param>
      public void SetSwcLat(int? swcLat_)
      {
         SetFieldValue(31, 0, swcLat_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the SwcLong field
      /// Units: semicircles
      /// <returns>Returns nullable int representing the SwcLong field</returns>
      public int? GetSwcLong()
      {
         return (int?)GetFieldValue(32, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set SwcLong field
      /// Units: semicircles
      /// <param name="swcLong_">Nullable field value to be set</param>
      public void SetSwcLong(int? swcLong_)
      {
         SetFieldValue(32, 0, swcLong_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the NormalizedPower field
      /// Units: watts
      /// <returns>Returns nullable ushort representing the NormalizedPower field</returns>
      public ushort? GetNormalizedPower()
      {
         return (ushort?)GetFieldValue(34, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set NormalizedPower field
      /// Units: watts
      /// <param name="normalizedPower_">Nullable field value to be set</param>
      public void SetNormalizedPower(ushort? normalizedPower_)
      {
         SetFieldValue(34, 0, normalizedPower_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TrainingStressScore field
      /// Units: tss
      /// <returns>Returns nullable float representing the TrainingStressScore field</returns>
      public float? GetTrainingStressScore()
      {
         return (float?)GetFieldValue(35, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TrainingStressScore field
      /// Units: tss
      /// <param name="trainingStressScore_">Nullable field value to be set</param>
      public void SetTrainingStressScore(float? trainingStressScore_)
      {
         SetFieldValue(35, 0, trainingStressScore_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the IntensityFactor field
      /// Units: if
      /// <returns>Returns nullable float representing the IntensityFactor field</returns>
      public float? GetIntensityFactor()
      {
         return (float?)GetFieldValue(36, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set IntensityFactor field
      /// Units: if
      /// <param name="intensityFactor_">Nullable field value to be set</param>
      public void SetIntensityFactor(float? intensityFactor_)
      {
         SetFieldValue(36, 0, intensityFactor_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the LeftRightBalance field
      /// <returns>Returns nullable ushort representing the LeftRightBalance field</returns>
      public ushort? GetLeftRightBalance()
      {
         return (ushort?)GetFieldValue(37, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set LeftRightBalance field
      /// <param name="leftRightBalance_">Nullable field value to be set</param>
      public void SetLeftRightBalance(ushort? leftRightBalance_)
      {
         SetFieldValue(37, 0, leftRightBalance_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgStrokeCount field
      /// Units: strokes/lap
      /// <returns>Returns nullable float representing the AvgStrokeCount field</returns>
      public float? GetAvgStrokeCount()
      {
         return (float?)GetFieldValue(41, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgStrokeCount field
      /// Units: strokes/lap
      /// <param name="avgStrokeCount_">Nullable field value to be set</param>
      public void SetAvgStrokeCount(float? avgStrokeCount_)
      {
         SetFieldValue(41, 0, avgStrokeCount_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgStrokeDistance field
      /// Units: m
      /// <returns>Returns nullable float representing the AvgStrokeDistance field</returns>
      public float? GetAvgStrokeDistance()
      {
         return (float?)GetFieldValue(42, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgStrokeDistance field
      /// Units: m
      /// <param name="avgStrokeDistance_">Nullable field value to be set</param>
      public void SetAvgStrokeDistance(float? avgStrokeDistance_)
      {
         SetFieldValue(42, 0, avgStrokeDistance_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the SwimStroke field
      /// Units: swim_stroke
      /// <returns>Returns nullable SwimStroke enum representing the SwimStroke field</returns>
      public Types.SwimStroke? GetSwimStroke()
      {
         object obj = GetFieldValue(43, 0, Fit.SubfieldIndexMainField);
         Types.SwimStroke? value = obj == null ? (Types.SwimStroke?)null : (Types.SwimStroke)obj;
         return value;
      }

      ///
      /// Set SwimStroke field
      /// Units: swim_stroke
      /// <param name="swimStroke_">Nullable field value to be set</param>
      public void SetSwimStroke(Types.SwimStroke? swimStroke_)
      {
         SetFieldValue(43, 0, swimStroke_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the PoolLength field
      /// Units: m
      /// <returns>Returns nullable float representing the PoolLength field</returns>
      public float? GetPoolLength()
      {
         return (float?)GetFieldValue(44, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set PoolLength field
      /// Units: m
      /// <param name="poolLength_">Nullable field value to be set</param>
      public void SetPoolLength(float? poolLength_)
      {
         SetFieldValue(44, 0, poolLength_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the PoolLengthUnit field
      /// <returns>Returns nullable DisplayMeasure enum representing the PoolLengthUnit field</returns>
      public Types.DisplayMeasure? GetPoolLengthUnit()
      {
         object obj = GetFieldValue(46, 0, Fit.SubfieldIndexMainField);
         Types.DisplayMeasure? value = obj == null ? (Types.DisplayMeasure?)null : (Types.DisplayMeasure)obj;
         return value;
      }

      ///
      /// Set PoolLengthUnit field
      /// <param name="poolLengthUnit_">Nullable field value to be set</param>
      public void SetPoolLengthUnit(Types.DisplayMeasure? poolLengthUnit_)
      {
         SetFieldValue(46, 0, poolLengthUnit_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the NumActiveLengths field
      /// Units: lengths
      /// Comment: # of active lengths of swim pool
      /// <returns>Returns nullable ushort representing the NumActiveLengths field</returns>
      public ushort? GetNumActiveLengths()
      {
         return (ushort?)GetFieldValue(47, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set NumActiveLengths field
      /// Units: lengths
      /// Comment: # of active lengths of swim pool
      /// <param name="numActiveLengths_">Nullable field value to be set</param>
      public void SetNumActiveLengths(ushort? numActiveLengths_)
      {
         SetFieldValue(47, 0, numActiveLengths_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalWork field
      /// Units: J
      /// <returns>Returns nullable uint representing the TotalWork field</returns>
      public uint? GetTotalWork()
      {
         return (uint?)GetFieldValue(48, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalWork field
      /// Units: J
      /// <param name="totalWork_">Nullable field value to be set</param>
      public void SetTotalWork(uint? totalWork_)
      {
         SetFieldValue(48, 0, totalWork_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgAltitude field
      /// Units: m
      /// <returns>Returns nullable float representing the AvgAltitude field</returns>
      public float? GetAvgAltitude()
      {
         return (float?)GetFieldValue(49, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgAltitude field
      /// Units: m
      /// <param name="avgAltitude_">Nullable field value to be set</param>
      public void SetAvgAltitude(float? avgAltitude_)
      {
         SetFieldValue(49, 0, avgAltitude_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxAltitude field
      /// Units: m
      /// <returns>Returns nullable float representing the MaxAltitude field</returns>
      public float? GetMaxAltitude()
      {
         return (float?)GetFieldValue(50, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxAltitude field
      /// Units: m
      /// <param name="maxAltitude_">Nullable field value to be set</param>
      public void SetMaxAltitude(float? maxAltitude_)
      {
         SetFieldValue(50, 0, maxAltitude_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the GpsAccuracy field
      /// Units: m
      /// <returns>Returns nullable byte representing the GpsAccuracy field</returns>
      public byte? GetGpsAccuracy()
      {
         return (byte?)GetFieldValue(51, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set GpsAccuracy field
      /// Units: m
      /// <param name="gpsAccuracy_">Nullable field value to be set</param>
      public void SetGpsAccuracy(byte? gpsAccuracy_)
      {
         SetFieldValue(51, 0, gpsAccuracy_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgGrade field
      /// Units: %
      /// <returns>Returns nullable float representing the AvgGrade field</returns>
      public float? GetAvgGrade()
      {
         return (float?)GetFieldValue(52, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgGrade field
      /// Units: %
      /// <param name="avgGrade_">Nullable field value to be set</param>
      public void SetAvgGrade(float? avgGrade_)
      {
         SetFieldValue(52, 0, avgGrade_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgPosGrade field
      /// Units: %
      /// <returns>Returns nullable float representing the AvgPosGrade field</returns>
      public float? GetAvgPosGrade()
      {
         return (float?)GetFieldValue(53, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgPosGrade field
      /// Units: %
      /// <param name="avgPosGrade_">Nullable field value to be set</param>
      public void SetAvgPosGrade(float? avgPosGrade_)
      {
         SetFieldValue(53, 0, avgPosGrade_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgNegGrade field
      /// Units: %
      /// <returns>Returns nullable float representing the AvgNegGrade field</returns>
      public float? GetAvgNegGrade()
      {
         return (float?)GetFieldValue(54, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgNegGrade field
      /// Units: %
      /// <param name="avgNegGrade_">Nullable field value to be set</param>
      public void SetAvgNegGrade(float? avgNegGrade_)
      {
         SetFieldValue(54, 0, avgNegGrade_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxPosGrade field
      /// Units: %
      /// <returns>Returns nullable float representing the MaxPosGrade field</returns>
      public float? GetMaxPosGrade()
      {
         return (float?)GetFieldValue(55, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxPosGrade field
      /// Units: %
      /// <param name="maxPosGrade_">Nullable field value to be set</param>
      public void SetMaxPosGrade(float? maxPosGrade_)
      {
         SetFieldValue(55, 0, maxPosGrade_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxNegGrade field
      /// Units: %
      /// <returns>Returns nullable float representing the MaxNegGrade field</returns>
      public float? GetMaxNegGrade()
      {
         return (float?)GetFieldValue(56, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxNegGrade field
      /// Units: %
      /// <param name="maxNegGrade_">Nullable field value to be set</param>
      public void SetMaxNegGrade(float? maxNegGrade_)
      {
         SetFieldValue(56, 0, maxNegGrade_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgTemperature field
      /// Units: C
      /// <returns>Returns nullable sbyte representing the AvgTemperature field</returns>
      public sbyte? GetAvgTemperature()
      {
         return (sbyte?)GetFieldValue(57, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgTemperature field
      /// Units: C
      /// <param name="avgTemperature_">Nullable field value to be set</param>
      public void SetAvgTemperature(sbyte? avgTemperature_)
      {
         SetFieldValue(57, 0, avgTemperature_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxTemperature field
      /// Units: C
      /// <returns>Returns nullable sbyte representing the MaxTemperature field</returns>
      public sbyte? GetMaxTemperature()
      {
         return (sbyte?)GetFieldValue(58, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxTemperature field
      /// Units: C
      /// <param name="maxTemperature_">Nullable field value to be set</param>
      public void SetMaxTemperature(sbyte? maxTemperature_)
      {
         SetFieldValue(58, 0, maxTemperature_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalMovingTime field
      /// Units: s
      /// <returns>Returns nullable float representing the TotalMovingTime field</returns>
      public float? GetTotalMovingTime()
      {
         return (float?)GetFieldValue(59, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalMovingTime field
      /// Units: s
      /// <param name="totalMovingTime_">Nullable field value to be set</param>
      public void SetTotalMovingTime(float? totalMovingTime_)
      {
         SetFieldValue(59, 0, totalMovingTime_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgPosVerticalSpeed field
      /// Units: m/s
      /// <returns>Returns nullable float representing the AvgPosVerticalSpeed field</returns>
      public float? GetAvgPosVerticalSpeed()
      {
         return (float?)GetFieldValue(60, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgPosVerticalSpeed field
      /// Units: m/s
      /// <param name="avgPosVerticalSpeed_">Nullable field value to be set</param>
      public void SetAvgPosVerticalSpeed(float? avgPosVerticalSpeed_)
      {
         SetFieldValue(60, 0, avgPosVerticalSpeed_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgNegVerticalSpeed field
      /// Units: m/s
      /// <returns>Returns nullable float representing the AvgNegVerticalSpeed field</returns>
      public float? GetAvgNegVerticalSpeed()
      {
         return (float?)GetFieldValue(61, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgNegVerticalSpeed field
      /// Units: m/s
      /// <param name="avgNegVerticalSpeed_">Nullable field value to be set</param>
      public void SetAvgNegVerticalSpeed(float? avgNegVerticalSpeed_)
      {
         SetFieldValue(61, 0, avgNegVerticalSpeed_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxPosVerticalSpeed field
      /// Units: m/s
      /// <returns>Returns nullable float representing the MaxPosVerticalSpeed field</returns>
      public float? GetMaxPosVerticalSpeed()
      {
         return (float?)GetFieldValue(62, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxPosVerticalSpeed field
      /// Units: m/s
      /// <param name="maxPosVerticalSpeed_">Nullable field value to be set</param>
      public void SetMaxPosVerticalSpeed(float? maxPosVerticalSpeed_)
      {
         SetFieldValue(62, 0, maxPosVerticalSpeed_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxNegVerticalSpeed field
      /// Units: m/s
      /// <returns>Returns nullable float representing the MaxNegVerticalSpeed field</returns>
      public float? GetMaxNegVerticalSpeed()
      {
         return (float?)GetFieldValue(63, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxNegVerticalSpeed field
      /// Units: m/s
      /// <param name="maxNegVerticalSpeed_">Nullable field value to be set</param>
      public void SetMaxNegVerticalSpeed(float? maxNegVerticalSpeed_)
      {
         SetFieldValue(63, 0, maxNegVerticalSpeed_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MinHeartRate field
      /// Units: bpm
      /// <returns>Returns nullable byte representing the MinHeartRate field</returns>
      public byte? GetMinHeartRate()
      {
         return (byte?)GetFieldValue(64, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MinHeartRate field
      /// Units: bpm
      /// <param name="minHeartRate_">Nullable field value to be set</param>
      public void SetMinHeartRate(byte? minHeartRate_)
      {
         SetFieldValue(64, 0, minHeartRate_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field TimeInHrZone</returns>
      public int GetNumTimeInHrZone()
      {
         return GetNumFieldValues(65, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TimeInHrZone field
      /// Units: s
      /// <param name="index">0 based index of TimeInHrZone element to retrieve</param>
      /// <returns>Returns nullable float representing the TimeInHrZone field</returns>
      public float? GetTimeInHrZone(int index)
      {
         return (float?)GetFieldValue(65, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TimeInHrZone field
      /// Units: s
      /// <param name="index">0 based index of time_in_hr_zone</param>
      /// <param name="timeInHrZone_">Nullable field value to be set</param>
      public void SetTimeInHrZone(int index, float? timeInHrZone_)
      {
         SetFieldValue(65, index, timeInHrZone_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field TimeInSpeedZone</returns>
      public int GetNumTimeInSpeedZone()
      {
         return GetNumFieldValues(66, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TimeInSpeedZone field
      /// Units: s
      /// <param name="index">0 based index of TimeInSpeedZone element to retrieve</param>
      /// <returns>Returns nullable float representing the TimeInSpeedZone field</returns>
      public float? GetTimeInSpeedZone(int index)
      {
         return (float?)GetFieldValue(66, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TimeInSpeedZone field
      /// Units: s
      /// <param name="index">0 based index of time_in_speed_zone</param>
      /// <param name="timeInSpeedZone_">Nullable field value to be set</param>
      public void SetTimeInSpeedZone(int index, float? timeInSpeedZone_)
      {
         SetFieldValue(66, index, timeInSpeedZone_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field TimeInCadenceZone</returns>
      public int GetNumTimeInCadenceZone()
      {
         return GetNumFieldValues(67, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TimeInCadenceZone field
      /// Units: s
      /// <param name="index">0 based index of TimeInCadenceZone element to retrieve</param>
      /// <returns>Returns nullable float representing the TimeInCadenceZone field</returns>
      public float? GetTimeInCadenceZone(int index)
      {
         return (float?)GetFieldValue(67, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TimeInCadenceZone field
      /// Units: s
      /// <param name="index">0 based index of time_in_cadence_zone</param>
      /// <param name="timeInCadenceZone_">Nullable field value to be set</param>
      public void SetTimeInCadenceZone(int index, float? timeInCadenceZone_)
      {
         SetFieldValue(67, index, timeInCadenceZone_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field TimeInPowerZone</returns>
      public int GetNumTimeInPowerZone()
      {
         return GetNumFieldValues(68, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TimeInPowerZone field
      /// Units: s
      /// <param name="index">0 based index of TimeInPowerZone element to retrieve</param>
      /// <returns>Returns nullable float representing the TimeInPowerZone field</returns>
      public float? GetTimeInPowerZone(int index)
      {
         return (float?)GetFieldValue(68, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TimeInPowerZone field
      /// Units: s
      /// <param name="index">0 based index of time_in_power_zone</param>
      /// <param name="timeInPowerZone_">Nullable field value to be set</param>
      public void SetTimeInPowerZone(int index, float? timeInPowerZone_)
      {
         SetFieldValue(68, index, timeInPowerZone_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgLapTime field
      /// Units: s
      /// <returns>Returns nullable float representing the AvgLapTime field</returns>
      public float? GetAvgLapTime()
      {
         return (float?)GetFieldValue(69, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgLapTime field
      /// Units: s
      /// <param name="avgLapTime_">Nullable field value to be set</param>
      public void SetAvgLapTime(float? avgLapTime_)
      {
         SetFieldValue(69, 0, avgLapTime_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the BestLapIndex field
      /// <returns>Returns nullable ushort representing the BestLapIndex field</returns>
      public ushort? GetBestLapIndex()
      {
         return (ushort?)GetFieldValue(70, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set BestLapIndex field
      /// <param name="bestLapIndex_">Nullable field value to be set</param>
      public void SetBestLapIndex(ushort? bestLapIndex_)
      {
         SetFieldValue(70, 0, bestLapIndex_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MinAltitude field
      /// Units: m
      /// <returns>Returns nullable float representing the MinAltitude field</returns>
      public float? GetMinAltitude()
      {
         return (float?)GetFieldValue(71, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MinAltitude field
      /// Units: m
      /// <param name="minAltitude_">Nullable field value to be set</param>
      public void SetMinAltitude(float? minAltitude_)
      {
         SetFieldValue(71, 0, minAltitude_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the PlayerScore field
      /// <returns>Returns nullable ushort representing the PlayerScore field</returns>
      public ushort? GetPlayerScore()
      {
         return (ushort?)GetFieldValue(82, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set PlayerScore field
      /// <param name="playerScore_">Nullable field value to be set</param>
      public void SetPlayerScore(ushort? playerScore_)
      {
         SetFieldValue(82, 0, playerScore_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the OpponentScore field
      /// <returns>Returns nullable ushort representing the OpponentScore field</returns>
      public ushort? GetOpponentScore()
      {
         return (ushort?)GetFieldValue(83, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set OpponentScore field
      /// <param name="opponentScore_">Nullable field value to be set</param>
      public void SetOpponentScore(ushort? opponentScore_)
      {
         SetFieldValue(83, 0, opponentScore_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the OpponentName field
      /// <returns>Returns byte[] representing the OpponentName field</returns>
      public byte[] GetOpponentName()
      {
         return (byte[])GetFieldValue(84, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set OpponentName field
      /// <param name="opponentName_">field value to be set</param>
      public void SetOpponentName(byte[] opponentName_)
      {
         SetFieldValue(84, 0, opponentName_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field StrokeCount</returns>
      public int GetNumStrokeCount()
      {
         return GetNumFieldValues(85, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the StrokeCount field
      /// Units: counts
      /// Comment: stroke_type enum used as the index
      /// <param name="index">0 based index of StrokeCount element to retrieve</param>
      /// <returns>Returns nullable ushort representing the StrokeCount field</returns>
      public ushort? GetStrokeCount(int index)
      {
         return (ushort?)GetFieldValue(85, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set StrokeCount field
      /// Units: counts
      /// Comment: stroke_type enum used as the index
      /// <param name="index">0 based index of stroke_count</param>
      /// <param name="strokeCount_">Nullable field value to be set</param>
      public void SetStrokeCount(int index, ushort? strokeCount_)
      {
         SetFieldValue(85, index, strokeCount_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field ZoneCount</returns>
      public int GetNumZoneCount()
      {
         return GetNumFieldValues(86, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the ZoneCount field
      /// Units: counts
      /// Comment: zone number used as the index
      /// <param name="index">0 based index of ZoneCount element to retrieve</param>
      /// <returns>Returns nullable ushort representing the ZoneCount field</returns>
      public ushort? GetZoneCount(int index)
      {
         return (ushort?)GetFieldValue(86, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set ZoneCount field
      /// Units: counts
      /// Comment: zone number used as the index
      /// <param name="index">0 based index of zone_count</param>
      /// <param name="zoneCount_">Nullable field value to be set</param>
      public void SetZoneCount(int index, ushort? zoneCount_)
      {
         SetFieldValue(86, index, zoneCount_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxBallSpeed field
      /// Units: m/s
      /// <returns>Returns nullable float representing the MaxBallSpeed field</returns>
      public float? GetMaxBallSpeed()
      {
         return (float?)GetFieldValue(87, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxBallSpeed field
      /// Units: m/s
      /// <param name="maxBallSpeed_">Nullable field value to be set</param>
      public void SetMaxBallSpeed(float? maxBallSpeed_)
      {
         SetFieldValue(87, 0, maxBallSpeed_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgBallSpeed field
      /// Units: m/s
      /// <returns>Returns nullable float representing the AvgBallSpeed field</returns>
      public float? GetAvgBallSpeed()
      {
         return (float?)GetFieldValue(88, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgBallSpeed field
      /// Units: m/s
      /// <param name="avgBallSpeed_">Nullable field value to be set</param>
      public void SetAvgBallSpeed(float? avgBallSpeed_)
      {
         SetFieldValue(88, 0, avgBallSpeed_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgVerticalOscillation field
      /// Units: mm
      /// <returns>Returns nullable float representing the AvgVerticalOscillation field</returns>
      public float? GetAvgVerticalOscillation()
      {
         return (float?)GetFieldValue(89, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgVerticalOscillation field
      /// Units: mm
      /// <param name="avgVerticalOscillation_">Nullable field value to be set</param>
      public void SetAvgVerticalOscillation(float? avgVerticalOscillation_)
      {
         SetFieldValue(89, 0, avgVerticalOscillation_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgStanceTimePercent field
      /// Units: percent
      /// <returns>Returns nullable float representing the AvgStanceTimePercent field</returns>
      public float? GetAvgStanceTimePercent()
      {
         return (float?)GetFieldValue(90, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgStanceTimePercent field
      /// Units: percent
      /// <param name="avgStanceTimePercent_">Nullable field value to be set</param>
      public void SetAvgStanceTimePercent(float? avgStanceTimePercent_)
      {
         SetFieldValue(90, 0, avgStanceTimePercent_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgStanceTime field
      /// Units: ms
      /// <returns>Returns nullable float representing the AvgStanceTime field</returns>
      public float? GetAvgStanceTime()
      {
         return (float?)GetFieldValue(91, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgStanceTime field
      /// Units: ms
      /// <param name="avgStanceTime_">Nullable field value to be set</param>
      public void SetAvgStanceTime(float? avgStanceTime_)
      {
         SetFieldValue(91, 0, avgStanceTime_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgFractionalCadence field
      /// Units: rpm
      /// Comment: fractional part of the avg_cadence
      /// <returns>Returns nullable float representing the AvgFractionalCadence field</returns>
      public float? GetAvgFractionalCadence()
      {
         return (float?)GetFieldValue(92, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgFractionalCadence field
      /// Units: rpm
      /// Comment: fractional part of the avg_cadence
      /// <param name="avgFractionalCadence_">Nullable field value to be set</param>
      public void SetAvgFractionalCadence(float? avgFractionalCadence_)
      {
         SetFieldValue(92, 0, avgFractionalCadence_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxFractionalCadence field
      /// Units: rpm
      /// Comment: fractional part of the max_cadence
      /// <returns>Returns nullable float representing the MaxFractionalCadence field</returns>
      public float? GetMaxFractionalCadence()
      {
         return (float?)GetFieldValue(93, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxFractionalCadence field
      /// Units: rpm
      /// Comment: fractional part of the max_cadence
      /// <param name="maxFractionalCadence_">Nullable field value to be set</param>
      public void SetMaxFractionalCadence(float? maxFractionalCadence_)
      {
         SetFieldValue(93, 0, maxFractionalCadence_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the TotalFractionalCycles field
      /// Units: cycles
      /// Comment: fractional part of the total_cycles
      /// <returns>Returns nullable float representing the TotalFractionalCycles field</returns>
      public float? GetTotalFractionalCycles()
      {
         return (float?)GetFieldValue(94, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set TotalFractionalCycles field
      /// Units: cycles
      /// Comment: fractional part of the total_cycles
      /// <param name="totalFractionalCycles_">Nullable field value to be set</param>
      public void SetTotalFractionalCycles(float? totalFractionalCycles_)
      {
         SetFieldValue(94, 0, totalFractionalCycles_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field AvgTotalHemoglobinConc</returns>
      public int GetNumAvgTotalHemoglobinConc()
      {
         return GetNumFieldValues(95, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgTotalHemoglobinConc field
      /// Units: g/dL
      /// Comment: Avg saturated and unsaturated hemoglobin
      /// <param name="index">0 based index of AvgTotalHemoglobinConc element to retrieve</param>
      /// <returns>Returns nullable float representing the AvgTotalHemoglobinConc field</returns>
      public float? GetAvgTotalHemoglobinConc(int index)
      {
         return (float?)GetFieldValue(95, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgTotalHemoglobinConc field
      /// Units: g/dL
      /// Comment: Avg saturated and unsaturated hemoglobin
      /// <param name="index">0 based index of avg_total_hemoglobin_conc</param>
      /// <param name="avgTotalHemoglobinConc_">Nullable field value to be set</param>
      public void SetAvgTotalHemoglobinConc(int index, float? avgTotalHemoglobinConc_)
      {
         SetFieldValue(95, index, avgTotalHemoglobinConc_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field MinTotalHemoglobinConc</returns>
      public int GetNumMinTotalHemoglobinConc()
      {
         return GetNumFieldValues(96, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MinTotalHemoglobinConc field
      /// Units: g/dL
      /// Comment: Min saturated and unsaturated hemoglobin
      /// <param name="index">0 based index of MinTotalHemoglobinConc element to retrieve</param>
      /// <returns>Returns nullable float representing the MinTotalHemoglobinConc field</returns>
      public float? GetMinTotalHemoglobinConc(int index)
      {
         return (float?)GetFieldValue(96, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MinTotalHemoglobinConc field
      /// Units: g/dL
      /// Comment: Min saturated and unsaturated hemoglobin
      /// <param name="index">0 based index of min_total_hemoglobin_conc</param>
      /// <param name="minTotalHemoglobinConc_">Nullable field value to be set</param>
      public void SetMinTotalHemoglobinConc(int index, float? minTotalHemoglobinConc_)
      {
         SetFieldValue(96, index, minTotalHemoglobinConc_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field MaxTotalHemoglobinConc</returns>
      public int GetNumMaxTotalHemoglobinConc()
      {
         return GetNumFieldValues(97, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxTotalHemoglobinConc field
      /// Units: g/dL
      /// Comment: Max saturated and unsaturated hemoglobin
      /// <param name="index">0 based index of MaxTotalHemoglobinConc element to retrieve</param>
      /// <returns>Returns nullable float representing the MaxTotalHemoglobinConc field</returns>
      public float? GetMaxTotalHemoglobinConc(int index)
      {
         return (float?)GetFieldValue(97, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxTotalHemoglobinConc field
      /// Units: g/dL
      /// Comment: Max saturated and unsaturated hemoglobin
      /// <param name="index">0 based index of max_total_hemoglobin_conc</param>
      /// <param name="maxTotalHemoglobinConc_">Nullable field value to be set</param>
      public void SetMaxTotalHemoglobinConc(int index, float? maxTotalHemoglobinConc_)
      {
         SetFieldValue(97, index, maxTotalHemoglobinConc_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field AvgSaturatedHemoglobinPercent</returns>
      public int GetNumAvgSaturatedHemoglobinPercent()
      {
         return GetNumFieldValues(98, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgSaturatedHemoglobinPercent field
      /// Units: %
      /// Comment: Avg percentage of hemoglobin saturated with oxygen
      /// <param name="index">0 based index of AvgSaturatedHemoglobinPercent element to retrieve</param>
      /// <returns>Returns nullable float representing the AvgSaturatedHemoglobinPercent field</returns>
      public float? GetAvgSaturatedHemoglobinPercent(int index)
      {
         return (float?)GetFieldValue(98, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgSaturatedHemoglobinPercent field
      /// Units: %
      /// Comment: Avg percentage of hemoglobin saturated with oxygen
      /// <param name="index">0 based index of avg_saturated_hemoglobin_percent</param>
      /// <param name="avgSaturatedHemoglobinPercent_">Nullable field value to be set</param>
      public void SetAvgSaturatedHemoglobinPercent(int index, float? avgSaturatedHemoglobinPercent_)
      {
         SetFieldValue(98, index, avgSaturatedHemoglobinPercent_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field MinSaturatedHemoglobinPercent</returns>
      public int GetNumMinSaturatedHemoglobinPercent()
      {
         return GetNumFieldValues(99, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MinSaturatedHemoglobinPercent field
      /// Units: %
      /// Comment: Min percentage of hemoglobin saturated with oxygen
      /// <param name="index">0 based index of MinSaturatedHemoglobinPercent element to retrieve</param>
      /// <returns>Returns nullable float representing the MinSaturatedHemoglobinPercent field</returns>
      public float? GetMinSaturatedHemoglobinPercent(int index)
      {
         return (float?)GetFieldValue(99, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MinSaturatedHemoglobinPercent field
      /// Units: %
      /// Comment: Min percentage of hemoglobin saturated with oxygen
      /// <param name="index">0 based index of min_saturated_hemoglobin_percent</param>
      /// <param name="minSaturatedHemoglobinPercent_">Nullable field value to be set</param>
      public void SetMinSaturatedHemoglobinPercent(int index, float? minSaturatedHemoglobinPercent_)
      {
         SetFieldValue(99, index, minSaturatedHemoglobinPercent_, Fit.SubfieldIndexMainField);
      }

      ///
      ///
      ///
      /// <returns>returns number of elements in field MaxSaturatedHemoglobinPercent</returns>
      public int GetNumMaxSaturatedHemoglobinPercent()
      {
         return GetNumFieldValues(100, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the MaxSaturatedHemoglobinPercent field
      /// Units: %
      /// Comment: Max percentage of hemoglobin saturated with oxygen
      /// <param name="index">0 based index of MaxSaturatedHemoglobinPercent element to retrieve</param>
      /// <returns>Returns nullable float representing the MaxSaturatedHemoglobinPercent field</returns>
      public float? GetMaxSaturatedHemoglobinPercent(int index)
      {
         return (float?)GetFieldValue(100, index, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set MaxSaturatedHemoglobinPercent field
      /// Units: %
      /// Comment: Max percentage of hemoglobin saturated with oxygen
      /// <param name="index">0 based index of max_saturated_hemoglobin_percent</param>
      /// <param name="maxSaturatedHemoglobinPercent_">Nullable field value to be set</param>
      public void SetMaxSaturatedHemoglobinPercent(int index, float? maxSaturatedHemoglobinPercent_)
      {
         SetFieldValue(100, index, maxSaturatedHemoglobinPercent_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgLeftTorqueEffectiveness field
      /// Units: percent
      /// <returns>Returns nullable float representing the AvgLeftTorqueEffectiveness field</returns>
      public float? GetAvgLeftTorqueEffectiveness()
      {
         return (float?)GetFieldValue(101, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgLeftTorqueEffectiveness field
      /// Units: percent
      /// <param name="avgLeftTorqueEffectiveness_">Nullable field value to be set</param>
      public void SetAvgLeftTorqueEffectiveness(float? avgLeftTorqueEffectiveness_)
      {
         SetFieldValue(101, 0, avgLeftTorqueEffectiveness_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgRightTorqueEffectiveness field
      /// Units: percent
      /// <returns>Returns nullable float representing the AvgRightTorqueEffectiveness field</returns>
      public float? GetAvgRightTorqueEffectiveness()
      {
         return (float?)GetFieldValue(102, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgRightTorqueEffectiveness field
      /// Units: percent
      /// <param name="avgRightTorqueEffectiveness_">Nullable field value to be set</param>
      public void SetAvgRightTorqueEffectiveness(float? avgRightTorqueEffectiveness_)
      {
         SetFieldValue(102, 0, avgRightTorqueEffectiveness_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgLeftPedalSmoothness field
      /// Units: percent
      /// <returns>Returns nullable float representing the AvgLeftPedalSmoothness field</returns>
      public float? GetAvgLeftPedalSmoothness()
      {
         return (float?)GetFieldValue(103, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgLeftPedalSmoothness field
      /// Units: percent
      /// <param name="avgLeftPedalSmoothness_">Nullable field value to be set</param>
      public void SetAvgLeftPedalSmoothness(float? avgLeftPedalSmoothness_)
      {
         SetFieldValue(103, 0, avgLeftPedalSmoothness_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgRightPedalSmoothness field
      /// Units: percent
      /// <returns>Returns nullable float representing the AvgRightPedalSmoothness field</returns>
      public float? GetAvgRightPedalSmoothness()
      {
         return (float?)GetFieldValue(104, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgRightPedalSmoothness field
      /// Units: percent
      /// <param name="avgRightPedalSmoothness_">Nullable field value to be set</param>
      public void SetAvgRightPedalSmoothness(float? avgRightPedalSmoothness_)
      {
         SetFieldValue(104, 0, avgRightPedalSmoothness_, Fit.SubfieldIndexMainField);
      }

      ///
      /// Retrieves the AvgCombinedPedalSmoothness field
      /// Units: percent
      /// <returns>Returns nullable float representing the AvgCombinedPedalSmoothness field</returns>
      public float? GetAvgCombinedPedalSmoothness()
      {
         return (float?)GetFieldValue(105, 0, Fit.SubfieldIndexMainField);
      }

      ///
      /// Set AvgCombinedPedalSmoothness field
      /// Units: percent
      /// <param name="avgCombinedPedalSmoothness_">Nullable field value to be set</param>
      public void SetAvgCombinedPedalSmoothness(float? avgCombinedPedalSmoothness_)
      {
         SetFieldValue(105, 0, avgCombinedPedalSmoothness_, Fit.SubfieldIndexMainField);
      }

      #endregion // Methods
   } // Class
} // namespace


text:
<job extends="lib:bench:auction/config/job">
	<serverNum>3</serverNum>
	<workerNum>8</workerNum>
	<populateThreads>32</populateThreads>
	<userNum>30000</userNum>
    <maxCountPerSession>10</maxCountPerSession>
	<threadPerNode>200</threadPerNode>
	<rampupTime>30</rampupTime>
	<measureTime>60</measureTime>
	<populateWorkerNum ref="workerNum" />
	<servers>
	  <workerHosts/>
	  <cluster/>
	</servers>
	<cluster ref="servers/cluster"/>
	<environment/>
	<dbName>test</dbName>
	<database/>
	<tasks>
		<populate extends=".">
			<cluster ref="cluster">
				<size ref="populateWorkerNum" />
			</cluster>
		</populate>
		<workload extends=".">
			<measure extends=".">
				<poll>2</poll>
				<monitors>
					<worker extends="jmx/worker-session">
						<hosts ref="servers/workerHosts" />
						<out>avg</out>
					</worker>
				</monitors>
			</measure>
		</workload>
	</tasks>

	<reporter>
		<include>
			<workers type="number" ref="workerNum" />
			<threads type="number" ref="threadPerNode" />
		</include>
	</reporter>

</job>


text:
package net.minecraft.client.settings;

public class KeyBinding {

    /** keycode */
    public int field_74512_d;
}


text:
xdebug () {
read xdebugpart
echo "xdebug location at $xdebugpart"
cat << EOF | sudo tee -a /etc/php5/apache2/php.ini
xdebug.remote_host = 192.168.33.1
xdebug.remote_enable = 1
xdebug.remote_port = 9000
xdebug.remote_handler = dbgp
xdebug.remote_mode = req
zend_extension=$xdebugpart
EOF

cat << EOF | sudo tee -a /etc/php5/cli/php.ini
xdebug.remote_host = 192.168.33.1
xdebug.remote_enable = 1
xdebug.remote_port = 9000
xdebug.remote_handler = dbgp
xdebug.remote_mode = req
EOF
}

mkDirIfNotExist() {
if [ -d $1 ];
then
    echo $1 " exists"
else
    echo $1 " not exists"
    sudo mkdir -p $1
    echo $1 " created"
fi
}

forceSymLink() {
    sudo rm -rf $2
    sudo ln -s $1 $2
    echo $2 " created"
}

echo "Start provisioning"

sudo apt-get update >/dev/null 2>&1

sudo a2enmod headers
echo "installing phing"
sudo apt-get install php5-dev >/dev/null 2>&1
sudo apt-get install php-pear >/dev/null 2>&1
sudo pear channel-discover pear.phing.info >/dev/null 2>&1
sudo pear install --alldeps phing/phing >/dev/null 2>&1

sudo apt-get install php5-xdebug >/dev/null 2>&1
echo "writing xdebug"
cd /usr/lib
find $PWD -name "xdebug.so"  | xdebug
cd /vagrant

sudo rm -rf /etc/apache2/sites-enabled/*
sudo cp -r /vagrant/apache_hosts/* /etc/apache2/sites-available/
sudo a2ensite 0_macro.conf
sudo a2ensite vhosts.conf
sudo a2ensite ssl.conf
forceSymLink "/var/www/www.zf2.dev/project/public" "/var/www/www.zf2.dev/webroot"

sudo chown -R www-data.www-data /var/www/www.zf2.dev

sudo service apache2 restart >/dev/null 2>&1
#in case mysql is not running
sudo service mysql restart >/dev/null 2>&1

echo "Provisioning complete"


text:
/* jslint multistr: true */
/* eslint-env jasmine, jquery */

import 'jquery';
import * as testutils from '../common/specCommonUtils';
import 'jasmine-jquery';
import 'rup.feedback';
import 'rup.validate';

describe('Test Validate >  ', () => {
    var $validate, $feedBack, $validateEvent;
    var event_fail = false,
        event_success = false;

    beforeAll((done) => {
        testutils.loadCss(done);
    });

    beforeEach(() => {
        var html = '<form id="exampleValidate">\
                            Campo 1<input type="text" name="campoUno" id="campoUno"></input > \
                            Campo 2<input type="text" name="campoDos" id="campoDos"></input>\
                        </form>\

';
        $('#content').append(html);
        var htmlEvent = '<form id="exampleValidateEvent">\
                            Campo 1<input type="text" name="campoUnoEvent" id="campoUnoEvent"></input >\
                        </form>';
        $('#content').append(htmlEvent);

        var optsFeedback = {
            type: 'ok',
            closeLink: true,
            block: false
        };
        $feedBack = $('#feedback').rup_feedback(optsFeedback);
        var optsValidate = {
            feedback: $feedBack,
            liveCheckingErrors: false,
            showFieldErrorAsDefault: true,
            showErrorsInFeedback: true,
            showFieldErrorsInFeedback: true,
            rules: {
                'campoUno': {
                    required: true
                },
                'campoDos': {
                    required: true
                }
            }
        };
        $validate = $('#exampleValidate').rup_validate(optsValidate);

        $validateEvent = $('#exampleValidateEvent').rup_validate({
            rules: {
                'campoUnoEvent': {
                    required: true
                }
            },
            onSubmitHandler: () => {
                event_success = true;
                $('#exampleValidateEvent').triggerHandler('submitSuccessfull');
            },
            invalidHandler: () => {
                event_fail = true;
            }
        });
    });
    afterEach(() => {
        $('#content').html('');
        $('#content').nextAll().html('');
        event_success = false;
        event_fail = false;
    });
    describe('Creación > ', () => {
        it('El formulario tiene que tener la clase rup_validate', () => {
            expect($validate.hasClass('rup_validate')).toBeTruthy();
        });
        it('El feedback debe estar oculto', () => {
            expect($feedBack.is(':visible')).toBeFalsy();
        });
    });
    describe('La validación funciona, no debe pasar > ', () => {
        beforeEach(() => {
            $('#campoUno').val('foo');
            $validate.valid();
        });
        it('Debe mostrarse el feedback', () => {
            expect($feedBack.is(':visible')).toBeTruthy();
        });
        it('Cada campo del form debe tener la clase error', () => {
            expect($('#campoUno').hasClass('error')).toBeFalsy();
            expect($('#campoDos').hasClass('error')).toBeTruthy();
        });
    });
    describe('La validación funciona, debe pasar > ', () => {
        beforeEach(() => {
            $('#campoUno').val('foo');
            $('#campoDos').val('foo');
            $validate.valid();
        });
        it('No debe mostrarse el feedback', () => {
            expect($feedBack.is(':visible')).toBeFalsy();
        });
        it('Cada campo del form debe tener la clase error', () => {
            expect($('#campoUno').hasClass('error')).toBeFalsy();
            expect($('#campoDos').hasClass('error')).toBeFalsy();
        });
    });
    describe('Eventos > ', () => {
        describe('invalidHandler', () => {
            beforeEach((done) => {
                $('#exampleValidateEvent').on('rupValidate_formValidationError', () => {
                    done();
                });
                $('#campoUnoEvent').val('');
                $validateEvent.valid();
            });
            it('Debe lanzarse el evento', () => {
                expect(event_fail).toBeTruthy();
            });
        });
        describe('onSubmitHandler', () => {
            beforeEach((done) => {
                // $('#exampleValidateEvent').on('submitSuccessfull', () => {
                //     done();
                // });
                $('#campoUnoEvent').val('foo');
                $validateEvent.submit();
                setTimeout(() => {
                    done();
                }, 500);
            });
            it('Debe lanzarse el evento', () => {
                expect(event_success).toBeTruthy();
            });
        });
    });
    describe('Métodos públicos > ', () => {
        describe('Método resetForm > ', () => {
            beforeEach(() => {
                $validate.valid();
                $validate.rup_validate('resetForm');
            });
            it('Debe mantenerse el feedback', () => {
                expect($feedBack.is(':visible')).toBeTruthy();
            });
            it('Los campos del form no deben tener la clase error', () => {
                expect($('#campoUno').hasClass('error')).toBeFalsy();
                expect($('#campoDos').hasClass('error')).toBeFalsy();
            });
        });
        describe('Método resetElements > ', () => {
            beforeEach(() => {
                $validate.valid();
                $validate.rup_validate('resetElements');
            });
            it('Debe mantenerse el feedback', () => {
                expect($feedBack.is(':visible')).toBeTruthy();
            });
            it('Los campos del form no deben tener la clase error', () => {
                expect($('#campoUno').hasClass('error')).toBeFalsy();
                expect($('#campoDos').hasClass('error')).toBeFalsy();
            });
        });
        describe('Método destroy > ', () => {
            beforeEach(() => {
                $validate.rup_validate('destroy');
                $validate.valid();
            });
            it('No debe existir', () => {
                expect($('#campoUno').hasClass('error')).toBeFalsy();
                expect($('#campoDos').hasClass('error')).toBeFalsy();
            });
        });
    });
});


text:
namespace ipcz {

RefCounted::RefCounted() = default;

RefCounted::~RefCounted() = default;

void RefCounted::AcquireRef() {
  ref_count_.fetch_add(1, std::memory_order_relaxed);
}

void RefCounted::ReleaseRef() {
  // SUBTLE: Technically the load does not need to be an acquire unless we're
  // releasing the last reference and need to delete `this`, but it's not clear
  // whether std::memory_order_acq_rel here will produce more or less efficient
  // code compared to a plain std::memory_order_release followed by an acquire
  // fence in the conditional block below.
  int last_count = ref_count_.fetch_sub(1, std::memory_order_acq_rel);
  ABSL_ASSERT(last_count > 0);
  if (last_count == 1) {
    delete this;
  }
}

GenericRef::GenericRef(decltype(RefCounted::kAdoptExistingRef), RefCounted* ptr)
    : ptr_(ptr) {}

GenericRef::GenericRef(RefCounted* ptr) : ptr_(ptr) {
  if (ptr_) {
    ptr_->AcquireRef();
  }
}

GenericRef::GenericRef(GenericRef&& other)
    : ptr_(std::exchange(other.ptr_, nullptr)) {}

GenericRef& GenericRef::operator=(GenericRef&& other) {
  reset();
  ptr_ = std::exchange(other.ptr_, nullptr);
  return *this;
}

GenericRef::GenericRef(const GenericRef& other) : ptr_(other.ptr_) {
  if (ptr_) {
    ptr_->AcquireRef();
  }
}

GenericRef& GenericRef::operator=(const GenericRef& other) {
  reset();
  ptr_ = other.ptr_;
  if (ptr_) {
    ptr_->AcquireRef();
  }
  return *this;
}

GenericRef::~GenericRef() {
  reset();
}

void GenericRef::reset() {
  if (ptr_) {
    std::exchange(ptr_, nullptr)->ReleaseRef();
  }
}

void* GenericRef::ReleaseImpl() {
  return std::exchange(ptr_, nullptr);
}

}  // namespace ipcz


text:
/* ###
 * IP: GHIDRA
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package docking.widgets.fieldpanel.internal;

import java.math.BigInteger;
import java.util.ArrayList;
import java.util.List;

import docking.widgets.fieldpanel.FieldPanel;
import ghidra.util.exception.AssertException;

/**
 * A LineLockedFieldPanelCoordinator coordinates the scrolling of a set of field panels by sharing
 * bound scroll models that are locked together by a set of line numbers.
 * All the field panels are locked together at the line numbers specified in the locked line array.
 * In other words this coordinator tries to keep the indicated line for each field panel
 * side by side with the indicated line for each other field panel.
 */
public class LineLockedFieldPanelCoordinator extends FieldPanelCoordinator {

	// Keep an array of the line number for each field panel where we are locking
	// these field panels together when scrolling or moving the cursor location.
	protected BigInteger[] lockedLineNumbers;

	public LineLockedFieldPanelCoordinator(FieldPanel[] panels) {
		super(panels);
		resetLockedLines();
	}

	/**
	 * Resets the locked line numbers for this field panel coordinator to their default
	 * of each being zero.
	 */
	public void resetLockedLines() {
		// Make the locked line numbers default to 0.
		lockedLineNumbers = new BigInteger[panels.length];
		for (int i = 0; i < lockedLineNumbers.length; i++) {
			this.lockedLineNumbers[i] = BigInteger.ZERO;
		}
	}

	/**
	 * Call this method whenever you want to change the line numbers that are locked together
	 * for the associated field panels.
	 * @param lockedLineNumbers the array of locked line numbers that are directly associated with
	 * the array of field panels.<BR>
	 * Important: Make sure the line numbers are in the order that matches the field panels in the array.
	 */
	public void setLockedLines(BigInteger[] lockedLineNumbers) {
		if (lockedLineNumbers.length != this.lockedLineNumbers.length) {
			throw new AssertException("The number of lines(" + lockedLineNumbers.length +
				") must exactly match the number of panels(" + this.lockedLineNumbers.length +
				").");
		}
		for (int i = 0; i < lockedLineNumbers.length; i++) {
			if (lockedLineNumbers[i] == null) {
				lockedLineNumbers[i] = BigInteger.ZERO;
			}
		}
		for (int i = 0; i < lockedLineNumbers.length; i++) {
			if (!this.lockedLineNumbers[i].equals(lockedLineNumbers[i])) {
				this.lockedLineNumbers[i] = lockedLineNumbers[i];
			}
		}
	}

	/**
	 * Adds the given field panel to the list of panels to coordinate.
	 * @param fp the field panel to add.
	 */
	@Override
	public void add(FieldPanel fp) {
		// Adjust our locked line number array.
		BigInteger[] newLineNumbers = new BigInteger[lockedLineNumbers.length + 1];
		System.arraycopy(lockedLineNumbers, 0, newLineNumbers, 0, lockedLineNumbers.length);
		newLineNumbers[panels.length] = BigInteger.valueOf(0L);
		lockedLineNumbers = newLineNumbers;

		// The super class will adjust the field panel array.
		super.add(fp);
	}

	/**
	 * Removes the given field panel from the list of those to be coordinated.
	 */
	@Override
	public void remove(FieldPanel fp) {
		List<BigInteger> lineNumberList = new ArrayList<>(panels.length);
		// Adjust our locked line number array.
		int length = panels.length;
		for (int i = 0; i < length; i++) {
			if (panels[i] != fp) {
				lineNumberList.add(lockedLineNumbers[i]);
			}
		}
		lockedLineNumbers = lineNumberList.toArray(new BigInteger[lineNumberList.size()]);

		// The super class will adjust the field panel array.
		super.remove(fp);
	}

	@Override
	public void viewChanged(FieldPanel fp, BigInteger index, int xPos, int yPos) {
		if (valuesChanging)
			return;
		try {
			valuesChanging = true;
			BigInteger fpLineNumber = getLockedLineForPanel(fp);
			if (fpLineNumber == null) {
				throw new AssertException("Couldn't find line number for indicated field panel.");
			}
			// Position the views for the other panels to match the changed one the best they can.
			for (int i = 0; i < panels.length; i++) {
				if (panels[i] != fp) {
					BigInteger adjustment = lockedLineNumbers[i].subtract(fpLineNumber);
					BigInteger panelIndex = index.add(adjustment);
					if (panelIndex.longValue() < 0) {
						panelIndex = BigInteger.valueOf(0L);
					}
					panels[i].setViewerPosition(panelIndex, xPos, yPos);
				}
			}
		}
		finally {
			valuesChanging = false;
		}
	}

	/**
	 * Gets the locked line value for the indicated panel.
	 * @param fp the field panel whose locked line value is wanted.
	 * @return the locked line value or null if the panel isn't found.
	 */
	protected BigInteger getLockedLineForPanel(FieldPanel fp) {
		for (int i = 0; i < lockedLineNumbers.length; i++) {
			if (panels[i] == fp) {
				return lockedLineNumbers[i];
			}
		}
		return null;
	}
}