Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
b6f4e31
[docs] Document ATTrackingManagerAuthorizationStatus
rolfbjarne Nov 27, 2026
2847a65
[docs] Document BGContinuedProcessingTaskRequestSubmissionStrategy
rolfbjarne Nov 27, 2026
3f847ab
[docs] Document BGContinuedProcessingTaskRequestResources
rolfbjarne Nov 27, 2026
e1cbcbb
[docs] Document BGTaskSchedulerErrorCode
rolfbjarne Nov 27, 2026
ca9cf23
[docs] Document CXErrorCodeNotificationServiceExtensionError
rolfbjarne Nov 27, 2026
5f6687a
[docs] Document CXTranslationEngine
rolfbjarne Nov 27, 2026
a5cd004
[docs] Document CLSProgressReportingCapabilityKind
rolfbjarne Nov 27, 2026
1d2e09a
[docs] Document CBConnectionEvent
rolfbjarne Nov 27, 2026
130aaf5
[docs] Document CBCentralManagerFeature
rolfbjarne Nov 27, 2026
e5b31bc
[docs] Document CBManagerAuthorization
rolfbjarne Nov 27, 2026
74891a7
[docs] Document EPDeveloperToolStatus
rolfbjarne Nov 27, 2026
6724c98
[docs] Document EPError
rolfbjarne Nov 27, 2026
82a5f4e
[docs] Document GSSyncState
rolfbjarne Nov 27, 2026
e178176
[docs] Document HMHomeManagerAuthorizationStatus
rolfbjarne Nov 27, 2026
4361515
[docs] Document LPErrorCode
rolfbjarne Nov 27, 2026
1b61bd0
[docs] Document LARightState
rolfbjarne Nov 27, 2026
74f75ee
[docs] Document MXErrorCode
rolfbjarne Nov 27, 2026
47a2c56
[docs] Document SCNLightProbeType
rolfbjarne Nov 27, 2026
e407834
[docs] Document SCNLightProbeUpdateType
rolfbjarne Nov 27, 2026
7ecbaab
[docs] Document SCNLightAreaType
rolfbjarne Nov 27, 2026
17801c1
[docs] Document SCSensitiveContentType
rolfbjarne Nov 27, 2026
097ff98
[docs] Document SCSensitivityAnalysisPolicy
rolfbjarne Nov 27, 2026
d1abce0
[docs] Document SCVideoStreamAnalyzerStreamDirection
rolfbjarne Nov 27, 2026
ff2fb59
[docs] Document SMAppServiceStatus
rolfbjarne Nov 27, 2026
48c3a09
[docs] Document SNErrorCode
rolfbjarne Nov 27, 2026
498c53a
[docs] Document SNTimeDurationConstraintType
rolfbjarne Nov 27, 2026
adbcdff
[docs] Document SNClassifierIdentifier
rolfbjarne Nov 27, 2026
c8a6303
[docs] Document SFSpeechErrorCode
rolfbjarne Nov 27, 2026
501e874
[docs] Document UNNotificationInterruptionLevel
rolfbjarne Nov 27, 2026
d5d74a5
[docs] Document LACompanionType
rolfbjarne Nov 27, 2026
e218003
[docs] Document TVCaptionButtonViewMotionDirection
rolfbjarne Nov 27, 2026
1a3d30f
[docs] Document TVMediaItemContentTextTransform
rolfbjarne Nov 27, 2026
6deb27c
[docs] Document HMHomeManagerAuthorizationStatus fix Determined
rolfbjarne Nov 27, 2026
419e307
[docs] Address review feedback on enum docs
rolfbjarne Nov 27, 2026
cebf820
[docs] Address second review round on enum docs
rolfbjarne Nov 27, 2026
e840bb2
[docs] Clarify ATTrackingManagerAuthorizationStatus.NotDetermined
rolfbjarne Nov 27, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/BackgroundTasks/Enums.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,19 @@

