objc2_metal/generated/
MTLDeviceCertification.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use objc2::__framework_prelude::*;
4use objc2_foundation::*;
5
6use crate::*;
7
8/// [Apple's documentation](https://developer.apple.com/documentation/metal/nsdevicecertification?language=objc)
9// NS_TYPED_ENUM
10pub type NSDeviceCertification = NSInteger;
11
12extern "C" {
13    /// [Apple's documentation](https://developer.apple.com/documentation/metal/nsdevicecertificationiphoneperformancegaming?language=objc)
14    pub static NSDeviceCertificationiPhonePerformanceGaming: NSDeviceCertification;
15}
16
17/// [Apple's documentation](https://developer.apple.com/documentation/metal/nsprocessperformanceprofile?language=objc)
18// NS_TYPED_ENUM
19pub type NSProcessPerformanceProfile = NSInteger;
20
21extern "C" {
22    /// [Apple's documentation](https://developer.apple.com/documentation/metal/nsprocessperformanceprofiledefault?language=objc)
23    pub static NSProcessPerformanceProfileDefault: NSProcessPerformanceProfile;
24}
25
26extern "C" {
27    /// [Apple's documentation](https://developer.apple.com/documentation/metal/nsprocessperformanceprofilesustained?language=objc)
28    pub static NSProcessPerformanceProfileSustained: NSProcessPerformanceProfile;
29}
30
31extern "C" {
32    /// [Apple's documentation](https://developer.apple.com/documentation/metal/nsprocessinfoperformanceprofiledidchangenotification?language=objc)
33    pub static NSProcessInfoPerformanceProfileDidChangeNotification:
34        Option<&'static NSNotificationName>;
35}
36
37mod private_NSProcessInfoNSDeviceCertification {
38    pub trait Sealed {}
39}
40
41/// Category "NSDeviceCertification" on [`NSProcessInfo`].
42#[doc(alias = "NSDeviceCertification")]
43pub unsafe trait NSProcessInfoNSDeviceCertification:
44    ClassType + Sized + private_NSProcessInfoNSDeviceCertification::Sealed
45{
46    extern_methods!(
47        #[unsafe(method(isDeviceCertifiedFor:))]
48        #[unsafe(method_family = none)]
49        fn isDeviceCertifiedFor(&self, performance_tier: NSDeviceCertification) -> bool;
50
51        #[unsafe(method(hasPerformanceProfile:))]
52        #[unsafe(method_family = none)]
53        fn hasPerformanceProfile(&self, performance_profile: NSProcessPerformanceProfile) -> bool;
54    );
55}
56
57impl private_NSProcessInfoNSDeviceCertification::Sealed for NSProcessInfo {}
58unsafe impl NSProcessInfoNSDeviceCertification for NSProcessInfo {}