objc2_foundation/generated/
NSHFSFileTypes.rs

1//! This file has been automatically generated by `objc2`'s `header-translator`.
2//! DO NOT EDIT
3use objc2::__framework_prelude::*;
4
5use crate::*;
6
7#[cfg(feature = "NSString")]
8#[inline]
9pub unsafe 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")]
21    pub fn NSHFSTypeCodeFromFileType(file_type_string: Option<&NSString>) -> OSType;
22}
23
24#[cfg(feature = "NSString")]
25#[inline]
26pub unsafe extern "C-unwind" fn NSHFSTypeOfFile(
27    full_file_path: Option<&NSString>,
28) -> Option<Retained<NSString>> {
29    extern "C-unwind" {
30        fn NSHFSTypeOfFile(full_file_path: Option<&NSString>) -> *mut NSString;
31    }
32    let ret = unsafe { NSHFSTypeOfFile(full_file_path) };
33    unsafe { Retained::retain_autoreleased(ret) }
34}