namespace BackgroundTasks {

/// <summary>Enumerates the errors that can occur when scheduling a background task.</summary>
[NoMac]
[MacCatalyst (13, 1)]
[Native]
[ErrorDomain ("BGTaskSchedulerErrorDomain")]
public enum BGTaskSchedulerErrorCode : long {
/// <summary>The app or extension can't schedule background work. For example, the user disabled background refresh, the app runs in the simulator, or the extension type can't schedule background tasks.</summary>
Unavailable = 1,
/// <summary>There are too many pending tasks of the requested type. Cancel some existing requests and submit the request again.</summary>
TooManyPendingTaskRequests = 2,
/// <summary>The app isn't permitted to schedule the task. For example, the app doesn't declare the required background mode or the task identifier in its Info.plist, the task asks for unavailable resources, or the user denied background launches for the app.</summary>
NotPermitted = 3,
/// <summary>The system couldn't run a continued processing task request immediately. The system only returns this error when the request uses the <see cref="BGContinuedProcessingTaskRequestSubmissionStrategy.Fail" /> strategy.</summary>
ImmediateRunIneligible = 4,
}
}
10 changes: 10 additions & 0 deletions src/CoreBluetooth/Enums.cs
Original file line number Diff line number Diff line change
Expand Up @@ -255,29 +255,39 @@ public enum CBPeripheralManagerConnectionLatency : long {
High,
}

/// <summary>Enumerates the connection events of a peripheral.</summary>
[MacCatalyst (13, 1)]
[Native]
public enum CBConnectionEvent : long {
/// <summary>The peripheral disconnected.</summary>
Disconnected = 0,
/// <summary>The peripheral connected.</summary>
Connected = 1,
}

/// <summary>Enumerates the device-specific features of a central manager.</summary>
[Flags, NoMac]
[MacCatalyst (13, 1)]
[Native]
public enum CBCentralManagerFeature : ulong {
/// <summary>The hardware supports extended scans and enhanced connection creation.</summary>
ExtendedScanAndConnect = 1uL << 0,
/// <summary>The hardware and region support channel sounding.</summary>
[NoTV, iOS (27, 0), MacCatalyst (27, 0)]
ChannelSounding = 1uL << 10,
}

/// <summary>Enumerates the user's Bluetooth authorization status for the app.</summary>
[MacCatalyst (13, 1)]
[Native]
public enum CBManagerAuthorization : long {
/// <summary>The user hasn't made a choice about this app using Bluetooth yet.</summary>
NotDetermined = 0,
/// <summary>The app isn't authorized to use Bluetooth, and the user can't change that. For example, parental controls might be active.</summary>
Restricted,
/// <summary>The user denied this app the use of Bluetooth.</summary>
Denied,
/// <summary>The user authorized this app to always use Bluetooth.</summary>
AllowedAlways,
}
}
4 changes: 4 additions & 0 deletions src/HomeKit/HMEnums.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1628,12 +1628,16 @@ public enum HMSignificantEvent {
Sunset,
}

/// <summary>Enumerates the authorization status of an app to access home data.</summary>
[NoMac, MacCatalyst (14, 0)]
[Flags]
[Native]
public enum HMHomeManagerAuthorizationStatus : ulong {
/// <summary>The user has decided whether the app can access home data.</summary>
Determined = 1 << 0,
/// <summary>The system currently restricts access to home data.</summary>
Restricted = 1 << 1,
/// <summary>The app is authorized to access home data.</summary>
Authorized = 1 << 2,
}

Expand Down
5 changes: 5 additions & 0 deletions src/LocalAuthentication/LAEnums.cs
Original file line number Diff line number Diff line change
Expand Up @@ -128,12 +128,17 @@ public enum LAAccessControlOperation : long {
UseKeyKeyExchange,
}

/// <summary>Enumerates the states of a right.</summary>
[iOS (16, 0), MacCatalyst (16, 0), NoTV]
[Native]
public enum LARightState : long {
/// <summary>The right hasn't been evaluated yet. This is the initial state of a right.</summary>
Unknown = 0,
/// <summary>The system is evaluating the requirements. This happens after the app requests authorization, but before the user grants the right.</summary>
Authorizing = 1,
/// <summary>The right was authorized.</summary>
Authorized = 2,
/// <summary>The right wasn't authorized. For example, the requirements weren't met or the user rejected the request.</summary>
NotAuthorized = 3,
}
}
7 changes: 7 additions & 0 deletions src/MetricKit/MXEnums.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,22 @@
using CoreFoundation;

