objc2_ar_kit/generated/
ARRaycastResult.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ptr::NonNull;
4#[cfg(feature = "objc2")]
5use objc2::__framework_prelude::*;
6
7use crate::*;
8
9#[cfg(feature = "objc2")]
10extern_class!(
11    /// Result of a raycast on a single target.
12    ///
13    /// See also [Apple's documentation](https://developer.apple.com/documentation/arkit/arraycastresult?language=objc)
14    #[unsafe(super(NSObject))]
15    #[derive(Debug, PartialEq, Eq, Hash)]
16    #[cfg(feature = "objc2")]
17    pub struct ARRaycastResult;
18);
19
20#[cfg(feature = "objc2")]
21unsafe impl NSObjectProtocol for ARRaycastResult {}
22
23#[cfg(feature = "objc2")]
24impl ARRaycastResult {
25    extern_methods!(
26        #[cfg(feature = "ARRaycastQuery")]
27        /// Type of the target where the ray terminated.
28        #[unsafe(method(target))]
29        #[unsafe(method_family = none)]
30        pub unsafe fn target(&self) -> ARRaycastTarget;
31
32        #[cfg(feature = "ARRaycastQuery")]
33        /// Alignment of the target.
34        #[unsafe(method(targetAlignment))]
35        #[unsafe(method_family = none)]
36        pub unsafe fn targetAlignment(&self) -> ARRaycastTargetAlignment;
37
38        #[cfg(feature = "ARAnchor")]
39        /// The anchor that the ray intersected.
40        ///
41        ///
42        /// In case of an existing plane target, an anchor will always be provided. In case of an estimated plane target,
43        /// an anchor may be provided if the ray hit an existing plane.
44        #[unsafe(method(anchor))]
45        #[unsafe(method_family = none)]
46        pub unsafe fn anchor(&self) -> Option<Retained<ARAnchor>>;
47
48        #[unsafe(method(init))]
49        #[unsafe(method_family = init)]
50        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
51
52        #[unsafe(method(new))]
53        #[unsafe(method_family = new)]
54        pub unsafe fn new(&self) -> Retained<Self>;
55    );
56}
57
58/// Methods declared on superclass `NSObject`.
59#[cfg(feature = "objc2")]
60impl ARRaycastResult {
61    extern_methods!(
62        #[unsafe(method(new))]
63        #[unsafe(method_family = new)]
64        pub unsafe fn new_class() -> Retained<Self>;
65    );
66}