objc2_speech/generated/
SFSpeechRecognitionMetadata.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ffi::*;
4use core::ptr::NonNull;
5use objc2::__framework_prelude::*;
6use objc2_foundation::*;
7
8use crate::*;
9
10extern_class!(
11    /// [Apple's documentation](https://developer.apple.com/documentation/speech/sfspeechrecognitionmetadata?language=objc)
12    #[unsafe(super(NSObject))]
13    #[derive(Debug, PartialEq, Eq, Hash)]
14    pub struct SFSpeechRecognitionMetadata;
15);
16
17unsafe impl NSCoding for SFSpeechRecognitionMetadata {}
18
19unsafe impl NSCopying for SFSpeechRecognitionMetadata {}
20
21unsafe impl CopyingHelper for SFSpeechRecognitionMetadata {
22    type Result = Self;
23}
24
25unsafe impl NSObjectProtocol for SFSpeechRecognitionMetadata {}
26
27unsafe impl NSSecureCoding for SFSpeechRecognitionMetadata {}
28
29impl SFSpeechRecognitionMetadata {
30    extern_methods!(
31        #[unsafe(method(speakingRate))]
32        #[unsafe(method_family = none)]
33        pub unsafe fn speakingRate(&self) -> c_double;
34
35        #[unsafe(method(averagePauseDuration))]
36        #[unsafe(method_family = none)]
37        pub unsafe fn averagePauseDuration(&self) -> NSTimeInterval;
38
39        #[unsafe(method(speechStartTimestamp))]
40        #[unsafe(method_family = none)]
41        pub unsafe fn speechStartTimestamp(&self) -> NSTimeInterval;
42
43        #[unsafe(method(speechDuration))]
44        #[unsafe(method_family = none)]
45        pub unsafe fn speechDuration(&self) -> NSTimeInterval;
46
47        #[cfg(feature = "SFVoiceAnalytics")]
48        #[unsafe(method(voiceAnalytics))]
49        #[unsafe(method_family = none)]
50        pub unsafe fn voiceAnalytics(&self) -> Option<Retained<SFVoiceAnalytics>>;
51    );
52}
53
54/// Methods declared on superclass `NSObject`.
55impl SFSpeechRecognitionMetadata {
56    extern_methods!(
57        #[unsafe(method(init))]
58        #[unsafe(method_family = init)]
59        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
60
61        #[unsafe(method(new))]
62        #[unsafe(method_family = new)]
63        pub unsafe fn new() -> Retained<Self>;
64    );
65}