namespace MetricKit {
/// <summary>Enumerates the errors that MetricKit reports for launch tasks.</summary>
[NoMac, iOS (16, 0), MacCatalyst (16, 0), NoTV]
[ErrorDomain ("MXErrorDomain")]
[Native]
public enum MXErrorCode : long {
/// <summary>The task identifier is null or longer than 128 characters.</summary>
InvalidId,
/// <summary>The app exceeded the maximum number of tasks.</summary>
MaxCount,
/// <summary>The app started the task too late.</summary>
PastDeadline,
/// <summary>A task with the same identifier has already been started.</summary>
Duplicated,
/// <summary>The task hasn't been started, or it has already finished.</summary>
Unknown,
/// <summary>MetricKit failed internally.</summary>
InternalFailure,
}
}
9 changes: 9 additions & 0 deletions src/SceneKit/Defs.cs
Original file line number Diff line number Diff line change
Expand Up @@ -622,24 +622,33 @@ public enum SCNNodeFocusBehavior : long {
Focusable,
}

/// <summary>Enumerates the kinds of light probes.</summary>
[MacCatalyst (13, 1)]
[Native]
public enum SCNLightProbeType : long {
/// <summary>The probe bakes and stores spherical harmonics. This is the default.</summary>
Irradiance = 0,
/// <summary>The probe captures radiance (reflections) in its extents, either by capturing the scene or from a cube texture the app provides.</summary>
Radiance = 1,
}

/// <summary>Enumerates how often a light probe updates.</summary>
[MacCatalyst (13, 1)]
[Native]
public enum SCNLightProbeUpdateType : long {
/// <summary>SceneKit never updates the probe automatically. For example, the probe was baked in the Xcode scene editor, or it uses a provided environment.</summary>
Never = 0,
/// <summary>SceneKit updates the probe automatically every frame.</summary>
Realtime = 1,
}

/// <summary>Enumerates the shapes of an area light.</summary>
[MacCatalyst (13, 1)]
[Native]
public enum SCNLightAreaType : long {
/// <summary>The light is a rectangle. This is the default.</summary>
Rectangle = 1,
/// <summary>The light is a polygon.</summary>
Polygon = 4,
}

Expand Down
5 changes: 5 additions & 0 deletions src/apptrackingtransparency.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,18 @@

namespace AppTrackingTransparency {

/// <summary>Enumerates the user's tracking authorization status for the app.</summary>
[iOS (14, 0), TV (14, 0)]
[Introduced (PlatformName.MacCatalyst, 14, 0)]
[Native]
public enum ATTrackingManagerAuthorizationStatus : ulong {
/// <summary>The user hasn't made a tracking authorization decision. This is the case before the app asks, and also when the user selects the additional-information button in the expanded-consent prompt.</summary>
NotDetermined = 0,
/// <summary>Tracking authorization is restricted on this device, and the user can't change it.</summary>
Restricted = 1,
/// <summary>The user denied tracking authorization.</summary>
Denied = 2,
/// <summary>The user authorized tracking.</summary>
Authorized = 3,
}

Expand Down
6 changes: 6 additions & 0 deletions src/backgroundtasks.cs
Original file line number Diff line number Diff line change
Expand Up @@ -169,18 +169,24 @@ interface BGContinuedProcessingTaskRequest {
NativeHandle Constructor (string identifier, string title, string subtitle);
}

/// <summary>Enumerates how the scheduler handles a continued processing task request that can't run immediately.</summary>
[NoTV, NoMacCatalyst, NoMac, iOS (26, 0)]
[Native]
public enum BGContinuedProcessingTaskRequestSubmissionStrategy : long {
/// <summary>Fail the submission if the scheduler has no capacity for the request, or if the system is under heavy load and can't run it immediately.</summary>
Fail,
/// <summary>Add the request to the back of a queue if it can't run immediately. The system cancels queued requests when the user removes the app from the app switcher.</summary>
Queue,
}

/// <summary>Enumerates the extra system resources a continued processing task request can ask for.</summary>
[NoTV, NoMacCatalyst, NoMac, iOS (26, 0)]
[Native]
[Flags]
public enum BGContinuedProcessingTaskRequestResources : long {
/// <summary>No special system resources are required. The scheduler assumes the default resources, which allow background CPU and network access.</summary>
Default = 0x0,
/// <summary>The task needs background GPU access. The system rejects the request if the app lacks the required entitlement. Not all devices support background GPU execution, and the system doesn't guarantee that the task runs when the GPU is heavily contended.</summary>
Gpu = (1L << 0),
}

Expand Down
7 changes: 7 additions & 0 deletions src/callkit.cs
Original file line number Diff line number Diff line change
Expand Up @@ -109,13 +109,17 @@ public enum CXErrorCodeCallDirectoryManagerError : long {
UnexpectedIncrementalRemoval = 8,
}

/// <summary>Enumerates the errors that CallKit reports to a notification service extension.</summary>
[iOS (14, 5), NoTV, NoMac]
[Introduced (PlatformName.MacCatalyst, 14, 5)]
[ErrorDomain ("CXErrorDomainNotificationServiceExtension")]
[Native]
public enum CXErrorCodeNotificationServiceExtensionError : long {
/// <summary>An unknown error occurred.</summary>
Unknown = 0,
/// <summary>The request came from a process that isn't a valid client, such as one that isn't a notification service extension.</summary>
InvalidClientProcess = 1,
/// <summary>The extension doesn't have the notification filtering entitlement.</summary>
MissingNotificationFilteringEntitlement = 2,
}

Expand Down Expand Up @@ -934,10 +938,13 @@ interface CXSetTranslatingCallAction : NSSecureCoding {
void Fulfill (CXTranslationEngine translationEngine);
}

/// <summary>Enumerates the translation engines that can translate a call.</summary>
[iOS (26, 0), NoMacCatalyst, NoMac]
[Native]
public enum CXTranslationEngine : long {
/// <summary>The system's translation engine translates the call.</summary>
Default,
/// <summary>The app's own translation engine translates the call.</summary>
Custom,
}
}
6 changes: 6 additions & 0 deletions src/classkit.cs
Original file line number Diff line number Diff line change
Expand Up @@ -137,14 +137,20 @@ enum CLSContextTopic {
}


