use objc2::__framework_prelude::*;
use objc2_foundation::*;
use crate::*;
extern_class!(
#[derive(Debug, PartialEq, Eq, Hash)]
#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
pub struct AMShellScriptAction;
#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
unsafe impl ClassType for AMShellScriptAction {
#[inherits(AMAction, NSObject)]
type Super = AMBundleAction;
type Mutability = InteriorMutable;
}
);
#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
unsafe impl NSCoding for AMShellScriptAction {}
#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
unsafe impl NSCopying for AMShellScriptAction {}
#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
unsafe impl NSObjectProtocol for AMShellScriptAction {}
#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
unsafe impl NSSecureCoding for AMShellScriptAction {}
extern_methods!(
#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
unsafe impl AMShellScriptAction {
#[method(remapLineEndings)]
pub unsafe fn remapLineEndings(&self) -> bool;
#[method_id(@__retain_semantics Other inputFieldSeparator)]
pub unsafe fn inputFieldSeparator(&self) -> Retained<NSString>;
#[method_id(@__retain_semantics Other outputFieldSeparator)]
pub unsafe fn outputFieldSeparator(&self) -> Retained<NSString>;
}
);
extern_methods!(
#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
unsafe impl AMShellScriptAction {
#[method_id(@__retain_semantics Init initWithDefinition:fromArchive:)]
pub unsafe fn initWithDefinition_fromArchive(
this: Allocated<Self>,
dict: Option<&NSDictionary<NSString, AnyObject>>,
archived: bool,
) -> Option<Retained<Self>>;
#[method_id(@__retain_semantics Init initWithContentsOfURL:error:_)]
pub unsafe fn initWithContentsOfURL_error(
this: Allocated<Self>,
file_url: &NSURL,
) -> Result<Retained<Self>, Retained<NSError>>;
}
);
extern_methods!(
#[cfg(all(feature = "AMAction", feature = "AMBundleAction"))]
unsafe impl AMShellScriptAction {
#[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>;
}
);