objc2_web_kit/generated/
DOMHTMLCollection.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/webkit/domhtmlcollection?language=objc)
12    #[unsafe(super(DOMObject, WebScriptObject, NSObject))]
13    #[derive(Debug, PartialEq, Eq, Hash)]
14    #[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
15    #[deprecated]
16    pub struct DOMHTMLCollection;
17);
18
19#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
20extern_conformance!(
21    unsafe impl NSCopying for DOMHTMLCollection {}
22);
23
24#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
25unsafe impl CopyingHelper for DOMHTMLCollection {
26    type Result = Self;
27}
28
29#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
30extern_conformance!(
31    unsafe impl NSObjectProtocol for DOMHTMLCollection {}
32);
33
34#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
35impl DOMHTMLCollection {
36    extern_methods!(
37        #[deprecated]
38        #[unsafe(method(length))]
39        #[unsafe(method_family = none)]
40        pub unsafe fn length(&self) -> c_uint;
41
42        #[cfg(feature = "DOMNode")]
43        #[deprecated]
44        #[unsafe(method(item:))]
45        #[unsafe(method_family = none)]
46        pub unsafe fn item(&self, index: c_uint) -> Option<Retained<DOMNode>>;
47
48        #[cfg(feature = "DOMNode")]
49        #[deprecated]
50        #[unsafe(method(namedItem:))]
51        #[unsafe(method_family = none)]
52        pub unsafe fn namedItem(&self, name: Option<&NSString>) -> Option<Retained<DOMNode>>;
53
54        #[cfg(feature = "DOMNodeList")]
55        #[unsafe(method(tags:))]
56        #[unsafe(method_family = none)]
57        pub unsafe fn tags(&self, name: Option<&NSString>) -> Option<Retained<DOMNodeList>>;
58    );
59}
60
61/// Methods declared on superclass `DOMObject`.
62#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
63impl DOMHTMLCollection {
64    extern_methods!(
65        #[deprecated]
66        #[unsafe(method(init))]
67        #[unsafe(method_family = init)]
68        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
69    );
70}
71
72/// Methods declared on superclass `NSObject`.
73#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
74impl DOMHTMLCollection {
75    extern_methods!(
76        #[unsafe(method(new))]
77        #[unsafe(method_family = new)]
78        pub unsafe fn new() -> Retained<Self>;
79    );
80}