/// <summary>Enumerates the kinds of progress an app can report.</summary>
[Introduced (PlatformName.MacCatalyst, 14, 0)]
[NoTV, iOS (14, 0)]
[Native]
public enum CLSProgressReportingCapabilityKind : long {
/// <summary>The app reports the time spent. Every context has this capability by default.</summary>
Duration = 0,
/// <summary>The app reports a progress percentage.</summary>
Percent,
/// <summary>The app reports a binary value, such as true or false, pass or fail, or correct or incorrect.</summary>
Binary,
/// <summary>The app reports a discrete value.</summary>
Quantity,
/// <summary>The app reports a score.</summary>
Score,
}

Expand Down
8 changes: 8 additions & 0 deletions src/executionpolicy.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,28 @@

namespace ExecutionPolicy {

/// <summary>Enumerates whether a process has developer tool privileges.</summary>
[MacCatalyst (16, 0)]
[Native]
public enum EPDeveloperToolStatus : long {
/// <summary>The user hasn't decided whether the process gets developer tool privileges.</summary>
NotDetermined = 0,
/// <summary>The process can't get developer tool privileges, and the user can't change that.</summary>
Restricted,
/// <summary>The user denied developer tool privileges to the process.</summary>
Denied,
/// <summary>The process has developer tool privileges.</summary>
Authorized,
}

/// <summary>Enumerates the errors that the ExecutionPolicy framework reports.</summary>
[MacCatalyst (16, 0)]
[Native]
[ErrorDomain ("EPErrorDomain")]
public enum EPError : long {
/// <summary>A general error occurred.</summary>
Generic = 1,
/// <summary>The process isn't a developer tool.</summary>
NotADeveloperTool,
}

Expand Down
8 changes: 8 additions & 0 deletions src/gamesave.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,23 @@
#endif

namespace GameSave {
/// <summary>Enumerates the sync states of a synced directory.</summary>
[iOS (26, 0), Mac (26, 0), MacCatalyst (26, 0)]
[Native]
public enum GSSyncState : long {
/// <summary>The directory is fully synced and ready to use.</summary>
Ready,
/// <summary>The directory is available locally, but it isn't fully synced because the device is offline.</summary>
Offline,
/// <summary>The directory is local-only and isn't synced to iCloud.</summary>
Local,
/// <summary>The directory is syncing and isn't ready yet.</summary>
Syncing,
/// <summary>The directory has conflicts with the cloud that the game needs to resolve.</summary>
Conflicted,
/// <summary>The directory is in an error state and can't be used.</summary>
Error,
/// <summary>The directory is closed.</summary>
Closed,
}

Expand Down
6 changes: 6 additions & 0 deletions src/linkpresentation.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,21 @@

namespace LinkPresentation {

/// <summary>Enumerates the errors that can occur when fetching link metadata.</summary>
[ErrorDomain ("LPErrorDomain")]
[TV (14, 0)]
[MacCatalyst (13, 1)]
[Native]
public enum LPErrorCode : long {
/// <summary>An unknown error occurred.</summary>
Unknown = 1,
/// <summary>Fetching the metadata failed.</summary>
MetadataFetchFailed,
/// <summary>The client canceled the metadata fetch.</summary>
MetadataFetchCancelled,
/// <summary>The metadata fetch took longer than allowed.</summary>
MetadataFetchTimedOut,
/// <summary>System policies don't allow the metadata fetch.</summary>
MetadataFetchNotAllowed,
}

Expand Down
5 changes: 5 additions & 0 deletions src/localauthentication.cs
Original file line number Diff line number Diff line change
Expand Up @@ -377,15 +377,20 @@ interface LASecret {
void LoadData (LASecretCompletionHandler handler);
}

/// <summary>Enumerates the kinds of companion devices that can authenticate the user.</summary>
[Flags]
[Native]
[Mac (15, 0), iOS (18, 0), MacCatalyst (18, 0), NoTV]
enum LACompanionType : long {
/// <summary>No companion device.</summary>
None = 0,
/// <summary>A paired Apple Watch.</summary>
[NoiOS, NoTV, NoMacCatalyst]
Watch = 1 << 0,
/// <summary>A paired Mac.</summary>
[NoMac, NoTV]
Mac = 1 << 1,
/// <summary>A paired Apple Vision Pro.</summary>
[NoMac, NoTV]
Vision = 1 << 2,
}
Expand Down
10 changes: 10 additions & 0 deletions src/sensitivecontentanalysis.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,14 @@
using VideoToolbox;

namespace SensitiveContentAnalysis {
/// <summary>Enumerates the types of sensitive content.</summary>
[NoTV, iOS (27, 0), Mac (27, 0), MacCatalyst (27, 0)]
public enum SCSensitiveContentType {
/// <summary>The content is nude or sexually explicit.</summary>
[Field ("SCSensitiveContentTypeSexuallyExplicit")]
SexuallyExplicit,

/// <summary>The content contains graphic violence or gore.</summary>
[Field ("SCSensitiveContentTypeGoreOrViolence")]
GoreOrViolence,
}
Expand Down Expand Up @@ -46,11 +49,15 @@ interface SCSensitivityAnalysis {
bool ShouldMuteAudio { get; }
}

/// <summary>Enumerates the sensitivity analysis policies on the device, which determine the kind of intervention to show.</summary>
[NoTV, iOS (17, 0), MacCatalyst (17, 0)]
[Native]
public enum SCSensitivityAnalysisPolicy : long {
/// <summary>No feature that requires sensitivity analysis is enabled, so analysis is disabled.</summary>
Disabled = 0,
/// <summary>Sensitivity analysis is enabled through Sensitive Content Warning in Settings. Apps are expected to show brief, inline UI, such as a simple button to show the content.</summary>
SimpleInterventions = 1,
/// <summary>Sensitivity analysis is enabled for children or teens through Communication Safety in Screen Time. Apps are expected to show more descriptive UI that explains the potential risks.</summary>
DescriptiveInterventions = 2,
}

Expand All @@ -73,10 +80,13 @@ interface SCSensitivityAnalyzer {
NSProgress AnalyzeVideo (NSUrl fileUrl, Action<SCSensitivityAnalysis, NSError> completionHandler);
}

/// <summary>Enumerates the directions of a video stream that a video stream analyzer analyzes.</summary>
[NoTV, NoMacCatalyst, NoMac, iOS (26, 0)]
[Native]
public enum SCVideoStreamAnalyzerStreamDirection : long {
/// <summary>The stream is sent to another device, such as the stream from this device's camera.</summary>
Outgoing = 1,
/// <summary>The stream comes from another device, such as one received over the network from another device's camera.</summary>
Incoming = 2,
}

Expand Down
Loading
Loading