objc2_automator/generated/
AMShellScriptAction.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use core::ptr::NonNull;
4use objc2::__framework_prelude::*;
5use objc2_foundation::*;
6
7use crate::*;
8
9extern_class!(
10    /// [Apple's documentation](https://developer.apple.com/documentation/automator/amshellscriptaction?language=objc)
11    #[unsafe(super(AMBundleAction, AMAction, NSObject))]
12    #[derive(Debug, PartialEq, Eq, Hash)]
13    #[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
14    pub struct AMShellScriptAction;
15);
16
17#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
18extern_conformance!(
19    unsafe impl NSCoding for AMShellScriptAction {}
20);
21
22#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
23extern_conformance!(
24    unsafe impl NSCopying for AMShellScriptAction {}
25);
26
27#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
28unsafe impl CopyingHelper for AMShellScriptAction {
29    type Result = Self;
30}
31
32#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
33extern_conformance!(
34    unsafe impl NSObjectProtocol for AMShellScriptAction {}
35);
36
37#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
38extern_conformance!(
39    unsafe impl NSSecureCoding for AMShellScriptAction {}
40);
41
42#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
43impl AMShellScriptAction {
44    extern_methods!(
45        #[unsafe(method(remapLineEndings))]
46        #[unsafe(method_family = none)]
47        pub unsafe fn remapLineEndings(&self) -> bool;
48
49        #[unsafe(method(inputFieldSeparator))]
50        #[unsafe(method_family = none)]
51        pub unsafe fn inputFieldSeparator(&self) -> Retained<NSString>;
52
53        #[unsafe(method(outputFieldSeparator))]
54        #[unsafe(method_family = none)]
55        pub unsafe fn outputFieldSeparator(&self) -> Retained<NSString>;
56    );
57}
58
59/// Methods declared on superclass `AMAction`.
60#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
61impl AMShellScriptAction {
62    extern_methods!(
63        /// # Safety
64        ///
65        /// `dict` generic should be of the correct type.
66        #[unsafe(method(initWithDefinition:fromArchive:))]
67        #[unsafe(method_family = init)]
68        pub unsafe fn initWithDefinition_fromArchive(
69            this: Allocated<Self>,
70            dict: Option<&NSDictionary<NSString, AnyObject>>,
71            archived: bool,
72        ) -> Option<Retained<Self>>;
73
74        #[unsafe(method(initWithContentsOfURL:error:_))]
75        #[unsafe(method_family = init)]
76        pub unsafe fn initWithContentsOfURL_error(
77            this: Allocated<Self>,
78            file_url: &NSURL,
79        ) -> Result<Retained<Self>, Retained<NSError>>;
80    );
81}
82
83/// Methods declared on superclass `NSObject`.
84#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
85impl AMShellScriptAction {
86    extern_methods!(
87        #[unsafe(method(init))]
88        #[unsafe(method_family = init)]
89        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
90
91        #[unsafe(method(new))]
92        #[unsafe(method_family = new)]
93        pub unsafe fn new() -> Retained<Self>;
94    );
95}