Example #1
0
        static internal NSString ToKey(HKCategoryTypeIdentifier kind)
        {
            switch (kind)
            {
            case HKCategoryTypeIdentifier.SleepAnalysis:
                return(HKCategoryTypeIdentifierKey.SleepAnalysis);

            case HKCategoryTypeIdentifier.AppleStandHour:
                return(HKCategoryTypeIdentifierKey.AppleStandHour);

            case HKCategoryTypeIdentifier.CervicalMucusQuality:
                return(HKCategoryTypeIdentifierKey.CervicalMucusQuality);

            case HKCategoryTypeIdentifier.OvulationTestResult:
                return(HKCategoryTypeIdentifierKey.OvulationTestResult);

            case HKCategoryTypeIdentifier.MenstrualFlow:
                return(HKCategoryTypeIdentifierKey.MenstrualFlow);

            case HKCategoryTypeIdentifier.IntermenstrualBleeding:
                return(HKCategoryTypeIdentifierKey.IntermenstrualBleeding);

            case HKCategoryTypeIdentifier.SexualActivity:
                return(HKCategoryTypeIdentifierKey.SexualActivity);

            case HKCategoryTypeIdentifier.MindfulSession:
                return(HKCategoryTypeIdentifierKey.MindfulSession);
            }
            return(null);
        }
Example #2
0
 internal static NSString ToKey(HKCategoryTypeIdentifier kind)
 {
     switch (kind){
     case HKCategoryTypeIdentifier.SleepAnalysis:
         return HKCategoryTypeIdentifierKey.SleepAnalysis;
     case HKCategoryTypeIdentifier.AppleStandHour:
         return HKCategoryTypeIdentifierKey.AppleStandHour;
     case HKCategoryTypeIdentifier.CervicalMucusQuality:
         return HKCategoryTypeIdentifierKey.CervicalMucusQuality;
     case HKCategoryTypeIdentifier.OvulationTestResult:
         return HKCategoryTypeIdentifierKey.OvulationTestResult;
     case HKCategoryTypeIdentifier.MenstrualFlow:
         return HKCategoryTypeIdentifierKey.MenstrualFlow;
     case HKCategoryTypeIdentifier.IntermenstrualBleeding:
         return HKCategoryTypeIdentifierKey.IntermenstrualBleeding;
     case HKCategoryTypeIdentifier.SexualActivity:
         return HKCategoryTypeIdentifierKey.SexualActivity;
     }
     return null;
 }
Example #3
0
 public static HKCategoryType Create(HKCategoryTypeIdentifier kind)
 {
     return HKObjectType.GetCategoryType (ToKey (kind));
 }
Example #4
0
 public static HKCategoryType Create(HKCategoryTypeIdentifier kind)
 {
     return(HKObjectType.GetCategoryType(ToKey(kind)));
 }
Example #5
0
 public static HKCategoryType Create(HKCategoryTypeIdentifier kind)
 {
     return(HKObjectType.GetCategoryType(kind.GetConstant()));
 }
Example #6
0
 public HealthKitData(HKCategoryTypeIdentifier identifier)
 {
     CategoryTypeIdentifier = identifier;
     HKType     = HKTypes.Category;
     Permission = HKCategoryType.Create(identifier);
 }