void UpdateBiologicalSex()
 {
     //https://www.npmjs.com/package/cordova-plugin-health
     //-- Helpful mapping of HealthKit attributes to Google Fit constants.
     // Retrieval of gender is not supported, but can be added as a custom attribute for just this app.
     HealthStateMutator.MutateBiologicalSex(
         StateDispatcher <HealthState> .State, () => "Unknown");
 }
        private void RefreshCharacteristicValue(NSString characteristicTypeKey, HKCharacteristicType characteristicType)
        {
            if (characteristicTypeKey == HKCharacteristicTypeIdentifierKey.BiologicalSex)
            {
                NSError error         = null;
                var     biologicalSex = HealthStore.GetBiologicalSex(out error);
                if (error == null)
                {
                    DispatchQueue.MainQueue.DispatchAsync(() => {
                        var dataStore = StateDispatcher <HealthState> .State;

                        HealthStateMutator.MutateBiologicalSex(
                            dataStore, () => GetDisplayableBiologicalSex(biologicalSex.BiologicalSex));

                        StateDispatcher <HealthState> .Refresh();
                    });
                }
            }
        }