objc2_foundation/generated/
NSHFSFileTypes.rs1use objc2::__framework_prelude::*;
4
5use crate::*;
6
7#[cfg(feature = "NSString")]
8#[inline]
9pub extern "C-unwind" fn NSFileTypeForHFSTypeCode(
10 hfs_file_type_code: OSType,
11) -> Option<Retained<NSString>> {
12 extern "C-unwind" {
13 fn NSFileTypeForHFSTypeCode(hfs_file_type_code: OSType) -> *mut NSString;
14 }
15 let ret = unsafe { NSFileTypeForHFSTypeCode(hfs_file_type_code) };
16 unsafe { Retained::retain_autoreleased(ret) }
17}
18
19extern "C-unwind" {
20 #[cfg(feature = "NSString")]
24 pub fn NSHFSTypeCodeFromFileType(file_type_string: Option<&NSString>) -> OSType;
25}
26
27#[cfg(feature = "NSString")]
31#[inline]
32pub unsafe extern "C-unwind" fn NSHFSTypeOfFile(
33 full_file_path: Option<&NSString>,
34) -> Option<Retained<NSString>> {
35 extern "C-unwind" {
36 fn NSHFSTypeOfFile(full_file_path: Option<&NSString>) -> *mut NSString;
37 }
38 let ret = unsafe { NSHFSTypeOfFile(full_file_path) };
39 unsafe { Retained::retain_autoreleased(ret) }
40}