1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use objc2::__framework_prelude::*;
use objc2_foundation::*;

use crate::*;

extern_class!(
    #[derive(Debug, PartialEq, Eq, Hash)]
    #[deprecated]
    pub struct WebDataSource;

    unsafe impl ClassType for WebDataSource {
        type Super = NSObject;
        type Mutability = InteriorMutable;
    }
);

unsafe impl NSObjectProtocol for WebDataSource {}

extern_methods!(
    unsafe impl WebDataSource {
        #[deprecated]
        #[method_id(@__retain_semantics Init initWithRequest:)]
        pub unsafe fn initWithRequest(
            this: Allocated<Self>,
            request: Option<&NSURLRequest>,
        ) -> Option<Retained<Self>>;

        #[deprecated]
        #[method_id(@__retain_semantics Other data)]
        pub unsafe fn data(&self) -> Retained<NSData>;

        #[cfg(feature = "WebDocument")]
        #[deprecated]
        #[method_id(@__retain_semantics Other representation)]
        pub unsafe fn representation(
            &self,
        ) -> Option<Retained<ProtocolObject<dyn WebDocumentRepresentation>>>;

        #[cfg(feature = "WebFrame")]
        #[deprecated]
        #[method_id(@__retain_semantics Other webFrame)]
        pub unsafe fn webFrame(&self) -> Option<Retained<WebFrame>>;

        #[deprecated]
        #[method_id(@__retain_semantics Other initialRequest)]
        pub unsafe fn initialRequest(&self) -> Option<Retained<NSURLRequest>>;

        #[deprecated]
        #[method_id(@__retain_semantics Other request)]
        pub unsafe fn request(&self) -> Option<Retained<NSMutableURLRequest>>;

        #[deprecated]
        #[method_id(@__retain_semantics Other response)]
        pub unsafe fn response(&self) -> Option<Retained<NSURLResponse>>;

        #[deprecated]
        #[method_id(@__retain_semantics Other textEncodingName)]
        pub unsafe fn textEncodingName(&self) -> Retained<NSString>;

        #[deprecated]
        #[method(isLoading)]
        pub unsafe fn isLoading(&self) -> bool;

        #[deprecated]
        #[method_id(@__retain_semantics Other pageTitle)]
        pub unsafe fn pageTitle(&self) -> Retained<NSString>;

        #[deprecated]
        #[method_id(@__retain_semantics Other unreachableURL)]
        pub unsafe fn unreachableURL(&self) -> Option<Retained<NSURL>>;

        #[cfg(feature = "WebArchive")]
        #[deprecated]
        #[method_id(@__retain_semantics Other webArchive)]
        pub unsafe fn webArchive(&self) -> Option<Retained<WebArchive>>;

        #[cfg(feature = "WebResource")]
        #[deprecated]
        #[method_id(@__retain_semantics Other mainResource)]
        pub unsafe fn mainResource(&self) -> Option<Retained<WebResource>>;

        #[deprecated]
        #[method_id(@__retain_semantics Other subresources)]
        pub unsafe fn subresources(&self) -> Retained<NSArray>;

        #[cfg(feature = "WebResource")]
        #[deprecated]
        #[method_id(@__retain_semantics Other subresourceForURL:)]
        pub unsafe fn subresourceForURL(
            &self,
            url: Option<&NSURL>,
        ) -> Option<Retained<WebResource>>;

        #[cfg(feature = "WebResource")]
        #[deprecated]
        #[method(addSubresource:)]
        pub unsafe fn addSubresource(&self, subresource: Option<&WebResource>);
    }
);

extern_methods!(
    /// Methods declared on superclass `NSObject`
    unsafe impl WebDataSource {
        #[method_id(@__retain_semantics Init init)]
        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;

        #[method_id(@__retain_semantics New new)]
        pub unsafe fn new() -> Retained<Self>;
    }
);