objc2_metric_kit/generated/
MXSignpostMetric.rs1use core::ptr::NonNull;
4use objc2::__framework_prelude::*;
5use objc2_foundation::*;
6
7use crate::*;
8
9extern_class!(
10 #[unsafe(super(NSObject))]
20 #[derive(Debug, PartialEq, Eq, Hash)]
21 pub struct MXSignpostIntervalData;
22);
23
24extern_conformance!(
25 unsafe impl NSCoding for MXSignpostIntervalData {}
26);
27
28extern_conformance!(
29 unsafe impl NSObjectProtocol for MXSignpostIntervalData {}
30);
31
32extern_conformance!(
33 unsafe impl NSSecureCoding for MXSignpostIntervalData {}
34);
35
36impl MXSignpostIntervalData {
37 extern_methods!(
38 #[cfg(feature = "MXHistogram")]
39 #[unsafe(method(histogrammedSignpostDuration))]
41 #[unsafe(method_family = none)]
42 pub unsafe fn histogrammedSignpostDuration(&self) -> Retained<MXHistogram<NSUnitDuration>>;
43
44 #[unsafe(method(cumulativeCPUTime))]
48 #[unsafe(method_family = none)]
49 pub unsafe fn cumulativeCPUTime(&self) -> Option<Retained<NSMeasurement<NSUnitDuration>>>;
50
51 #[cfg(feature = "MXAverage")]
52 #[unsafe(method(averageMemory))]
56 #[unsafe(method_family = none)]
57 pub unsafe fn averageMemory(&self)
58 -> Option<Retained<MXAverage<NSUnitInformationStorage>>>;
59
60 #[unsafe(method(cumulativeLogicalWrites))]
64 #[unsafe(method_family = none)]
65 pub unsafe fn cumulativeLogicalWrites(
66 &self,
67 ) -> Option<Retained<NSMeasurement<NSUnitInformationStorage>>>;
68
69 #[unsafe(method(cumulativeHitchTimeRatio))]
73 #[unsafe(method_family = none)]
74 pub unsafe fn cumulativeHitchTimeRatio(&self) -> Option<Retained<NSMeasurement<NSUnit>>>;
75 );
76}
77
78impl MXSignpostIntervalData {
80 extern_methods!(
81 #[unsafe(method(init))]
82 #[unsafe(method_family = init)]
83 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
84
85 #[unsafe(method(new))]
86 #[unsafe(method_family = new)]
87 pub unsafe fn new() -> Retained<Self>;
88 );
89}
90
91extern_class!(
92 #[unsafe(super(MXMetric, NSObject))]
98 #[derive(Debug, PartialEq, Eq, Hash)]
99 #[cfg(feature = "MXMetric")]
100 pub struct MXSignpostMetric;
101);
102
103#[cfg(feature = "MXMetric")]
104extern_conformance!(
105 unsafe impl NSCoding for MXSignpostMetric {}
106);
107
108#[cfg(feature = "MXMetric")]
109extern_conformance!(
110 unsafe impl NSObjectProtocol for MXSignpostMetric {}
111);
112
113#[cfg(feature = "MXMetric")]
114extern_conformance!(
115 unsafe impl NSSecureCoding for MXSignpostMetric {}
116);
117
118#[cfg(feature = "MXMetric")]
119impl MXSignpostMetric {
120 extern_methods!(
121 #[unsafe(method(signpostName))]
123 #[unsafe(method_family = none)]
124 pub unsafe fn signpostName(&self) -> Retained<NSString>;
125
126 #[unsafe(method(signpostCategory))]
128 #[unsafe(method_family = none)]
129 pub unsafe fn signpostCategory(&self) -> Retained<NSString>;
130
131 #[unsafe(method(signpostIntervalData))]
135 #[unsafe(method_family = none)]
136 pub unsafe fn signpostIntervalData(&self) -> Option<Retained<MXSignpostIntervalData>>;
137
138 #[unsafe(method(totalCount))]
140 #[unsafe(method_family = none)]
141 pub unsafe fn totalCount(&self) -> NSUInteger;
142 );
143}
144
145#[cfg(feature = "MXMetric")]
147impl MXSignpostMetric {
148 extern_methods!(
149 #[unsafe(method(init))]
150 #[unsafe(method_family = init)]
151 pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
152
153 #[unsafe(method(new))]
154 #[unsafe(method_family = new)]
155 pub unsafe fn new() -> Retained<Self>;
156 );
157}