Skip to content

Instantly share code, notes, and snippets.

@pupboss
Created May 21, 2015 16:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pupboss/0cf42d6114816ef2fdb8 to your computer and use it in GitHub Desktop.
Save pupboss/0cf42d6114816ef2fdb8 to your computer and use it in GitHub Desktop.
Block-Test
This file has been truncated, but you can view the full file.
#ifndef __OBJC2__
#define __OBJC2__
#endif
struct objc_selector; struct objc_class;
struct __rw_objc_super {
struct objc_object *object;
struct objc_object *superClass;
__rw_objc_super(struct objc_object *o, struct objc_object *s) : object(o), superClass(s) {}
};
#ifndef _REWRITER_typedef_Protocol
typedef struct objc_object Protocol;
#define _REWRITER_typedef_Protocol
#endif
#define __OBJC_RW_DLLIMPORT extern
__OBJC_RW_DLLIMPORT void objc_msgSend(void);
__OBJC_RW_DLLIMPORT void objc_msgSendSuper(void);
__OBJC_RW_DLLIMPORT void objc_msgSend_stret(void);
__OBJC_RW_DLLIMPORT void objc_msgSendSuper_stret(void);
__OBJC_RW_DLLIMPORT void objc_msgSend_fpret(void);
__OBJC_RW_DLLIMPORT struct objc_class *objc_getClass(const char *);
__OBJC_RW_DLLIMPORT struct objc_class *class_getSuperclass(struct objc_class *);
__OBJC_RW_DLLIMPORT struct objc_class *objc_getMetaClass(const char *);
__OBJC_RW_DLLIMPORT void objc_exception_throw( struct objc_object *);
__OBJC_RW_DLLIMPORT int objc_sync_enter( struct objc_object *);
__OBJC_RW_DLLIMPORT int objc_sync_exit( struct objc_object *);
__OBJC_RW_DLLIMPORT Protocol *objc_getProtocol(const char *);
#ifdef _WIN64
typedef unsigned long long _WIN_NSUInteger;
#else
typedef unsigned int _WIN_NSUInteger;
#endif
#ifndef __FASTENUMERATIONSTATE
struct __objcFastEnumerationState {
unsigned long state;
void **itemsPtr;
unsigned long *mutationsPtr;
unsigned long extra[5];
};
__OBJC_RW_DLLIMPORT void objc_enumerationMutation(struct objc_object *);
#define __FASTENUMERATIONSTATE
#endif
#ifndef __NSCONSTANTSTRINGIMPL
struct __NSConstantStringImpl {
int *isa;
int flags;
char *str;
#if _WIN64
long long length;
#else
long length;
#endif
};
#ifdef CF_EXPORT_CONSTANT_STRING
extern "C" __declspec(dllexport) int __CFConstantStringClassReference[];
#else
__OBJC_RW_DLLIMPORT int __CFConstantStringClassReference[];
#endif
#define __NSCONSTANTSTRINGIMPL
#endif
#ifndef BLOCK_IMPL
#define BLOCK_IMPL
struct __block_impl {
void *isa;
int Flags;
int Reserved;
void *FuncPtr;
};
// Runtime copy/destroy helper functions (from Block_private.h)
#ifdef __OBJC_EXPORT_BLOCKS
extern "C" __declspec(dllexport) void _Block_object_assign(void *, const void *, const int);
extern "C" __declspec(dllexport) void _Block_object_dispose(const void *, const int);
extern "C" __declspec(dllexport) void *_NSConcreteGlobalBlock[32];
extern "C" __declspec(dllexport) void *_NSConcreteStackBlock[32];
#else
__OBJC_RW_DLLIMPORT void _Block_object_assign(void *, const void *, const int);
__OBJC_RW_DLLIMPORT void _Block_object_dispose(const void *, const int);
__OBJC_RW_DLLIMPORT void *_NSConcreteGlobalBlock[32];
__OBJC_RW_DLLIMPORT void *_NSConcreteStackBlock[32];
#endif
#endif
#define __block
#define __weak
#include <stdarg.h>
struct __NSContainer_literal {
void * *arr;
__NSContainer_literal (unsigned int count, ...) {
va_list marker;
va_start(marker, count);
arr = new void *[count];
for (unsigned i = 0; i < count; i++)
arr[i] = va_arg(marker, void *);
va_end( marker );
};
~__NSContainer_literal() {
delete[] arr;
}
};
extern "C" __declspec(dllimport) void * objc_autoreleasePoolPush(void);
extern "C" __declspec(dllimport) void objc_autoreleasePoolPop(void *);
struct __AtAutoreleasePool {
__AtAutoreleasePool() {atautoreleasepoolobj = objc_autoreleasePoolPush();}
~__AtAutoreleasePool() {objc_autoreleasePoolPop(atautoreleasepoolobj);}
void * atautoreleasepoolobj;
};
#define __OFFSETOFIVAR__(TYPE, MEMBER) ((long long) &((TYPE *)0)->MEMBER)
static __NSConstantStringImpl __NSConstantStringImpl__var_folders_f__kvyhp79j5wbcb2d7t24v3v_c0000gn_T_main_f979f0_mi_0 __attribute__ ((section ("__DATA, __cfstring"))) = {__CFConstantStringClassReference,0x000007c8,"Before Block",12};
static __NSConstantStringImpl __NSConstantStringImpl__var_folders_f__kvyhp79j5wbcb2d7t24v3v_c0000gn_T_main_f979f0_mi_1 __attribute__ ((section ("__DATA, __cfstring"))) = {__CFConstantStringClassReference,0x000007c8,"After Block",11};
static __NSConstantStringImpl __NSConstantStringImpl__var_folders_f__kvyhp79j5wbcb2d7t24v3v_c0000gn_T_main_f979f0_mi_2 __attribute__ ((section ("__DATA, __cfstring"))) = {__CFConstantStringClassReference,0x000007c8,"%d",2};
typedef signed char __int8_t;
typedef unsigned char __uint8_t;
typedef short __int16_t;
typedef unsigned short __uint16_t;
typedef int __int32_t;
typedef unsigned int __uint32_t;
typedef long long __int64_t;
typedef unsigned long long __uint64_t;
typedef long __darwin_intptr_t;
typedef unsigned int __darwin_natural_t;
typedef int __darwin_ct_rune_t;
typedef union {
char __mbstate8[128];
long long _mbstateL;
} __mbstate_t;
typedef __mbstate_t __darwin_mbstate_t;
typedef long int __darwin_ptrdiff_t;
typedef long unsigned int __darwin_size_t;
typedef __builtin_va_list __darwin_va_list;
typedef int __darwin_wchar_t;
typedef __darwin_wchar_t __darwin_rune_t;
typedef int __darwin_wint_t;
typedef unsigned long __darwin_clock_t;
typedef __uint32_t __darwin_socklen_t;
typedef long __darwin_ssize_t;
typedef long __darwin_time_t;
typedef signed char int8_t;
typedef short int16_t;
typedef int int32_t;
typedef long long int64_t;
typedef unsigned char u_int8_t;
typedef unsigned short u_int16_t;
typedef unsigned int u_int32_t;
typedef unsigned long long u_int64_t;
typedef int64_t register_t;
typedef __darwin_intptr_t intptr_t;
typedef unsigned long uintptr_t;
typedef u_int64_t user_addr_t;
typedef u_int64_t user_size_t;
typedef int64_t user_ssize_t;
typedef int64_t user_long_t;
typedef u_int64_t user_ulong_t;
typedef int64_t user_time_t;
typedef int64_t user_off_t;
typedef u_int64_t syscall_arg_t;
typedef __int64_t __darwin_blkcnt_t;
typedef __int32_t __darwin_blksize_t;
typedef __int32_t __darwin_dev_t;
typedef unsigned int __darwin_fsblkcnt_t;
typedef unsigned int __darwin_fsfilcnt_t;
typedef __uint32_t __darwin_gid_t;
typedef __uint32_t __darwin_id_t;
typedef __uint64_t __darwin_ino64_t;
typedef __darwin_ino64_t __darwin_ino_t;
typedef __darwin_natural_t __darwin_mach_port_name_t;
typedef __darwin_mach_port_name_t __darwin_mach_port_t;
typedef __uint16_t __darwin_mode_t;
typedef __int64_t __darwin_off_t;
typedef __int32_t __darwin_pid_t;
typedef __uint32_t __darwin_sigset_t;
typedef __int32_t __darwin_suseconds_t;
typedef __uint32_t __darwin_uid_t;
typedef __uint32_t __darwin_useconds_t;
typedef unsigned char __darwin_uuid_t[16];
typedef char __darwin_uuid_string_t[37];
struct __darwin_pthread_handler_rec {
void (*__routine)(void *);
void *__arg;
struct __darwin_pthread_handler_rec *__next;
};
struct _opaque_pthread_attr_t {
long __sig;
char __opaque[56];
};
struct _opaque_pthread_cond_t {
long __sig;
char __opaque[40];
};
struct _opaque_pthread_condattr_t {
long __sig;
char __opaque[8];
};
struct _opaque_pthread_mutex_t {
long __sig;
char __opaque[56];
};
struct _opaque_pthread_mutexattr_t {
long __sig;
char __opaque[8];
};
struct _opaque_pthread_once_t {
long __sig;
char __opaque[8];
};
struct _opaque_pthread_rwlock_t {
long __sig;
char __opaque[192];
};
struct _opaque_pthread_rwlockattr_t {
long __sig;
char __opaque[16];
};
struct _opaque_pthread_t {
long __sig;
struct __darwin_pthread_handler_rec *__cleanup_stack;
char __opaque[8176];
};
typedef struct _opaque_pthread_attr_t __darwin_pthread_attr_t;
typedef struct _opaque_pthread_cond_t __darwin_pthread_cond_t;
typedef struct _opaque_pthread_condattr_t __darwin_pthread_condattr_t;
typedef unsigned long __darwin_pthread_key_t;
typedef struct _opaque_pthread_mutex_t __darwin_pthread_mutex_t;
typedef struct _opaque_pthread_mutexattr_t __darwin_pthread_mutexattr_t;
typedef struct _opaque_pthread_once_t __darwin_pthread_once_t;
typedef struct _opaque_pthread_rwlock_t __darwin_pthread_rwlock_t;
typedef struct _opaque_pthread_rwlockattr_t __darwin_pthread_rwlockattr_t;
typedef struct _opaque_pthread_t *__darwin_pthread_t;
static inline
__uint16_t
_OSSwapInt16(
__uint16_t _data
)
{
return ((__uint16_t)((_data << 8) | (_data >> 8)));
}
static inline
__uint32_t
_OSSwapInt32(
__uint32_t _data
)
{
return __builtin_bswap32(_data);
}
static inline
__uint64_t
_OSSwapInt64(
__uint64_t _data
)
{
return __builtin_bswap64(_data);
}
typedef unsigned char u_char;
typedef unsigned short u_short;
typedef unsigned int u_int;
typedef unsigned long u_long;
typedef unsigned short ushort;
typedef unsigned int uint;
typedef u_int64_t u_quad_t;
typedef int64_t quad_t;
typedef quad_t * qaddr_t;
typedef char * caddr_t;
typedef int32_t daddr_t;
typedef __darwin_dev_t dev_t;
typedef u_int32_t fixpt_t;
typedef __darwin_blkcnt_t blkcnt_t;
typedef __darwin_blksize_t blksize_t;
typedef __darwin_gid_t gid_t;
typedef __uint32_t in_addr_t;
typedef __uint16_t in_port_t;
typedef __darwin_ino_t ino_t;
typedef __darwin_ino64_t ino64_t;
typedef __int32_t key_t;
typedef __darwin_mode_t mode_t;
typedef __uint16_t nlink_t;
typedef __darwin_id_t id_t;
typedef __darwin_pid_t pid_t;
typedef __darwin_off_t off_t;
typedef int32_t segsz_t;
typedef int32_t swblk_t;
typedef __darwin_uid_t uid_t;
static inline __int32_t major(__uint32_t _x)
{
return (__int32_t)(((__uint32_t)_x >> 24) & 0xff);
}
static inline __int32_t minor(__uint32_t _x)
{
return (__int32_t)((_x) & 0xffffff);
}
static inline dev_t makedev(__uint32_t _major, __uint32_t _minor)
{
return (dev_t)(((_major) << 24) | (_minor));
}
typedef __darwin_clock_t clock_t;
typedef __darwin_size_t size_t;
typedef __darwin_ssize_t ssize_t;
typedef __darwin_time_t time_t;
typedef __darwin_useconds_t useconds_t;
typedef __darwin_suseconds_t suseconds_t;
typedef __darwin_size_t rsize_t;
typedef int errno_t;
extern "C" {
typedef struct fd_set {
__int32_t fds_bits[((((1024) % ((sizeof(__int32_t) * 8))) == 0) ? ((1024) / ((sizeof(__int32_t) * 8))) : (((1024) / ((sizeof(__int32_t) * 8))) + 1))];
} fd_set;
}
static inline int
__darwin_fd_isset(int _n, const struct fd_set *_p)
{
return (_p->fds_bits[(unsigned long)_n/(sizeof(__int32_t) * 8)] & ((__int32_t)(1<<((unsigned long)_n % (sizeof(__int32_t) * 8)))));
}
typedef __int32_t fd_mask;
typedef __darwin_pthread_attr_t pthread_attr_t;
typedef __darwin_pthread_cond_t pthread_cond_t;
typedef __darwin_pthread_condattr_t pthread_condattr_t;
typedef __darwin_pthread_mutex_t pthread_mutex_t;
typedef __darwin_pthread_mutexattr_t pthread_mutexattr_t;
typedef __darwin_pthread_once_t pthread_once_t;
typedef __darwin_pthread_rwlock_t pthread_rwlock_t;
typedef __darwin_pthread_rwlockattr_t pthread_rwlockattr_t;
typedef __darwin_pthread_t pthread_t;
typedef __darwin_pthread_key_t pthread_key_t;
typedef __darwin_fsblkcnt_t fsblkcnt_t;
typedef __darwin_fsfilcnt_t fsfilcnt_t;
typedef __builtin_va_list va_list;
typedef __builtin_va_list __gnuc_va_list;
typedef int __darwin_nl_item;
typedef int __darwin_wctrans_t;
typedef __uint32_t __darwin_wctype_t;
typedef enum {
P_ALL,
P_PID,
P_PGID
} idtype_t;
typedef int sig_atomic_t;
struct __darwin_i386_thread_state
{
unsigned int __eax;
unsigned int __ebx;
unsigned int __ecx;
unsigned int __edx;
unsigned int __edi;
unsigned int __esi;
unsigned int __ebp;
unsigned int __esp;
unsigned int __ss;
unsigned int __eflags;
unsigned int __eip;
unsigned int __cs;
unsigned int __ds;
unsigned int __es;
unsigned int __fs;
unsigned int __gs;
};
struct __darwin_fp_control
{
unsigned short __invalid :1,
__denorm :1,
__zdiv :1,
__ovrfl :1,
__undfl :1,
__precis :1,
:2,
__pc :2,
__rc :2,
:1,
:3;
};
typedef struct __darwin_fp_control __darwin_fp_control_t;
struct __darwin_fp_status
{
unsigned short __invalid :1,
__denorm :1,
__zdiv :1,
__ovrfl :1,
__undfl :1,
__precis :1,
__stkflt :1,
__errsumm :1,
__c0 :1,
__c1 :1,
__c2 :1,
__tos :3,
__c3 :1,
__busy :1;
};
typedef struct __darwin_fp_status __darwin_fp_status_t;
struct __darwin_mmst_reg
{
char __mmst_reg[10];
char __mmst_rsrv[6];
};
struct __darwin_xmm_reg
{
char __xmm_reg[16];
};
struct __darwin_i386_float_state
{
int __fpu_reserved[2];
struct __darwin_fp_control __fpu_fcw;
struct __darwin_fp_status __fpu_fsw;
__uint8_t __fpu_ftw;
__uint8_t __fpu_rsrv1;
__uint16_t __fpu_fop;
__uint32_t __fpu_ip;
__uint16_t __fpu_cs;
__uint16_t __fpu_rsrv2;
__uint32_t __fpu_dp;
__uint16_t __fpu_ds;
__uint16_t __fpu_rsrv3;
__uint32_t __fpu_mxcsr;
__uint32_t __fpu_mxcsrmask;
struct __darwin_mmst_reg __fpu_stmm0;
struct __darwin_mmst_reg __fpu_stmm1;
struct __darwin_mmst_reg __fpu_stmm2;
struct __darwin_mmst_reg __fpu_stmm3;
struct __darwin_mmst_reg __fpu_stmm4;
struct __darwin_mmst_reg __fpu_stmm5;
struct __darwin_mmst_reg __fpu_stmm6;
struct __darwin_mmst_reg __fpu_stmm7;
struct __darwin_xmm_reg __fpu_xmm0;
struct __darwin_xmm_reg __fpu_xmm1;
struct __darwin_xmm_reg __fpu_xmm2;
struct __darwin_xmm_reg __fpu_xmm3;
struct __darwin_xmm_reg __fpu_xmm4;
struct __darwin_xmm_reg __fpu_xmm5;
struct __darwin_xmm_reg __fpu_xmm6;
struct __darwin_xmm_reg __fpu_xmm7;
char __fpu_rsrv4[14*16];
int __fpu_reserved1;
};
struct __darwin_i386_avx_state
{
int __fpu_reserved[2];
struct __darwin_fp_control __fpu_fcw;
struct __darwin_fp_status __fpu_fsw;
__uint8_t __fpu_ftw;
__uint8_t __fpu_rsrv1;
__uint16_t __fpu_fop;
__uint32_t __fpu_ip;
__uint16_t __fpu_cs;
__uint16_t __fpu_rsrv2;
__uint32_t __fpu_dp;
__uint16_t __fpu_ds;
__uint16_t __fpu_rsrv3;
__uint32_t __fpu_mxcsr;
__uint32_t __fpu_mxcsrmask;
struct __darwin_mmst_reg __fpu_stmm0;
struct __darwin_mmst_reg __fpu_stmm1;
struct __darwin_mmst_reg __fpu_stmm2;
struct __darwin_mmst_reg __fpu_stmm3;
struct __darwin_mmst_reg __fpu_stmm4;
struct __darwin_mmst_reg __fpu_stmm5;
struct __darwin_mmst_reg __fpu_stmm6;
struct __darwin_mmst_reg __fpu_stmm7;
struct __darwin_xmm_reg __fpu_xmm0;
struct __darwin_xmm_reg __fpu_xmm1;
struct __darwin_xmm_reg __fpu_xmm2;
struct __darwin_xmm_reg __fpu_xmm3;
struct __darwin_xmm_reg __fpu_xmm4;
struct __darwin_xmm_reg __fpu_xmm5;
struct __darwin_xmm_reg __fpu_xmm6;
struct __darwin_xmm_reg __fpu_xmm7;
char __fpu_rsrv4[14*16];
int __fpu_reserved1;
char __avx_reserved1[64];
struct __darwin_xmm_reg __fpu_ymmh0;
struct __darwin_xmm_reg __fpu_ymmh1;
struct __darwin_xmm_reg __fpu_ymmh2;
struct __darwin_xmm_reg __fpu_ymmh3;
struct __darwin_xmm_reg __fpu_ymmh4;
struct __darwin_xmm_reg __fpu_ymmh5;
struct __darwin_xmm_reg __fpu_ymmh6;
struct __darwin_xmm_reg __fpu_ymmh7;
};
struct __darwin_i386_exception_state
{
__uint16_t __trapno;
__uint16_t __cpu;
__uint32_t __err;
__uint32_t __faultvaddr;
};
struct __darwin_x86_debug_state32
{
unsigned int __dr0;
unsigned int __dr1;
unsigned int __dr2;
unsigned int __dr3;
unsigned int __dr4;
unsigned int __dr5;
unsigned int __dr6;
unsigned int __dr7;
};
struct __darwin_x86_thread_state64
{
__uint64_t __rax;
__uint64_t __rbx;
__uint64_t __rcx;
__uint64_t __rdx;
__uint64_t __rdi;
__uint64_t __rsi;
__uint64_t __rbp;
__uint64_t __rsp;
__uint64_t __r8;
__uint64_t __r9;
__uint64_t __r10;
__uint64_t __r11;
__uint64_t __r12;
__uint64_t __r13;
__uint64_t __r14;
__uint64_t __r15;
__uint64_t __rip;
__uint64_t __rflags;
__uint64_t __cs;
__uint64_t __fs;
__uint64_t __gs;
};
struct __darwin_x86_float_state64
{
int __fpu_reserved[2];
struct __darwin_fp_control __fpu_fcw;
struct __darwin_fp_status __fpu_fsw;
__uint8_t __fpu_ftw;
__uint8_t __fpu_rsrv1;
__uint16_t __fpu_fop;
__uint32_t __fpu_ip;
__uint16_t __fpu_cs;
__uint16_t __fpu_rsrv2;
__uint32_t __fpu_dp;
__uint16_t __fpu_ds;
__uint16_t __fpu_rsrv3;
__uint32_t __fpu_mxcsr;
__uint32_t __fpu_mxcsrmask;
struct __darwin_mmst_reg __fpu_stmm0;
struct __darwin_mmst_reg __fpu_stmm1;
struct __darwin_mmst_reg __fpu_stmm2;
struct __darwin_mmst_reg __fpu_stmm3;
struct __darwin_mmst_reg __fpu_stmm4;
struct __darwin_mmst_reg __fpu_stmm5;
struct __darwin_mmst_reg __fpu_stmm6;
struct __darwin_mmst_reg __fpu_stmm7;
struct __darwin_xmm_reg __fpu_xmm0;
struct __darwin_xmm_reg __fpu_xmm1;
struct __darwin_xmm_reg __fpu_xmm2;
struct __darwin_xmm_reg __fpu_xmm3;
struct __darwin_xmm_reg __fpu_xmm4;
struct __darwin_xmm_reg __fpu_xmm5;
struct __darwin_xmm_reg __fpu_xmm6;
struct __darwin_xmm_reg __fpu_xmm7;
struct __darwin_xmm_reg __fpu_xmm8;
struct __darwin_xmm_reg __fpu_xmm9;
struct __darwin_xmm_reg __fpu_xmm10;
struct __darwin_xmm_reg __fpu_xmm11;
struct __darwin_xmm_reg __fpu_xmm12;
struct __darwin_xmm_reg __fpu_xmm13;
struct __darwin_xmm_reg __fpu_xmm14;
struct __darwin_xmm_reg __fpu_xmm15;
char __fpu_rsrv4[6*16];
int __fpu_reserved1;
};
struct __darwin_x86_avx_state64
{
int __fpu_reserved[2];
struct __darwin_fp_control __fpu_fcw;
struct __darwin_fp_status __fpu_fsw;
__uint8_t __fpu_ftw;
__uint8_t __fpu_rsrv1;
__uint16_t __fpu_fop;
__uint32_t __fpu_ip;
__uint16_t __fpu_cs;
__uint16_t __fpu_rsrv2;
__uint32_t __fpu_dp;
__uint16_t __fpu_ds;
__uint16_t __fpu_rsrv3;
__uint32_t __fpu_mxcsr;
__uint32_t __fpu_mxcsrmask;
struct __darwin_mmst_reg __fpu_stmm0;
struct __darwin_mmst_reg __fpu_stmm1;
struct __darwin_mmst_reg __fpu_stmm2;
struct __darwin_mmst_reg __fpu_stmm3;
struct __darwin_mmst_reg __fpu_stmm4;
struct __darwin_mmst_reg __fpu_stmm5;
struct __darwin_mmst_reg __fpu_stmm6;
struct __darwin_mmst_reg __fpu_stmm7;
struct __darwin_xmm_reg __fpu_xmm0;
struct __darwin_xmm_reg __fpu_xmm1;
struct __darwin_xmm_reg __fpu_xmm2;
struct __darwin_xmm_reg __fpu_xmm3;
struct __darwin_xmm_reg __fpu_xmm4;
struct __darwin_xmm_reg __fpu_xmm5;
struct __darwin_xmm_reg __fpu_xmm6;
struct __darwin_xmm_reg __fpu_xmm7;
struct __darwin_xmm_reg __fpu_xmm8;
struct __darwin_xmm_reg __fpu_xmm9;
struct __darwin_xmm_reg __fpu_xmm10;
struct __darwin_xmm_reg __fpu_xmm11;
struct __darwin_xmm_reg __fpu_xmm12;
struct __darwin_xmm_reg __fpu_xmm13;
struct __darwin_xmm_reg __fpu_xmm14;
struct __darwin_xmm_reg __fpu_xmm15;
char __fpu_rsrv4[6*16];
int __fpu_reserved1;
char __avx_reserved1[64];
struct __darwin_xmm_reg __fpu_ymmh0;
struct __darwin_xmm_reg __fpu_ymmh1;
struct __darwin_xmm_reg __fpu_ymmh2;
struct __darwin_xmm_reg __fpu_ymmh3;
struct __darwin_xmm_reg __fpu_ymmh4;
struct __darwin_xmm_reg __fpu_ymmh5;
struct __darwin_xmm_reg __fpu_ymmh6;
struct __darwin_xmm_reg __fpu_ymmh7;
struct __darwin_xmm_reg __fpu_ymmh8;
struct __darwin_xmm_reg __fpu_ymmh9;
struct __darwin_xmm_reg __fpu_ymmh10;
struct __darwin_xmm_reg __fpu_ymmh11;
struct __darwin_xmm_reg __fpu_ymmh12;
struct __darwin_xmm_reg __fpu_ymmh13;
struct __darwin_xmm_reg __fpu_ymmh14;
struct __darwin_xmm_reg __fpu_ymmh15;
};
struct __darwin_x86_exception_state64
{
__uint16_t __trapno;
__uint16_t __cpu;
__uint32_t __err;
__uint64_t __faultvaddr;
};
struct __darwin_x86_debug_state64
{
__uint64_t __dr0;
__uint64_t __dr1;
__uint64_t __dr2;
__uint64_t __dr3;
__uint64_t __dr4;
__uint64_t __dr5;
__uint64_t __dr6;
__uint64_t __dr7;
};
struct __darwin_mcontext32
{
struct __darwin_i386_exception_state __es;
struct __darwin_i386_thread_state __ss;
struct __darwin_i386_float_state __fs;
};
struct __darwin_mcontext_avx32
{
struct __darwin_i386_exception_state __es;
struct __darwin_i386_thread_state __ss;
struct __darwin_i386_avx_state __fs;
};
struct __darwin_mcontext64
{
struct __darwin_x86_exception_state64 __es;
struct __darwin_x86_thread_state64 __ss;
struct __darwin_x86_float_state64 __fs;
};
struct __darwin_mcontext_avx64
{
struct __darwin_x86_exception_state64 __es;
struct __darwin_x86_thread_state64 __ss;
struct __darwin_x86_avx_state64 __fs;
};
typedef struct __darwin_mcontext64 *mcontext_t;
struct __darwin_sigaltstack
{
void *ss_sp;
__darwin_size_t ss_size;
int ss_flags;
};
typedef struct __darwin_sigaltstack stack_t;
struct __darwin_ucontext
{
int uc_onstack;
__darwin_sigset_t uc_sigmask;
struct __darwin_sigaltstack uc_stack;
struct __darwin_ucontext *uc_link;
__darwin_size_t uc_mcsize;
struct __darwin_mcontext64 *uc_mcontext;
};
typedef struct __darwin_ucontext ucontext_t;
typedef __darwin_sigset_t sigset_t;
union sigval {
int sival_int;
void *sival_ptr;
};
struct sigevent {
int sigev_notify;
int sigev_signo;
union sigval sigev_value;
void (*sigev_notify_function)(union sigval);
pthread_attr_t *sigev_notify_attributes;
};
typedef struct __siginfo {
int si_signo;
int si_errno;
int si_code;
pid_t si_pid;
uid_t si_uid;
int si_status;
void *si_addr;
union sigval si_value;
long si_band;
unsigned long __pad[7];
} siginfo_t;
union __sigaction_u {
void (*__sa_handler)(int);
void (*__sa_sigaction)(int, struct __siginfo *,
void *);
};
struct __sigaction {
union __sigaction_u __sigaction_u;
void (*sa_tramp)(void *, int, int, siginfo_t *, void *);
sigset_t sa_mask;
int sa_flags;
};
struct sigaction {
union __sigaction_u __sigaction_u;
sigset_t sa_mask;
int sa_flags;
};
typedef void (*sig_t)(int);
struct sigvec {
void (*sv_handler)(int);
int sv_mask;
int sv_flags;
};
struct sigstack {
char *ss_sp;
int ss_onstack;
};
extern "C" {
void (*signal(int, void (*)(int)))(int);
}
typedef unsigned char uint8_t;
typedef unsigned short uint16_t;
typedef unsigned int uint32_t;
typedef unsigned long long uint64_t;
typedef int8_t int_least8_t;
typedef int16_t int_least16_t;
typedef int32_t int_least32_t;
typedef int64_t int_least64_t;
typedef uint8_t uint_least8_t;
typedef uint16_t uint_least16_t;
typedef uint32_t uint_least32_t;
typedef uint64_t uint_least64_t;
typedef int8_t int_fast8_t;
typedef int16_t int_fast16_t;
typedef int32_t int_fast32_t;
typedef int64_t int_fast64_t;
typedef uint8_t uint_fast8_t;
typedef uint16_t uint_fast16_t;
typedef uint32_t uint_fast32_t;
typedef uint64_t uint_fast64_t;
typedef long int intmax_t;
typedef long unsigned int uintmax_t;
struct timeval
{
__darwin_time_t tv_sec;
__darwin_suseconds_t tv_usec;
};
typedef __uint64_t rlim_t;
struct rusage {
struct timeval ru_utime;
struct timeval ru_stime;
long ru_maxrss;
long ru_ixrss;
long ru_idrss;
long ru_isrss;
long ru_minflt;
long ru_majflt;
long ru_nswap;
long ru_inblock;
long ru_oublock;
long ru_msgsnd;
long ru_msgrcv;
long ru_nsignals;
long ru_nvcsw;
long ru_nivcsw;
};
typedef void *rusage_info_t;
struct rusage_info_v0 {
uint8_t ri_uuid[16];
uint64_t ri_user_time;
uint64_t ri_system_time;
uint64_t ri_pkg_idle_wkups;
uint64_t ri_interrupt_wkups;
uint64_t ri_pageins;
uint64_t ri_wired_size;
uint64_t ri_resident_size;
uint64_t ri_phys_footprint;
uint64_t ri_proc_start_abstime;
uint64_t ri_proc_exit_abstime;
};
struct rusage_info_v1 {
uint8_t ri_uuid[16];
uint64_t ri_user_time;
uint64_t ri_system_time;
uint64_t ri_pkg_idle_wkups;
uint64_t ri_interrupt_wkups;
uint64_t ri_pageins;
uint64_t ri_wired_size;
uint64_t ri_resident_size;
uint64_t ri_phys_footprint;
uint64_t ri_proc_start_abstime;
uint64_t ri_proc_exit_abstime;
uint64_t ri_child_user_time;
uint64_t ri_child_system_time;
uint64_t ri_child_pkg_idle_wkups;
uint64_t ri_child_interrupt_wkups;
uint64_t ri_child_pageins;
uint64_t ri_child_elapsed_abstime;
};
struct rusage_info_v2 {
uint8_t ri_uuid[16];
uint64_t ri_user_time;
uint64_t ri_system_time;
uint64_t ri_pkg_idle_wkups;
uint64_t ri_interrupt_wkups;
uint64_t ri_pageins;
uint64_t ri_wired_size;
uint64_t ri_resident_size;
uint64_t ri_phys_footprint;
uint64_t ri_proc_start_abstime;
uint64_t ri_proc_exit_abstime;
uint64_t ri_child_user_time;
uint64_t ri_child_system_time;
uint64_t ri_child_pkg_idle_wkups;
uint64_t ri_child_interrupt_wkups;
uint64_t ri_child_pageins;
uint64_t ri_child_elapsed_abstime;
uint64_t ri_diskio_bytesread;
uint64_t ri_diskio_byteswritten;
};
struct rusage_info_v3 {
uint8_t ri_uuid[16];
uint64_t ri_user_time;
uint64_t ri_system_time;
uint64_t ri_pkg_idle_wkups;
uint64_t ri_interrupt_wkups;
uint64_t ri_pageins;
uint64_t ri_wired_size;
uint64_t ri_resident_size;
uint64_t ri_phys_footprint;
uint64_t ri_proc_start_abstime;
uint64_t ri_proc_exit_abstime;
uint64_t ri_child_user_time;
uint64_t ri_child_system_time;
uint64_t ri_child_pkg_idle_wkups;
uint64_t ri_child_interrupt_wkups;
uint64_t ri_child_pageins;
uint64_t ri_child_elapsed_abstime;
uint64_t ri_diskio_bytesread;
uint64_t ri_diskio_byteswritten;
uint64_t ri_cpu_time_qos_default;
uint64_t ri_cpu_time_qos_maintenance;
uint64_t ri_cpu_time_qos_background;
uint64_t ri_cpu_time_qos_utility;
uint64_t ri_cpu_time_qos_legacy;
uint64_t ri_cpu_time_qos_user_initiated;
uint64_t ri_cpu_time_qos_user_interactive;
uint64_t ri_billed_system_time;
uint64_t ri_serviced_system_time;
};
typedef struct rusage_info_v3 rusage_info_current;
struct rlimit {
rlim_t rlim_cur;
rlim_t rlim_max;
};
struct proc_rlimit_control_wakeupmon {
uint32_t wm_flags;
int32_t wm_rate;
};
extern "C" {
int getpriority(int, id_t);
int getiopolicy_np(int, int) __attribute__((availability(macosx,introduced=10.5)));
int getrlimit(int, struct rlimit *) __asm("_" "getrlimit" );
int getrusage(int, struct rusage *);
int setpriority(int, id_t, int);
int setiopolicy_np(int, int, int) __attribute__((availability(macosx,introduced=10.5)));
int setrlimit(int, const struct rlimit *) __asm("_" "setrlimit" );
}
union wait {
int w_status;
struct {
unsigned int w_Termsig:7,
w_Coredump:1,
w_Retcode:8,
w_Filler:16;
} w_T;
struct {
unsigned int w_Stopval:8,
w_Stopsig:8,
w_Filler:16;
} w_S;
};
extern "C" {
pid_t wait(int *) __asm("_" "wait" );
pid_t waitpid(pid_t, int *, int) __asm("_" "waitpid" );
int waitid(idtype_t, id_t, siginfo_t *, int) __asm("_" "waitid" );
pid_t wait3(int *, int, struct rusage *);
pid_t wait4(pid_t, int *, int, struct rusage *);
}
extern "C" {
void *alloca(size_t);
}
typedef __darwin_ct_rune_t ct_rune_t;
typedef __darwin_rune_t rune_t;
typedef struct {
int quot;
int rem;
} div_t;
typedef struct {
long quot;
long rem;
} ldiv_t;
typedef struct {
long long quot;
long long rem;
} lldiv_t;
extern int __mb_cur_max;
extern "C" {
void abort(void) __attribute__((noreturn));
int abs(int) __attribute__((const));
int atexit(void (*)(void));
double atof(const char *);
int atoi(const char *);
long atol(const char *);
long long
atoll(const char *);
void *bsearch(const void *, const void *, size_t,
size_t, int (*)(const void *, const void *));
void *calloc(size_t, size_t);
div_t div(int, int) __attribute__((const));
void exit(int) __attribute__((noreturn));
void free(void *);
char *getenv(const char *);
long labs(long) __attribute__((const));
ldiv_t ldiv(long, long) __attribute__((const));
long long
llabs(long long);
lldiv_t lldiv(long long, long long);
void *malloc(size_t);
int mblen(const char *, size_t);
size_t mbstowcs(wchar_t * , const char * , size_t);
int mbtowc(wchar_t * , const char * , size_t);
int posix_memalign(void **, size_t, size_t) __attribute__((availability(macosx,introduced=10.6)));
void qsort(void *, size_t, size_t,
int (*)(const void *, const void *));
int rand(void);
void *realloc(void *, size_t);
void srand(unsigned);
double strtod(const char *, char **) __asm("_" "strtod" );
float strtof(const char *, char **) __asm("_" "strtof" );
long strtol(const char *, char **, int);
long double
strtold(const char *, char **);
long long
strtoll(const char *, char **, int);
unsigned long
strtoul(const char *, char **, int);
unsigned long long
strtoull(const char *, char **, int);
int system(const char *) __asm("_" "system" ) __attribute__((availability(macosx,introduced=10.0)));
size_t wcstombs(char * , const wchar_t * , size_t);
int wctomb(char *, wchar_t);
void _Exit(int) __attribute__((noreturn));
long a64l(const char *);
double drand48(void);
char *ecvt(double, int, int *, int *);
double erand48(unsigned short[3]);
char *fcvt(double, int, int *, int *);
char *gcvt(double, int, char *);
int getsubopt(char **, char * const *, char **);
int grantpt(int);
char *initstate(unsigned, char *, size_t);
long jrand48(unsigned short[3]);
char *l64a(long);
void lcong48(unsigned short[7]);
long lrand48(void);
char *mktemp(char *);
int mkstemp(char *);
long mrand48(void);
long nrand48(unsigned short[3]);
int posix_openpt(int);
char *ptsname(int);
int putenv(char *) __asm("_" "putenv" );
long random(void);
int rand_r(unsigned *);
char *realpath(const char * , char * ) __asm("_" "realpath" "$DARWIN_EXTSN");
unsigned short
*seed48(unsigned short[3]);
int setenv(const char *, const char *, int) __asm("_" "setenv" );
void setkey(const char *) __asm("_" "setkey" );
char *setstate(const char *);
void srand48(long);
void srandom(unsigned);
int unlockpt(int);
int unsetenv(const char *) __asm("_" "unsetenv" );
u_int32_t arc4random(void);
void arc4random_addrandom(unsigned char * , int );
void arc4random_buf(void * , size_t ) __attribute__((availability(macosx,introduced=10.7)));
void arc4random_stir(void);
u_int32_t
arc4random_uniform(u_int32_t ) __attribute__((availability(macosx,introduced=10.7)));
int atexit_b(void (*)(void)) __attribute__((availability(macosx,introduced=10.6)));
void *bsearch_b(const void *, const void *, size_t,
size_t, int (*)(const void *, const void *)) __attribute__((availability(macosx,introduced=10.6)));
char *cgetcap(char *, const char *, int);
int cgetclose(void);
int cgetent(char **, char **, const char *);
int cgetfirst(char **, char **);
int cgetmatch(const char *, const char *);
int cgetnext(char **, char **);
int cgetnum(char *, const char *, long *);
int cgetset(const char *);
int cgetstr(char *, const char *, char **);
int cgetustr(char *, const char *, char **);
int daemon(int, int) __asm("_" "daemon" "$1050") __attribute__((availability(macosx,introduced=10.0,deprecated=10.5)));
char *devname(dev_t, mode_t);
char *devname_r(dev_t, mode_t, char *buf, int len);
char *getbsize(int *, long *);
int getloadavg(double [], int);
const char
*getprogname(void);
int heapsort(void *, size_t, size_t,
int (*)(const void *, const void *));
int heapsort_b(void *, size_t, size_t,
int (*)(const void *, const void *)) __attribute__((availability(macosx,introduced=10.6)));
int mergesort(void *, size_t, size_t,
int (*)(const void *, const void *));
int mergesort_b(void *, size_t, size_t,
int (*)(const void *, const void *)) __attribute__((availability(macosx,introduced=10.6)));
void psort(void *, size_t, size_t,
int (*)(const void *, const void *)) __attribute__((availability(macosx,introduced=10.6)));
void psort_b(void *, size_t, size_t,
int (*)(const void *, const void *)) __attribute__((availability(macosx,introduced=10.6)));
void psort_r(void *, size_t, size_t, void *,
int (*)(void *, const void *, const void *)) __attribute__((availability(macosx,introduced=10.6)));
void qsort_b(void *, size_t, size_t,
int (*)(const void *, const void *)) __attribute__((availability(macosx,introduced=10.6)));
void qsort_r(void *, size_t, size_t, void *,
int (*)(void *, const void *, const void *));
int radixsort(const unsigned char **, int, const unsigned char *,
unsigned);
void setprogname(const char *);
int sradixsort(const unsigned char **, int, const unsigned char *,
unsigned);
void sranddev(void);
void srandomdev(void);
void *reallocf(void *, size_t);
long long
strtoq(const char *, char **, int);
unsigned long long
strtouq(const char *, char **, int);
extern char *suboptarg;
void *valloc(size_t);
}
extern "C" {
void __assert_rtn(const char *, const char *, int, const char *) __attribute__((noreturn));
}
typedef __darwin_wint_t wint_t;
typedef struct {
__darwin_rune_t __min;
__darwin_rune_t __max;
__darwin_rune_t __map;
__uint32_t *__types;
} _RuneEntry;
typedef struct {
int __nranges;
_RuneEntry *__ranges;
} _RuneRange;
typedef struct {
char __name[14];
__uint32_t __mask;
} _RuneCharClass;
typedef struct {
char __magic[8];
char __encoding[32];
__darwin_rune_t (*__sgetrune)(const char *, __darwin_size_t, char const **);
int (*__sputrune)(__darwin_rune_t, char *, __darwin_size_t, char **);
__darwin_rune_t __invalid_rune;
__uint32_t __runetype[(1 <<8 )];
__darwin_rune_t __maplower[(1 <<8 )];
__darwin_rune_t __mapupper[(1 <<8 )];
_RuneRange __runetype_ext;
_RuneRange __maplower_ext;
_RuneRange __mapupper_ext;
void *__variable;
int __variable_len;
int __ncharclasses;
_RuneCharClass *__charclasses;
} _RuneLocale;
extern "C" {
extern _RuneLocale _DefaultRuneLocale;
extern _RuneLocale *_CurrentRuneLocale;
}
extern "C" {
unsigned long ___runetype(__darwin_ct_rune_t);
__darwin_ct_rune_t ___tolower(__darwin_ct_rune_t);
__darwin_ct_rune_t ___toupper(__darwin_ct_rune_t);
}
inline int
isascii(int _c)
{
return ((_c & ~0x7F) == 0);
}
extern "C" {
int __maskrune(__darwin_ct_rune_t, unsigned long);
}
inline int
__istype(__darwin_ct_rune_t _c, unsigned long _f)
{
return (isascii(_c) ? !!(_DefaultRuneLocale.__runetype[_c] & _f)
: !!__maskrune(_c, _f));
}
inline __darwin_ct_rune_t
__isctype(__darwin_ct_rune_t _c, unsigned long _f)
{
return (_c < 0 || _c >= (1 <<8 )) ? 0 :
!!(_DefaultRuneLocale.__runetype[_c] & _f);
}
extern "C" {
__darwin_ct_rune_t __toupper(__darwin_ct_rune_t);
__darwin_ct_rune_t __tolower(__darwin_ct_rune_t);
}
inline int
__wcwidth(__darwin_ct_rune_t _c)
{
unsigned int _x;
if (_c == 0)
return (0);
_x = (unsigned int)__maskrune(_c, 0xe0000000L|0x00040000L);
if ((_x & 0xe0000000L) != 0)
return ((_x & 0xe0000000L) >> 30);
return ((_x & 0x00040000L) != 0 ? 1 : -1);
}
inline int
isalnum(int _c)
{
return (__istype(_c, 0x00000100L|0x00000400L));
}
inline int
isalpha(int _c)
{
return (__istype(_c, 0x00000100L));
}
inline int
isblank(int _c)
{
return (__istype(_c, 0x00020000L));
}
inline int
iscntrl(int _c)
{
return (__istype(_c, 0x00000200L));
}
inline int
isdigit(int _c)
{
return (__isctype(_c, 0x00000400L));
}
inline int
isgraph(int _c)
{
return (__istype(_c, 0x00000800L));
}
inline int
islower(int _c)
{
return (__istype(_c, 0x00001000L));
}
inline int
isprint(int _c)
{
return (__istype(_c, 0x00040000L));
}
inline int
ispunct(int _c)
{
return (__istype(_c, 0x00002000L));
}
inline int
isspace(int _c)
{
return (__istype(_c, 0x00004000L));
}
inline int
isupper(int _c)
{
return (__istype(_c, 0x00008000L));
}
inline int
isxdigit(int _c)
{
return (__isctype(_c, 0x00010000L));
}
inline int
toascii(int _c)
{
return (_c & 0x7F);
}
inline int
tolower(int _c)
{
return (__tolower(_c));
}
inline int
toupper(int _c)
{
return (__toupper(_c));
}
inline int
digittoint(int _c)
{
return (__maskrune(_c, 0x0F));
}
inline int
ishexnumber(int _c)
{
return (__istype(_c, 0x00010000L));
}
inline int
isideogram(int _c)
{
return (__istype(_c, 0x00080000L));
}
inline int
isnumber(int _c)
{
return (__istype(_c, 0x00000400L));
}
inline int
isphonogram(int _c)
{
return (__istype(_c, 0x00200000L));
}
inline int
isrune(int _c)
{
return (__istype(_c, 0xFFFFFFF0L));
}
inline int
isspecial(int _c)
{
return (__istype(_c, 0x00100000L));
}
extern "C" {
extern int * __error(void);
}
struct lconv {
char *decimal_point;
char *thousands_sep;
char *grouping;
char *int_curr_symbol;
char *currency_symbol;
char *mon_decimal_point;
char *mon_thousands_sep;
char *mon_grouping;
char *positive_sign;
char *negative_sign;
char int_frac_digits;
char frac_digits;
char p_cs_precedes;
char p_sep_by_space;
char n_cs_precedes;
char n_sep_by_space;
char p_sign_posn;
char n_sign_posn;
char int_p_cs_precedes;
char int_n_cs_precedes;
char int_p_sep_by_space;
char int_n_sep_by_space;
char int_p_sign_posn;
char int_n_sign_posn;
};
extern "C" {
struct lconv *localeconv(void);
}
extern "C" {
char *setlocale(int, const char *);
}
extern "C" {
typedef float float_t;
typedef double double_t;
extern int __math_errhandling(void);
extern int __fpclassifyf(float);
extern int __fpclassifyd(double);
extern int __fpclassifyl(long double);
inline __attribute__ ((__always_inline__)) int __inline_isfinitef(float);
inline __attribute__ ((__always_inline__)) int __inline_isfinited(double);
inline __attribute__ ((__always_inline__)) int __inline_isfinitel(long double);
inline __attribute__ ((__always_inline__)) int __inline_isinff(float);
inline __attribute__ ((__always_inline__)) int __inline_isinfd(double);
inline __attribute__ ((__always_inline__)) int __inline_isinfl(long double);
inline __attribute__ ((__always_inline__)) int __inline_isnanf(float);
inline __attribute__ ((__always_inline__)) int __inline_isnand(double);
inline __attribute__ ((__always_inline__)) int __inline_isnanl(long double);
inline __attribute__ ((__always_inline__)) int __inline_isnormalf(float);
inline __attribute__ ((__always_inline__)) int __inline_isnormald(double);
inline __attribute__ ((__always_inline__)) int __inline_isnormall(long double);
inline __attribute__ ((__always_inline__)) int __inline_signbitf(float);
inline __attribute__ ((__always_inline__)) int __inline_signbitd(double);
inline __attribute__ ((__always_inline__)) int __inline_signbitl(long double);
inline __attribute__ ((__always_inline__)) int __inline_isfinitef(float __x) {
return __x == __x && __builtin_fabsf(__x) != __builtin_inff();
}
inline __attribute__ ((__always_inline__)) int __inline_isfinited(double __x) {
return __x == __x && __builtin_fabs(__x) != __builtin_inf();
}
inline __attribute__ ((__always_inline__)) int __inline_isfinitel(long double __x) {
return __x == __x && __builtin_fabsl(__x) != __builtin_infl();
}
inline __attribute__ ((__always_inline__)) int __inline_isinff(float __x) {
return __builtin_fabsf(__x) == __builtin_inff();
}
inline __attribute__ ((__always_inline__)) int __inline_isinfd(double __x) {
return __builtin_fabs(__x) == __builtin_inf();
}
inline __attribute__ ((__always_inline__)) int __inline_isinfl(long double __x) {
return __builtin_fabsl(__x) == __builtin_infl();
}
inline __attribute__ ((__always_inline__)) int __inline_isnanf(float __x) {
return __x != __x;
}
inline __attribute__ ((__always_inline__)) int __inline_isnand(double __x) {
return __x != __x;
}
inline __attribute__ ((__always_inline__)) int __inline_isnanl(long double __x) {
return __x != __x;
}
inline __attribute__ ((__always_inline__)) int __inline_signbitf(float __x) {
union { float __f; unsigned int __u; } __u;
__u.__f = __x;
return (int)(__u.__u >> 31);
}
inline __attribute__ ((__always_inline__)) int __inline_signbitd(double __x) {
union { double __f; unsigned long long __u; } __u;
__u.__f = __x;
return (int)(__u.__u >> 63);
}
inline __attribute__ ((__always_inline__)) int __inline_signbitl(long double __x) {
union {
long double __ld;
struct{ unsigned long long __m; unsigned short __sexp; } __p;
} __u;
__u.__ld = __x;
return (int)(__u.__p.__sexp >> 15);
}
inline __attribute__ ((__always_inline__)) int __inline_isnormalf(float __x) {
return __inline_isfinitef(__x) && __builtin_fabsf(__x) >= 1.17549435e-38F;
}
inline __attribute__ ((__always_inline__)) int __inline_isnormald(double __x) {
return __inline_isfinited(__x) && __builtin_fabs(__x) >= 2.2250738585072014e-308;
}
inline __attribute__ ((__always_inline__)) int __inline_isnormall(long double __x) {
return __inline_isfinitel(__x) && __builtin_fabsl(__x) >= 3.36210314311209350626e-4932L;
}
extern float acosf(float);
extern double acos(double);
extern long double acosl(long double);
extern float asinf(float);
extern double asin(double);
extern long double asinl(long double);
extern float atanf(float);
extern double atan(double);
extern long double atanl(long double);
extern float atan2f(float, float);
extern double atan2(double, double);
extern long double atan2l(long double, long double);
extern float cosf(float);
extern double cos(double);
extern long double cosl(long double);
extern float sinf(float);
extern double sin(double);
extern long double sinl(long double);
extern float tanf(float);
extern double tan(double);
extern long double tanl(long double);
extern float acoshf(float);
extern double acosh(double);
extern long double acoshl(long double);
extern float asinhf(float);
extern double asinh(double);
extern long double asinhl(long double);
extern float atanhf(float);
extern double atanh(double);
extern long double atanhl(long double);
extern float coshf(float);
extern double cosh(double);
extern long double coshl(long double);
extern float sinhf(float);
extern double sinh(double);
extern long double sinhl(long double);
extern float tanhf(float);
extern double tanh(double);
extern long double tanhl(long double);
extern float expf(float);
extern double exp(double);
extern long double expl(long double);
extern float exp2f(float);
extern double exp2(double);
extern long double exp2l(long double);
extern float expm1f(float);
extern double expm1(double);
extern long double expm1l(long double);
extern float logf(float);
extern double log(double);
extern long double logl(long double);
extern float log10f(float);
extern double log10(double);
extern long double log10l(long double);
extern float log2f(float);
extern double log2(double);
extern long double log2l(long double);
extern float log1pf(float);
extern double log1p(double);
extern long double log1pl(long double);
extern float logbf(float);
extern double logb(double);
extern long double logbl(long double);
extern float modff(float, float *);
extern double modf(double, double *);
extern long double modfl(long double, long double *);
extern float ldexpf(float, int);
extern double ldexp(double, int);
extern long double ldexpl(long double, int);
extern float frexpf(float, int *);
extern double frexp(double, int *);
extern long double frexpl(long double, int *);
extern int ilogbf(float);
extern int ilogb(double);
extern int ilogbl(long double);
extern float scalbnf(float, int);
extern double scalbn(double, int);
extern long double scalbnl(long double, int);
extern float scalblnf(float, long int);
extern double scalbln(double, long int);
extern long double scalblnl(long double, long int);
extern float fabsf(float);
extern double fabs(double);
extern long double fabsl(long double);
extern float cbrtf(float);
extern double cbrt(double);
extern long double cbrtl(long double);
extern float hypotf(float, float);
extern double hypot(double, double);
extern long double hypotl(long double, long double);
extern float powf(float, float);
extern double pow(double, double);
extern long double powl(long double, long double);
extern float sqrtf(float);
extern double sqrt(double);
extern long double sqrtl(long double);
extern float erff(float);
extern double erf(double);
extern long double erfl(long double);
extern float erfcf(float);
extern double erfc(double);
extern long double erfcl(long double);
extern float lgammaf(float);
extern double lgamma(double);
extern long double lgammal(long double);
extern float tgammaf(float);
extern double tgamma(double);
extern long double tgammal(long double);
extern float ceilf(float);
extern double ceil(double);
extern long double ceill(long double);
extern float floorf(float);
extern double floor(double);
extern long double floorl(long double);
extern float nearbyintf(float);
extern double nearbyint(double);
extern long double nearbyintl(long double);
extern float rintf(float);
extern double rint(double);
extern long double rintl(long double);
extern long int lrintf(float);
extern long int lrint(double);
extern long int lrintl(long double);
extern float roundf(float);
extern double round(double);
extern long double roundl(long double);
extern long int lroundf(float);
extern long int lround(double);
extern long int lroundl(long double);
extern long long int llrintf(float);
extern long long int llrint(double);
extern long long int llrintl(long double);
extern long long int llroundf(float);
extern long long int llround(double);
extern long long int llroundl(long double);
extern float truncf(float);
extern double trunc(double);
extern long double truncl(long double);
extern float fmodf(float, float);
extern double fmod(double, double);
extern long double fmodl(long double, long double);
extern float remainderf(float, float);
extern double remainder(double, double);
extern long double remainderl(long double, long double);
extern float remquof(float, float, int *);
extern double remquo(double, double, int *);
extern long double remquol(long double, long double, int *);
extern float copysignf(float, float);
extern double copysign(double, double);
extern long double copysignl(long double, long double);
extern float nanf(const char *);
extern double nan(const char *);
extern long double nanl(const char *);
extern float nextafterf(float, float);
extern double nextafter(double, double);
extern long double nextafterl(long double, long double);
extern double nexttoward(double, long double);
extern float nexttowardf(float, long double);
extern long double nexttowardl(long double, long double);
extern float fdimf(float, float);
extern double fdim(double, double);
extern long double fdiml(long double, long double);
extern float fmaxf(float, float);
extern double fmax(double, double);
extern long double fmaxl(long double, long double);
extern float fminf(float, float);
extern double fmin(double, double);
extern long double fminl(long double, long double);
extern float fmaf(float, float, float);
extern double fma(double, double, double);
extern long double fmal(long double, long double, long double);
extern float __inff(void) __attribute__((availability(macosx,introduced=10.0,deprecated=10.9)));
extern double __inf(void) __attribute__((availability(macosx,introduced=10.0,deprecated=10.9)));
extern long double __infl(void) __attribute__((availability(macosx,introduced=10.0,deprecated=10.9)));
extern float __nan(void) __attribute__((availability(macosx,introduced=10.0)));
extern float __exp10f(float) __attribute__((availability(macosx,introduced=10.9)));
extern double __exp10(double) __attribute__((availability(macosx,introduced=10.9)));
inline __attribute__ ((__always_inline__)) void __sincosf(float __x, float *__sinp, float *__cosp) __attribute__((availability(macosx,introduced=10.9)));
inline __attribute__ ((__always_inline__)) void __sincos(double __x, double *__sinp, double *__cosp) __attribute__((availability(macosx,introduced=10.9)));
extern float __cospif(float) __attribute__((availability(macosx,introduced=10.9)));
extern double __cospi(double) __attribute__((availability(macosx,introduced=10.9)));
extern float __sinpif(float) __attribute__((availability(macosx,introduced=10.9)));
extern double __sinpi(double) __attribute__((availability(macosx,introduced=10.9)));
extern float __tanpif(float) __attribute__((availability(macosx,introduced=10.9)));
extern double __tanpi(double) __attribute__((availability(macosx,introduced=10.9)));
inline __attribute__ ((__always_inline__)) void __sincospif(float __x, float *__sinp, float *__cosp) __attribute__((availability(macosx,introduced=10.9)));
inline __attribute__ ((__always_inline__)) void __sincospi(double __x, double *__sinp, double *__cosp) __attribute__((availability(macosx,introduced=10.9)));
struct __float2 { float __sinval; float __cosval; };
struct __double2 { double __sinval; double __cosval; };
extern struct __float2 __sincosf_stret(float);
extern struct __double2 __sincos_stret(double);
extern struct __float2 __sincospif_stret(float);
extern struct __double2 __sincospi_stret(double);
inline __attribute__ ((__always_inline__)) void __sincosf(float __x, float *__sinp, float *__cosp) {
const struct __float2 __stret = __sincosf_stret(__x);
*__sinp = __stret.__sinval; *__cosp = __stret.__cosval;
}
inline __attribute__ ((__always_inline__)) void __sincos(double __x, double *__sinp, double *__cosp) {
const struct __double2 __stret = __sincos_stret(__x);
*__sinp = __stret.__sinval; *__cosp = __stret.__cosval;
}
inline __attribute__ ((__always_inline__)) void __sincospif(float __x, float *__sinp, float *__cosp) {
const struct __float2 __stret = __sincospif_stret(__x);
*__sinp = __stret.__sinval; *__cosp = __stret.__cosval;
}
inline __attribute__ ((__always_inline__)) void __sincospi(double __x, double *__sinp, double *__cosp) {
const struct __double2 __stret = __sincospi_stret(__x);
*__sinp = __stret.__sinval; *__cosp = __stret.__cosval;
}
extern double j0(double) __attribute__((availability(macosx,introduced=10.0)));
extern double j1(double) __attribute__((availability(macosx,introduced=10.0)));
extern double jn(int, double) __attribute__((availability(macosx,introduced=10.0)));
extern double y0(double) __attribute__((availability(macosx,introduced=10.0)));
extern double y1(double) __attribute__((availability(macosx,introduced=10.0)));
extern double yn(int, double) __attribute__((availability(macosx,introduced=10.0)));
extern double scalb(double, double);
extern int signgam;
extern long int rinttol(double) __attribute__((availability(macosx,introduced=10.0,deprecated=10.9)));
extern long int roundtol(double) __attribute__((availability(macosx,introduced=10.0,deprecated=10.9)));
extern double drem(double, double) __attribute__((availability(macosx,introduced=10.0,deprecated=10.9)));
extern int finite(double) __attribute__((availability(macosx,introduced=10.0,deprecated=10.9)));
extern double gamma(double) __attribute__((availability(macosx,introduced=10.0,deprecated=10.9)));
extern double significand(double) __attribute__((availability(macosx,introduced=10.0,deprecated=10.9)));
}
typedef int jmp_buf[((9 * 2) + 3 + 16)];
typedef int sigjmp_buf[((9 * 2) + 3 + 16) + 1];
extern "C" {
extern int setjmp(jmp_buf);
extern void longjmp(jmp_buf, int) __attribute__((noreturn));
int _setjmp(jmp_buf);
void _longjmp(jmp_buf, int) __attribute__((noreturn));
int sigsetjmp(sigjmp_buf, int);
void siglongjmp(sigjmp_buf, int) __attribute__((noreturn));
void longjmperror(void);
}
extern const char *const sys_signame[32];
extern const char *const sys_siglist[32];
extern "C" {
int raise(int);
}
extern "C" {
void (*bsd_signal(int, void (*)(int)))(int);
int kill(pid_t, int) __asm("_" "kill" );
int killpg(pid_t, int) __asm("_" "killpg" );
int pthread_kill(pthread_t, int);
int pthread_sigmask(int, const sigset_t *, sigset_t *) __asm("_" "pthread_sigmask" );
int sigaction(int, const struct sigaction * ,
struct sigaction * );
int sigaddset(sigset_t *, int);
int sigaltstack(const stack_t * , stack_t * ) __asm("_" "sigaltstack" );
int sigdelset(sigset_t *, int);
int sigemptyset(sigset_t *);
int sigfillset(sigset_t *);
int sighold(int);
int sigignore(int);
int siginterrupt(int, int);
int sigismember(const sigset_t *, int);
int sigpause(int) __asm("_" "sigpause" );
int sigpending(sigset_t *);
int sigprocmask(int, const sigset_t * , sigset_t * );
int sigrelse(int);
void (*sigset(int, void (*)(int)))(int);
int sigsuspend(const sigset_t *) __asm("_" "sigsuspend" );
int sigwait(const sigset_t * , int * ) __asm("_" "sigwait" );
void psignal(unsigned int, const char *);
int sigblock(int);
int sigsetmask(int);
int sigvec(int, struct sigvec *, struct sigvec *);
}
inline __attribute__ ((__always_inline__)) int
__sigbits(int __signo)
{
return __signo > 32 ? 0 : (1 << (__signo - 1));
}
typedef long int ptrdiff_t;
typedef __darwin_va_list va_list;
extern "C" {
int renameat(int, const char *, int, const char *) __attribute__((availability(macosx,introduced=10.10)));
}
typedef __darwin_off_t fpos_t;
struct __sbuf {
unsigned char *_base;
int _size;
};
struct __sFILEX;
typedef struct __sFILE {
unsigned char *_p;
int _r;
int _w;
short _flags;
short _file;
struct __sbuf _bf;
int _lbfsize;
void *_cookie;
int (*_close)(void *);
int (*_read) (void *, char *, int);
fpos_t (*_seek) (void *, fpos_t, int);
int (*_write)(void *, const char *, int);
struct __sbuf _ub;
struct __sFILEX *_extra;
int _ur;
unsigned char _ubuf[3];
unsigned char _nbuf[1];
struct __sbuf _lb;
int _blksize;
fpos_t _offset;
} FILE;
extern "C" {
extern FILE *__stdinp;
extern FILE *__stdoutp;
extern FILE *__stderrp;
}
extern "C" {
void clearerr(FILE *);
int fclose(FILE *);
int feof(FILE *);
int ferror(FILE *);
int fflush(FILE *);
int fgetc(FILE *);
int fgetpos(FILE * , fpos_t *);
char *fgets(char * , int, FILE *);
FILE *fopen(const char * , const char * ) __asm("_" "fopen" );
int fprintf(FILE * , const char * , ...) __attribute__((__format__ (__printf__, 2, 3)));
int fputc(int, FILE *);
int fputs(const char * , FILE * ) __asm("_" "fputs" );
size_t fread(void * , size_t, size_t, FILE * );
FILE *freopen(const char * , const char * ,
FILE * ) __asm("_" "freopen" );
int fscanf(FILE * , const char * , ...) __attribute__((__format__ (__scanf__, 2, 3)));
int fseek(FILE *, long, int);
int fsetpos(FILE *, const fpos_t *);
long ftell(FILE *);
size_t fwrite(const void * , size_t, size_t, FILE * ) __asm("_" "fwrite" );
int getc(FILE *);
int getchar(void);
char *gets(char *);
void perror(const char *);
int printf(const char * , ...) __attribute__((__format__ (__printf__, 1, 2)));
int putc(int, FILE *);
int putchar(int);
int puts(const char *);
int remove(const char *);
int rename (const char *, const char *);
void rewind(FILE *);
int scanf(const char * , ...) __attribute__((__format__ (__scanf__, 1, 2)));
void setbuf(FILE * , char * );
int setvbuf(FILE * , char * , int, size_t);
int sprintf(char * , const char * , ...) __attribute__((__format__ (__printf__, 2, 3)));
int sscanf(const char * , const char * , ...) __attribute__((__format__ (__scanf__, 2, 3)));
FILE *tmpfile(void);
__attribute__((deprecated("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of tmpnam(3), it is highly recommended that you use mkstemp(3) instead.")))
char *tmpnam(char *);
int ungetc(int, FILE *);
int vfprintf(FILE * , const char * , va_list) __attribute__((__format__ (__printf__, 2, 0)));
int vprintf(const char * , va_list) __attribute__((__format__ (__printf__, 1, 0)));
int vsprintf(char * , const char * , va_list) __attribute__((__format__ (__printf__, 2, 0)));
}
extern "C" {
char *ctermid(char *);
FILE *fdopen(int, const char *) __asm("_" "fdopen" );
int fileno(FILE *);
}
extern "C" {
int pclose(FILE *);
FILE *popen(const char *, const char *) __asm("_" "popen" );
}
extern "C" {
int __srget(FILE *);
int __svfscanf(FILE *, const char *, va_list) __attribute__((__format__ (__scanf__, 2, 0)));
int __swbuf(int, FILE *);
}
inline __attribute__ ((__always_inline__)) int __sputc(int _c, FILE *_p) {
if (--_p->_w >= 0 || (_p->_w >= _p->_lbfsize && (char)_c != '\n'))
return (*_p->_p++ = _c);
else
return (__swbuf(_c, _p));
}
extern "C" {
void flockfile(FILE *);
int ftrylockfile(FILE *);
void funlockfile(FILE *);
int getc_unlocked(FILE *);
int getchar_unlocked(void);
int putc_unlocked(int, FILE *);
int putchar_unlocked(int);
int getw(FILE *);
int putw(int, FILE *);
__attribute__((deprecated("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of tempnam(3), it is highly recommended that you use mkstemp(3) instead.")))
char *tempnam(const char *, const char *) __asm("_" "tempnam" );
}
extern "C" {
int fseeko(FILE *, off_t, int);
off_t ftello(FILE *);
}
extern "C" {
int snprintf(char * , size_t, const char * , ...) __attribute__((__format__ (__printf__, 3, 4)));
int vfscanf(FILE * , const char * , va_list) __attribute__((__format__ (__scanf__, 2, 0)));
int vscanf(const char * , va_list) __attribute__((__format__ (__scanf__, 1, 0)));
int vsnprintf(char * , size_t, const char * , va_list) __attribute__((__format__ (__printf__, 3, 0)));
int vsscanf(const char * , const char * , va_list) __attribute__((__format__ (__scanf__, 2, 0)));
}
extern "C" {
int dprintf(int, const char * , ...) __attribute__((__format__ (__printf__, 2, 3))) __attribute__((availability(macosx,introduced=10.7)));
int vdprintf(int, const char * , va_list) __attribute__((__format__ (__printf__, 2, 0))) __attribute__((availability(macosx,introduced=10.7)));
ssize_t getdelim(char ** , size_t * , int, FILE * ) __attribute__((availability(macosx,introduced=10.7)));
ssize_t getline(char ** , size_t * , FILE * ) __attribute__((availability(macosx,introduced=10.7)));
}
extern "C" {
extern const int sys_nerr;
extern const char *const sys_errlist[];
int asprintf(char ** , const char * , ...) __attribute__((__format__ (__printf__, 2, 3)));
char *ctermid_r(char *);
char *fgetln(FILE *, size_t *);
const char *fmtcheck(const char *, const char *);
int fpurge(FILE *);
void setbuffer(FILE *, char *, int);
int setlinebuf(FILE *);
int vasprintf(char ** , const char * , va_list) __attribute__((__format__ (__printf__, 2, 0)));
FILE *zopen(const char *, const char *, int);
FILE *funopen(const void *,
int (*)(void *, char *, int),
int (*)(void *, const char *, int),
fpos_t (*)(void *, fpos_t, int),
int (*)(void *));
}
extern "C" {
void *memchr(const void *, int, size_t);
int memcmp(const void *, const void *, size_t);
void *memcpy(void *, const void *, size_t);
void *memmove(void *, const void *, size_t);
void *memset(void *, int, size_t);
char *strcat(char *, const char *);
char *strchr(const char *, int);
int strcmp(const char *, const char *);
int strcoll(const char *, const char *);
char *strcpy(char *, const char *);
size_t strcspn(const char *, const char *);
char *strerror(int) __asm("_" "strerror" );
size_t strlen(const char *);
char *strncat(char *, const char *, size_t);
int strncmp(const char *, const char *, size_t);
char *strncpy(char *, const char *, size_t);
char *strpbrk(const char *, const char *);
char *strrchr(const char *, int);
size_t strspn(const char *, const char *);
char *strstr(const char *, const char *);
char *strtok(char *, const char *);
size_t strxfrm(char *, const char *, size_t);
}
extern "C" {
char *strtok_r(char *, const char *, char **);
}
extern "C" {
int strerror_r(int, char *, size_t);
char *strdup(const char *);
void *memccpy(void *, const void *, int, size_t);
}
extern "C" {
char *stpcpy(char *, const char *);
char *stpncpy(char *, const char *, size_t) __attribute__((availability(macosx,introduced=10.7)));
char *strndup(const char *, size_t) __attribute__((availability(macosx,introduced=10.7)));
size_t strnlen(const char *, size_t) __attribute__((availability(macosx,introduced=10.7)));
char *strsignal(int sig);
}
extern "C" {
errno_t memset_s(void *, rsize_t, int, rsize_t) __attribute__((availability(macosx,introduced=10.9)));
}
extern "C" {
void *memmem(const void *, size_t, const void *, size_t) __attribute__((availability(macosx,introduced=10.7)));
void memset_pattern4(void *, const void *, size_t) __attribute__((availability(macosx,introduced=10.5)));
void memset_pattern8(void *, const void *, size_t) __attribute__((availability(macosx,introduced=10.5)));
void memset_pattern16(void *, const void *, size_t) __attribute__((availability(macosx,introduced=10.5)));
char *strcasestr(const char *, const char *);
char *strnstr(const char *, const char *, size_t);
size_t strlcat(char *, const char *, size_t);
size_t strlcpy(char *, const char *, size_t);
void strmode(int, char *);
char *strsep(char **, const char *);
void swab(const void * , void * , ssize_t);
}
extern "C" {
int bcmp(const void *, const void *, size_t) ;
void bcopy(const void *, void *, size_t) ;
void bzero(void *, size_t) ;
char *index(const char *, int) ;
char *rindex(const char *, int) ;
int ffs(int);
int strcasecmp(const char *, const char *);
int strncasecmp(const char *, const char *, size_t);
}
extern "C" {
int ffsl(long) __attribute__((availability(macosx,introduced=10.5)));
int ffsll(long long) __attribute__((availability(macosx,introduced=10.9)));
int fls(int) __attribute__((availability(macosx,introduced=10.5)));
int flsl(long) __attribute__((availability(macosx,introduced=10.5)));
int flsll(long long) __attribute__((availability(macosx,introduced=10.9)));
}
struct timespec
{
__darwin_time_t tv_sec;
long tv_nsec;
};
struct tm {
int tm_sec;
int tm_min;
int tm_hour;
int tm_mday;
int tm_mon;
int tm_year;
int tm_wday;
int tm_yday;
int tm_isdst;
long tm_gmtoff;
char *tm_zone;
};
extern char *tzname[];
extern int getdate_err;
extern long timezone __asm("_" "timezone" );
extern int daylight;
extern "C" {
char *asctime(const struct tm *);
clock_t clock(void) __asm("_" "clock" );
char *ctime(const time_t *);
double difftime(time_t, time_t);
struct tm *getdate(const char *);
struct tm *gmtime(const time_t *);
struct tm *localtime(const time_t *);
time_t mktime(struct tm *) __asm("_" "mktime" );
size_t strftime(char * , size_t, const char * , const struct tm * ) __asm("_" "strftime" );
char *strptime(const char * , const char * , struct tm * ) __asm("_" "strptime" );
time_t time(time_t *);
void tzset(void);
char *asctime_r(const struct tm * , char * );
char *ctime_r(const time_t *, char *);
struct tm *gmtime_r(const time_t * , struct tm * );
struct tm *localtime_r(const time_t * , struct tm * );
time_t posix2time(time_t);
void tzsetwall(void);
time_t time2posix(time_t);
time_t timelocal(struct tm * const);
time_t timegm(struct tm * const);
int nanosleep(const struct timespec *, struct timespec *) __asm("_" "nanosleep" );
}
extern "C" {
extern "C" void *_Block_copy(const void *aBlock)
__attribute__((availability(macosx,introduced=10.6)));
extern "C" void _Block_release(const void *aBlock)
__attribute__((availability(macosx,introduced=10.6)));
extern "C" void _Block_object_assign(void *, const void *, const int)
__attribute__((availability(macosx,introduced=10.6)));
extern "C" void _Block_object_dispose(const void *, const int)
__attribute__((availability(macosx,introduced=10.6)));
extern "C" void * _NSConcreteGlobalBlock[32]
__attribute__((availability(macosx,introduced=10.6)));
extern "C" void * _NSConcreteStackBlock[32]
__attribute__((availability(macosx,introduced=10.6)));
}
extern "C" {
#pragma pack(push, 2)
typedef unsigned char UInt8;
typedef signed char SInt8;
typedef unsigned short UInt16;
typedef signed short SInt16;
typedef unsigned int UInt32;
typedef signed int SInt32;
struct wide {
UInt32 lo;
SInt32 hi;
};
typedef struct wide wide;
struct UnsignedWide {
UInt32 lo;
UInt32 hi;
};
typedef struct UnsignedWide UnsignedWide;
typedef signed long long SInt64;
typedef unsigned long long UInt64;
typedef SInt32 Fixed;
typedef Fixed * FixedPtr;
typedef SInt32 Fract;
typedef Fract * FractPtr;
typedef UInt32 UnsignedFixed;
typedef UnsignedFixed * UnsignedFixedPtr;
typedef short ShortFixed;
typedef ShortFixed * ShortFixedPtr;
typedef float Float32;
typedef double Float64;
struct Float80 {
SInt16 exp;
UInt16 man[4];
};
typedef struct Float80 Float80;
struct Float96 {
SInt16 exp[2];
UInt16 man[4];
};
typedef struct Float96 Float96;
struct Float32Point {
Float32 x;
Float32 y;
};
typedef struct Float32Point Float32Point;
typedef char * Ptr;
typedef Ptr * Handle;
typedef long Size;
typedef SInt16 OSErr;
typedef SInt32 OSStatus;
typedef void * LogicalAddress;
typedef const void * ConstLogicalAddress;
typedef void * PhysicalAddress;
typedef UInt8 * BytePtr;
typedef unsigned long ByteCount;
typedef unsigned long ByteOffset;
typedef SInt32 Duration;
typedef UnsignedWide AbsoluteTime;
typedef UInt32 OptionBits;
typedef unsigned long ItemCount;
typedef UInt32 PBVersion;
typedef SInt16 ScriptCode;
typedef SInt16 LangCode;
typedef SInt16 RegionCode;
typedef UInt32 FourCharCode;
typedef FourCharCode OSType;
typedef FourCharCode ResType;
typedef OSType * OSTypePtr;
typedef ResType * ResTypePtr;
typedef unsigned char Boolean;
typedef long ( * ProcPtr)();
typedef void ( * Register68kProcPtr)();
typedef ProcPtr UniversalProcPtr;
typedef ProcPtr * ProcHandle;
typedef UniversalProcPtr * UniversalProcHandle;
typedef void * PRefCon;
typedef void * URefCon;
typedef void * SRefCon;
enum {
noErr = 0
};
enum {
kNilOptions = 0
};
enum {
kVariableLengthArray
__attribute__((deprecated))
= 1
};
enum {
kUnknownType = 0x3F3F3F3F
};
typedef UInt32 UnicodeScalarValue;
typedef UInt32 UTF32Char;
typedef UInt16 UniChar;
typedef UInt16 UTF16Char;
typedef UInt8 UTF8Char;
typedef UniChar * UniCharPtr;
typedef unsigned long UniCharCount;
typedef UniCharCount * UniCharCountPtr;
typedef unsigned char Str255[256];
typedef unsigned char Str63[64];
typedef unsigned char Str32[33];
typedef unsigned char Str31[32];
typedef unsigned char Str27[28];
typedef unsigned char Str15[16];
typedef unsigned char Str32Field[34];
typedef Str63 StrFileName;
typedef unsigned char * StringPtr;
typedef StringPtr * StringHandle;
typedef const unsigned char * ConstStringPtr;
typedef const unsigned char * ConstStr255Param;
typedef const unsigned char * ConstStr63Param;
typedef const unsigned char * ConstStr32Param;
typedef const unsigned char * ConstStr31Param;
typedef const unsigned char * ConstStr27Param;
typedef const unsigned char * ConstStr15Param;
typedef ConstStr63Param ConstStrFileNameParam;
inline unsigned char StrLength(ConstStr255Param string) { return (*string); }
struct ProcessSerialNumber {
UInt32 highLongOfPSN;
UInt32 lowLongOfPSN;
};
typedef struct ProcessSerialNumber ProcessSerialNumber;
typedef ProcessSerialNumber * ProcessSerialNumberPtr;
struct Point {
short v;
short h;
};
typedef struct Point Point;
typedef Point * PointPtr;
struct Rect {
short top;
short left;
short bottom;
short right;
};
typedef struct Rect Rect;
typedef Rect * RectPtr;
struct FixedPoint {
Fixed x;
Fixed y;
};
typedef struct FixedPoint FixedPoint;
struct FixedRect {
Fixed left;
Fixed top;
Fixed right;
Fixed bottom;
};
typedef struct FixedRect FixedRect;
typedef short CharParameter;
enum {
normal = 0,
bold = 1,
italic = 2,
underline = 4,
outline = 8,
shadow = 0x10,
condense = 0x20,
extend = 0x40
};
typedef unsigned char Style;
typedef short StyleParameter;
typedef Style StyleField;
typedef SInt32 TimeValue;
typedef SInt32 TimeScale;
typedef wide CompTimeValue;
typedef SInt64 TimeValue64;
typedef struct TimeBaseRecord* TimeBase;
struct TimeRecord {
CompTimeValue value;
TimeScale scale;
TimeBase base;
};
typedef struct TimeRecord TimeRecord;
struct NumVersion {
UInt8 nonRelRev;
UInt8 stage;
UInt8 minorAndBugRev;
UInt8 majorRev;
};
typedef struct NumVersion NumVersion;
enum {
developStage = 0x20,
alphaStage = 0x40,
betaStage = 0x60,
finalStage = 0x80
};
union NumVersionVariant {
NumVersion parts;
UInt32 whole;
};
typedef union NumVersionVariant NumVersionVariant;
typedef NumVersionVariant * NumVersionVariantPtr;
typedef NumVersionVariantPtr * NumVersionVariantHandle;
struct VersRec {
NumVersion numericVersion;
short countryCode;
Str255 shortVersion;
Str255 reserved;
};
typedef struct VersRec VersRec;
typedef VersRec * VersRecPtr;
typedef VersRecPtr * VersRecHndl;
typedef UInt8 Byte;
typedef SInt8 SignedByte;
typedef wide * WidePtr;
typedef UnsignedWide * UnsignedWidePtr;
typedef Float80 extended80;
typedef Float96 extended96;
typedef SInt8 VHSelect;
extern void
Debugger(void) __attribute__((availability(macosx,introduced=10.0,deprecated=10.8)));
extern void
DebugStr(ConstStr255Param debuggerMsg) __attribute__((availability(macosx,introduced=10.0,deprecated=10.8)));
extern void
SysBreak(void) __attribute__((availability(macosx,introduced=10.0,deprecated=10.8)));
extern void
SysBreakStr(ConstStr255Param debuggerMsg) __attribute__((availability(macosx,introduced=10.0,deprecated=10.8)));
extern void
SysBreakFunc(ConstStr255Param debuggerMsg) __attribute__((availability(macosx,introduced=10.0,deprecated=10.8)));
#pragma pack(pop)
}
extern "C" {
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
// @class NSAttributedString;
#ifndef _REWRITER_typedef_NSAttributedString
#define _REWRITER_typedef_NSAttributedString
typedef struct objc_object NSAttributedString;
typedef struct {} _objc_exc_NSAttributedString;
#endif
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
// @class NSNull;
#ifndef _REWRITER_typedef_NSNull
#define _REWRITER_typedef_NSNull
typedef struct objc_object NSNull;
typedef struct {} _objc_exc_NSNull;
#endif
// @class NSCharacterSet;
#ifndef _REWRITER_typedef_NSCharacterSet
#define _REWRITER_typedef_NSCharacterSet
typedef struct objc_object NSCharacterSet;
typedef struct {} _objc_exc_NSCharacterSet;
#endif
// @class NSData;
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
// @class NSDate;
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
// @class NSTimeZone;
#ifndef _REWRITER_typedef_NSTimeZone
#define _REWRITER_typedef_NSTimeZone
typedef struct objc_object NSTimeZone;
typedef struct {} _objc_exc_NSTimeZone;
#endif
// @class NSDictionary;
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
// @class NSError;
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
// @class NSLocale;
#ifndef _REWRITER_typedef_NSLocale
#define _REWRITER_typedef_NSLocale
typedef struct objc_object NSLocale;
typedef struct {} _objc_exc_NSLocale;
#endif
// @class NSNumber;
#ifndef _REWRITER_typedef_NSNumber
#define _REWRITER_typedef_NSNumber
typedef struct objc_object NSNumber;
typedef struct {} _objc_exc_NSNumber;
#endif
// @class NSNumber;
#ifndef _REWRITER_typedef_NSNumber
#define _REWRITER_typedef_NSNumber
typedef struct objc_object NSNumber;
typedef struct {} _objc_exc_NSNumber;
#endif
// @class NSSet;
#ifndef _REWRITER_typedef_NSSet
#define _REWRITER_typedef_NSSet
typedef struct objc_object NSSet;
typedef struct {} _objc_exc_NSSet;
#endif
// @class NSURL;
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
extern double kCFCoreFoundationVersionNumber;
typedef unsigned long CFTypeID;
typedef unsigned long CFOptionFlags;
typedef unsigned long CFHashCode;
typedef signed long CFIndex;
typedef const void * CFTypeRef;
typedef const struct __attribute__((objc_bridge(NSString))) __CFString * CFStringRef;
typedef struct __attribute__((objc_bridge_mutable(NSMutableString))) __CFString * CFMutableStringRef;
typedef CFTypeRef CFPropertyListRef;
typedef CFIndex CFComparisonResult; enum {
kCFCompareLessThan = -1L,
kCFCompareEqualTo = 0,
kCFCompareGreaterThan = 1
};
typedef CFComparisonResult (*CFComparatorFunction)(const void *val1, const void *val2, void *context);
enum {
kCFNotFound = -1
};
typedef struct {
CFIndex location;
CFIndex length;
} CFRange;
static __inline__ __attribute__((always_inline)) CFRange CFRangeMake(CFIndex loc, CFIndex len) {
CFRange range;
range.location = loc;
range.length = len;
return range;
}
extern
CFRange __CFRangeMake(CFIndex loc, CFIndex len);
typedef const struct __attribute__((objc_bridge(NSNull))) __CFNull * CFNullRef;
extern
CFTypeID CFNullGetTypeID(void);
extern
const CFNullRef kCFNull;
typedef const struct __CFAllocator * CFAllocatorRef;
extern
const CFAllocatorRef kCFAllocatorDefault;
extern
const CFAllocatorRef kCFAllocatorSystemDefault;
extern
const CFAllocatorRef kCFAllocatorMalloc;
extern
const CFAllocatorRef kCFAllocatorMallocZone;
extern
const CFAllocatorRef kCFAllocatorNull;
extern
const CFAllocatorRef kCFAllocatorUseContext;
typedef const void * (*CFAllocatorRetainCallBack)(const void *info);
typedef void (*CFAllocatorReleaseCallBack)(const void *info);
typedef CFStringRef (*CFAllocatorCopyDescriptionCallBack)(const void *info);
typedef void * (*CFAllocatorAllocateCallBack)(CFIndex allocSize, CFOptionFlags hint, void *info);
typedef void * (*CFAllocatorReallocateCallBack)(void *ptr, CFIndex newsize, CFOptionFlags hint, void *info);
typedef void (*CFAllocatorDeallocateCallBack)(void *ptr, void *info);
typedef CFIndex (*CFAllocatorPreferredSizeCallBack)(CFIndex size, CFOptionFlags hint, void *info);
typedef struct {
CFIndex version;
void * info;
CFAllocatorRetainCallBack retain;
CFAllocatorReleaseCallBack release;
CFAllocatorCopyDescriptionCallBack copyDescription;
CFAllocatorAllocateCallBack allocate;
CFAllocatorReallocateCallBack reallocate;
CFAllocatorDeallocateCallBack deallocate;
CFAllocatorPreferredSizeCallBack preferredSize;
} CFAllocatorContext;
extern
CFTypeID CFAllocatorGetTypeID(void);
extern
void CFAllocatorSetDefault(CFAllocatorRef allocator);
extern
CFAllocatorRef CFAllocatorGetDefault(void);
extern
CFAllocatorRef CFAllocatorCreate(CFAllocatorRef allocator, CFAllocatorContext *context);
extern
void *CFAllocatorAllocate(CFAllocatorRef allocator, CFIndex size, CFOptionFlags hint);
extern
void *CFAllocatorReallocate(CFAllocatorRef allocator, void *ptr, CFIndex newsize, CFOptionFlags hint);
extern
void CFAllocatorDeallocate(CFAllocatorRef allocator, void *ptr);
extern
CFIndex CFAllocatorGetPreferredSizeForSize(CFAllocatorRef allocator, CFIndex size, CFOptionFlags hint);
extern
void CFAllocatorGetContext(CFAllocatorRef allocator, CFAllocatorContext *context);
extern
CFTypeID CFGetTypeID(CFTypeRef cf);
extern
CFStringRef CFCopyTypeIDDescription(CFTypeID type_id);
extern
CFTypeRef CFRetain(CFTypeRef cf);
extern
void CFRelease(CFTypeRef cf);
extern
CFTypeRef CFAutorelease(CFTypeRef __attribute__((cf_consumed)) arg) __attribute__((availability(macosx,introduced=10.9)));
extern
CFIndex CFGetRetainCount(CFTypeRef cf);
extern
Boolean CFEqual(CFTypeRef cf1, CFTypeRef cf2);
extern
CFHashCode CFHash(CFTypeRef cf);
extern
CFStringRef CFCopyDescription(CFTypeRef cf);
extern
CFAllocatorRef CFGetAllocator(CFTypeRef cf);
extern
CFTypeRef CFMakeCollectable(CFTypeRef cf) ;
}
extern "C" {
typedef const void * (*CFArrayRetainCallBack)(CFAllocatorRef allocator, const void *value);
typedef void (*CFArrayReleaseCallBack)(CFAllocatorRef allocator, const void *value);
typedef CFStringRef (*CFArrayCopyDescriptionCallBack)(const void *value);
typedef Boolean (*CFArrayEqualCallBack)(const void *value1, const void *value2);
typedef struct {
CFIndex version;
CFArrayRetainCallBack retain;
CFArrayReleaseCallBack release;
CFArrayCopyDescriptionCallBack copyDescription;
CFArrayEqualCallBack equal;
} CFArrayCallBacks;
extern
const CFArrayCallBacks kCFTypeArrayCallBacks;
typedef void (*CFArrayApplierFunction)(const void *value, void *context);
typedef const struct __attribute__((objc_bridge(NSArray))) __CFArray * CFArrayRef;
typedef struct __attribute__((objc_bridge_mutable(NSMutableArray))) __CFArray * CFMutableArrayRef;
extern
CFTypeID CFArrayGetTypeID(void);
extern
CFArrayRef CFArrayCreate(CFAllocatorRef allocator, const void **values, CFIndex numValues, const CFArrayCallBacks *callBacks);
extern
CFArrayRef CFArrayCreateCopy(CFAllocatorRef allocator, CFArrayRef theArray);
extern
CFMutableArrayRef CFArrayCreateMutable(CFAllocatorRef allocator, CFIndex capacity, const CFArrayCallBacks *callBacks);
extern
CFMutableArrayRef CFArrayCreateMutableCopy(CFAllocatorRef allocator, CFIndex capacity, CFArrayRef theArray);
extern
CFIndex CFArrayGetCount(CFArrayRef theArray);
extern
CFIndex CFArrayGetCountOfValue(CFArrayRef theArray, CFRange range, const void *value);
extern
Boolean CFArrayContainsValue(CFArrayRef theArray, CFRange range, const void *value);
extern
const void *CFArrayGetValueAtIndex(CFArrayRef theArray, CFIndex idx);
extern
void CFArrayGetValues(CFArrayRef theArray, CFRange range, const void **values);
extern
void CFArrayApplyFunction(CFArrayRef theArray, CFRange range, CFArrayApplierFunction applier, void *context);
extern
CFIndex CFArrayGetFirstIndexOfValue(CFArrayRef theArray, CFRange range, const void *value);
extern
CFIndex CFArrayGetLastIndexOfValue(CFArrayRef theArray, CFRange range, const void *value);
extern
CFIndex CFArrayBSearchValues(CFArrayRef theArray, CFRange range, const void *value, CFComparatorFunction comparator, void *context);
extern
void CFArrayAppendValue(CFMutableArrayRef theArray, const void *value);
extern
void CFArrayInsertValueAtIndex(CFMutableArrayRef theArray, CFIndex idx, const void *value);
extern
void CFArraySetValueAtIndex(CFMutableArrayRef theArray, CFIndex idx, const void *value);
extern
void CFArrayRemoveValueAtIndex(CFMutableArrayRef theArray, CFIndex idx);
extern
void CFArrayRemoveAllValues(CFMutableArrayRef theArray);
extern
void CFArrayReplaceValues(CFMutableArrayRef theArray, CFRange range, const void **newValues, CFIndex newCount);
extern
void CFArrayExchangeValuesAtIndices(CFMutableArrayRef theArray, CFIndex idx1, CFIndex idx2);
extern
void CFArraySortValues(CFMutableArrayRef theArray, CFRange range, CFComparatorFunction comparator, void *context);
extern
void CFArrayAppendArray(CFMutableArrayRef theArray, CFArrayRef otherArray, CFRange otherRange);
}
extern "C" {
typedef const void * (*CFBagRetainCallBack)(CFAllocatorRef allocator, const void *value);
typedef void (*CFBagReleaseCallBack)(CFAllocatorRef allocator, const void *value);
typedef CFStringRef (*CFBagCopyDescriptionCallBack)(const void *value);
typedef Boolean (*CFBagEqualCallBack)(const void *value1, const void *value2);
typedef CFHashCode (*CFBagHashCallBack)(const void *value);
typedef struct {
CFIndex version;
CFBagRetainCallBack retain;
CFBagReleaseCallBack release;
CFBagCopyDescriptionCallBack copyDescription;
CFBagEqualCallBack equal;
CFBagHashCallBack hash;
} CFBagCallBacks;
extern
const CFBagCallBacks kCFTypeBagCallBacks;
extern
const CFBagCallBacks kCFCopyStringBagCallBacks;
typedef void (*CFBagApplierFunction)(const void *value, void *context);
typedef const struct __CFBag * CFBagRef;
typedef struct __CFBag * CFMutableBagRef;
extern
CFTypeID CFBagGetTypeID(void);
extern
CFBagRef CFBagCreate(CFAllocatorRef allocator, const void **values, CFIndex numValues, const CFBagCallBacks *callBacks);
extern
CFBagRef CFBagCreateCopy(CFAllocatorRef allocator, CFBagRef theBag);
extern
CFMutableBagRef CFBagCreateMutable(CFAllocatorRef allocator, CFIndex capacity, const CFBagCallBacks *callBacks);
extern
CFMutableBagRef CFBagCreateMutableCopy(CFAllocatorRef allocator, CFIndex capacity, CFBagRef theBag);
extern
CFIndex CFBagGetCount(CFBagRef theBag);
extern
CFIndex CFBagGetCountOfValue(CFBagRef theBag, const void *value);
extern
Boolean CFBagContainsValue(CFBagRef theBag, const void *value);
extern
const void *CFBagGetValue(CFBagRef theBag, const void *value);
extern
Boolean CFBagGetValueIfPresent(CFBagRef theBag, const void *candidate, const void **value);
extern
void CFBagGetValues(CFBagRef theBag, const void **values);
extern
void CFBagApplyFunction(CFBagRef theBag, CFBagApplierFunction applier, void *context);
extern
void CFBagAddValue(CFMutableBagRef theBag, const void *value);
extern
void CFBagReplaceValue(CFMutableBagRef theBag, const void *value);
extern
void CFBagSetValue(CFMutableBagRef theBag, const void *value);
extern
void CFBagRemoveValue(CFMutableBagRef theBag, const void *value);
extern
void CFBagRemoveAllValues(CFMutableBagRef theBag);
}
extern "C" {
typedef struct {
CFIndex version;
void * info;
const void *(*retain)(const void *info);
void (*release)(const void *info);
CFStringRef (*copyDescription)(const void *info);
} CFBinaryHeapCompareContext;
typedef struct {
CFIndex version;
const void *(*retain)(CFAllocatorRef allocator, const void *ptr);
void (*release)(CFAllocatorRef allocator, const void *ptr);
CFStringRef (*copyDescription)(const void *ptr);
CFComparisonResult (*compare)(const void *ptr1, const void *ptr2, void *context);
} CFBinaryHeapCallBacks;
extern const CFBinaryHeapCallBacks kCFStringBinaryHeapCallBacks;
typedef void (*CFBinaryHeapApplierFunction)(const void *val, void *context);
typedef struct __CFBinaryHeap * CFBinaryHeapRef;
extern CFTypeID CFBinaryHeapGetTypeID(void);
extern CFBinaryHeapRef CFBinaryHeapCreate(CFAllocatorRef allocator, CFIndex capacity, const CFBinaryHeapCallBacks *callBacks, const CFBinaryHeapCompareContext *compareContext);
extern CFBinaryHeapRef CFBinaryHeapCreateCopy(CFAllocatorRef allocator, CFIndex capacity, CFBinaryHeapRef heap);
extern CFIndex CFBinaryHeapGetCount(CFBinaryHeapRef heap);
extern CFIndex CFBinaryHeapGetCountOfValue(CFBinaryHeapRef heap, const void *value);
extern Boolean CFBinaryHeapContainsValue(CFBinaryHeapRef heap, const void *value);
extern const void * CFBinaryHeapGetMinimum(CFBinaryHeapRef heap);
extern Boolean CFBinaryHeapGetMinimumIfPresent(CFBinaryHeapRef heap, const void **value);
extern void CFBinaryHeapGetValues(CFBinaryHeapRef heap, const void **values);
extern void CFBinaryHeapApplyFunction(CFBinaryHeapRef heap, CFBinaryHeapApplierFunction applier, void *context);
extern void CFBinaryHeapAddValue(CFBinaryHeapRef heap, const void *value);
extern void CFBinaryHeapRemoveMinimumValue(CFBinaryHeapRef heap);
extern void CFBinaryHeapRemoveAllValues(CFBinaryHeapRef heap);
}
extern "C" {
typedef UInt32 CFBit;
typedef const struct __CFBitVector * CFBitVectorRef;
typedef struct __CFBitVector * CFMutableBitVectorRef;
extern CFTypeID CFBitVectorGetTypeID(void);
extern CFBitVectorRef CFBitVectorCreate(CFAllocatorRef allocator, const UInt8 *bytes, CFIndex numBits);
extern CFBitVectorRef CFBitVectorCreateCopy(CFAllocatorRef allocator, CFBitVectorRef bv);
extern CFMutableBitVectorRef CFBitVectorCreateMutable(CFAllocatorRef allocator, CFIndex capacity);
extern CFMutableBitVectorRef CFBitVectorCreateMutableCopy(CFAllocatorRef allocator, CFIndex capacity, CFBitVectorRef bv);
extern CFIndex CFBitVectorGetCount(CFBitVectorRef bv);
extern CFIndex CFBitVectorGetCountOfBit(CFBitVectorRef bv, CFRange range, CFBit value);
extern Boolean CFBitVectorContainsBit(CFBitVectorRef bv, CFRange range, CFBit value);
extern CFBit CFBitVectorGetBitAtIndex(CFBitVectorRef bv, CFIndex idx);
extern void CFBitVectorGetBits(CFBitVectorRef bv, CFRange range, UInt8 *bytes);
extern CFIndex CFBitVectorGetFirstIndexOfBit(CFBitVectorRef bv, CFRange range, CFBit value);
extern CFIndex CFBitVectorGetLastIndexOfBit(CFBitVectorRef bv, CFRange range, CFBit value);
extern void CFBitVectorSetCount(CFMutableBitVectorRef bv, CFIndex count);
extern void CFBitVectorFlipBitAtIndex(CFMutableBitVectorRef bv, CFIndex idx);
extern void CFBitVectorFlipBits(CFMutableBitVectorRef bv, CFRange range);
extern void CFBitVectorSetBitAtIndex(CFMutableBitVectorRef bv, CFIndex idx, CFBit value);
extern void CFBitVectorSetBits(CFMutableBitVectorRef bv, CFRange range, CFBit value);
extern void CFBitVectorSetAllBits(CFMutableBitVectorRef bv, CFBit value);
}
static __inline__
uint16_t
OSReadSwapInt16(
const volatile void * base,
uintptr_t byteOffset
)
{
uint16_t result;
result = *(volatile uint16_t *)((uintptr_t)base + byteOffset);
return _OSSwapInt16(result);
}
static __inline__
uint32_t
OSReadSwapInt32(
const volatile void * base,
uintptr_t byteOffset
)
{
uint32_t result;
result = *(volatile uint32_t *)((uintptr_t)base + byteOffset);
return _OSSwapInt32(result);
}
static __inline__
uint64_t
OSReadSwapInt64(
const volatile void * base,
uintptr_t byteOffset
)
{
uint64_t result;
result = *(volatile uint64_t *)((uintptr_t)base + byteOffset);
return _OSSwapInt64(result);
}
static __inline__
void
OSWriteSwapInt16(
volatile void * base,
uintptr_t byteOffset,
uint16_t data
)
{
*(volatile uint16_t *)((uintptr_t)base + byteOffset) = _OSSwapInt16(data);
}
static __inline__
void
OSWriteSwapInt32(
volatile void * base,
uintptr_t byteOffset,
uint32_t data
)
{
*(volatile uint32_t *)((uintptr_t)base + byteOffset) = _OSSwapInt32(data);
}
static __inline__
void
OSWriteSwapInt64(
volatile void * base,
uintptr_t byteOffset,
uint64_t data
)
{
*(volatile uint64_t *)((uintptr_t)base + byteOffset) = _OSSwapInt64(data);
}
enum {
OSUnknownByteOrder,
OSLittleEndian,
OSBigEndian
};
static __inline__
int32_t
OSHostByteOrder(void) {
return OSLittleEndian;
}
static __inline__
uint16_t
_OSReadInt16(
const volatile void * base,
uintptr_t byteOffset
)
{
return *(volatile uint16_t *)((uintptr_t)base + byteOffset);
}
static __inline__
uint32_t
_OSReadInt32(
const volatile void * base,
uintptr_t byteOffset
)
{
return *(volatile uint32_t *)((uintptr_t)base + byteOffset);
}
static __inline__
uint64_t
_OSReadInt64(
const volatile void * base,
uintptr_t byteOffset
)
{
return *(volatile uint64_t *)((uintptr_t)base + byteOffset);
}
static __inline__
void
_OSWriteInt16(
volatile void * base,
uintptr_t byteOffset,
uint16_t data
)
{
*(volatile uint16_t *)((uintptr_t)base + byteOffset) = data;
}
static __inline__
void
_OSWriteInt32(
volatile void * base,
uintptr_t byteOffset,
uint32_t data
)
{
*(volatile uint32_t *)((uintptr_t)base + byteOffset) = data;
}
static __inline__
void
_OSWriteInt64(
volatile void * base,
uintptr_t byteOffset,
uint64_t data
)
{
*(volatile uint64_t *)((uintptr_t)base + byteOffset) = data;
}
extern "C" {
enum __CFByteOrder {
CFByteOrderUnknown,
CFByteOrderLittleEndian,
CFByteOrderBigEndian
};
typedef CFIndex CFByteOrder;
static __inline__ __attribute__((always_inline)) CFByteOrder CFByteOrderGetCurrent(void) {
int32_t byteOrder = OSHostByteOrder();
switch (byteOrder) {
case OSLittleEndian: return CFByteOrderLittleEndian;
case OSBigEndian: return CFByteOrderBigEndian;
default: break;
}
return CFByteOrderUnknown;
}
static __inline__ __attribute__((always_inline)) uint16_t CFSwapInt16(uint16_t arg) {
return ((__uint16_t)(__builtin_constant_p(arg) ? ((__uint16_t)((((__uint16_t)(arg) & 0xff00) >> 8) | (((__uint16_t)(arg) & 0x00ff) << 8))) : _OSSwapInt16(arg)));
}
static __inline__ __attribute__((always_inline)) uint32_t CFSwapInt32(uint32_t arg) {
return (__builtin_constant_p(arg) ? ((__uint32_t)((((__uint32_t)(arg) & 0xff000000) >> 24) | (((__uint32_t)(arg) & 0x00ff0000) >> 8) | (((__uint32_t)(arg) & 0x0000ff00) << 8) | (((__uint32_t)(arg) & 0x000000ff) << 24))) : _OSSwapInt32(arg));
}
static __inline__ __attribute__((always_inline)) uint64_t CFSwapInt64(uint64_t arg) {
return (__builtin_constant_p(arg) ? ((__uint64_t)((((__uint64_t)(arg) & 0xff00000000000000ULL) >> 56) | (((__uint64_t)(arg) & 0x00ff000000000000ULL) >> 40) | (((__uint64_t)(arg) & 0x0000ff0000000000ULL) >> 24) | (((__uint64_t)(arg) & 0x000000ff00000000ULL) >> 8) | (((__uint64_t)(arg) & 0x00000000ff000000ULL) << 8) | (((__uint64_t)(arg) & 0x0000000000ff0000ULL) << 24) | (((__uint64_t)(arg) & 0x000000000000ff00ULL) << 40) | (((__uint64_t)(arg) & 0x00000000000000ffULL) << 56))) : _OSSwapInt64(arg));
}
static __inline__ __attribute__((always_inline)) uint16_t CFSwapInt16BigToHost(uint16_t arg) {
return ((__uint16_t)(__builtin_constant_p(arg) ? ((__uint16_t)((((__uint16_t)(arg) & 0xff00) >> 8) | (((__uint16_t)(arg) & 0x00ff) << 8))) : _OSSwapInt16(arg)));
}
static __inline__ __attribute__((always_inline)) uint32_t CFSwapInt32BigToHost(uint32_t arg) {
return (__builtin_constant_p(arg) ? ((__uint32_t)((((__uint32_t)(arg) & 0xff000000) >> 24) | (((__uint32_t)(arg) & 0x00ff0000) >> 8) | (((__uint32_t)(arg) & 0x0000ff00) << 8) | (((__uint32_t)(arg) & 0x000000ff) << 24))) : _OSSwapInt32(arg));
}
static __inline__ __attribute__((always_inline)) uint64_t CFSwapInt64BigToHost(uint64_t arg) {
return (__builtin_constant_p(arg) ? ((__uint64_t)((((__uint64_t)(arg) & 0xff00000000000000ULL) >> 56) | (((__uint64_t)(arg) & 0x00ff000000000000ULL) >> 40) | (((__uint64_t)(arg) & 0x0000ff0000000000ULL) >> 24) | (((__uint64_t)(arg) & 0x000000ff00000000ULL) >> 8) | (((__uint64_t)(arg) & 0x00000000ff000000ULL) << 8) | (((__uint64_t)(arg) & 0x0000000000ff0000ULL) << 24) | (((__uint64_t)(arg) & 0x000000000000ff00ULL) << 40) | (((__uint64_t)(arg) & 0x00000000000000ffULL) << 56))) : _OSSwapInt64(arg));
}
static __inline__ __attribute__((always_inline)) uint16_t CFSwapInt16HostToBig(uint16_t arg) {
return ((__uint16_t)(__builtin_constant_p(arg) ? ((__uint16_t)((((__uint16_t)(arg) & 0xff00) >> 8) | (((__uint16_t)(arg) & 0x00ff) << 8))) : _OSSwapInt16(arg)));
}
static __inline__ __attribute__((always_inline)) uint32_t CFSwapInt32HostToBig(uint32_t arg) {
return (__builtin_constant_p(arg) ? ((__uint32_t)((((__uint32_t)(arg) & 0xff000000) >> 24) | (((__uint32_t)(arg) & 0x00ff0000) >> 8) | (((__uint32_t)(arg) & 0x0000ff00) << 8) | (((__uint32_t)(arg) & 0x000000ff) << 24))) : _OSSwapInt32(arg));
}
static __inline__ __attribute__((always_inline)) uint64_t CFSwapInt64HostToBig(uint64_t arg) {
return (__builtin_constant_p(arg) ? ((__uint64_t)((((__uint64_t)(arg) & 0xff00000000000000ULL) >> 56) | (((__uint64_t)(arg) & 0x00ff000000000000ULL) >> 40) | (((__uint64_t)(arg) & 0x0000ff0000000000ULL) >> 24) | (((__uint64_t)(arg) & 0x000000ff00000000ULL) >> 8) | (((__uint64_t)(arg) & 0x00000000ff000000ULL) << 8) | (((__uint64_t)(arg) & 0x0000000000ff0000ULL) << 24) | (((__uint64_t)(arg) & 0x000000000000ff00ULL) << 40) | (((__uint64_t)(arg) & 0x00000000000000ffULL) << 56))) : _OSSwapInt64(arg));
}
static __inline__ __attribute__((always_inline)) uint16_t CFSwapInt16LittleToHost(uint16_t arg) {
return ((uint16_t)(arg));
}
static __inline__ __attribute__((always_inline)) uint32_t CFSwapInt32LittleToHost(uint32_t arg) {
return ((uint32_t)(arg));
}
static __inline__ __attribute__((always_inline)) uint64_t CFSwapInt64LittleToHost(uint64_t arg) {
return ((uint64_t)(arg));
}
static __inline__ __attribute__((always_inline)) uint16_t CFSwapInt16HostToLittle(uint16_t arg) {
return ((uint16_t)(arg));
}
static __inline__ __attribute__((always_inline)) uint32_t CFSwapInt32HostToLittle(uint32_t arg) {
return ((uint32_t)(arg));
}
static __inline__ __attribute__((always_inline)) uint64_t CFSwapInt64HostToLittle(uint64_t arg) {
return ((uint64_t)(arg));
}
typedef struct {uint32_t v;} CFSwappedFloat32;
typedef struct {uint64_t v;} CFSwappedFloat64;
static __inline__ __attribute__((always_inline)) CFSwappedFloat32 CFConvertFloat32HostToSwapped(Float32 arg) {
union CFSwap {
Float32 v;
CFSwappedFloat32 sv;
} result;
result.v = arg;
result.sv.v = CFSwapInt32(result.sv.v);
return result.sv;
}
static __inline__ __attribute__((always_inline)) Float32 CFConvertFloat32SwappedToHost(CFSwappedFloat32 arg) {
union CFSwap {
Float32 v;
CFSwappedFloat32 sv;
} result;
result.sv = arg;
result.sv.v = CFSwapInt32(result.sv.v);
return result.v;
}
static __inline__ __attribute__((always_inline)) CFSwappedFloat64 CFConvertFloat64HostToSwapped(Float64 arg) {
union CFSwap {
Float64 v;
CFSwappedFloat64 sv;
} result;
result.v = arg;
result.sv.v = CFSwapInt64(result.sv.v);
return result.sv;
}
static __inline__ __attribute__((always_inline)) Float64 CFConvertFloat64SwappedToHost(CFSwappedFloat64 arg) {
union CFSwap {
Float64 v;
CFSwappedFloat64 sv;
} result;
result.sv = arg;
result.sv.v = CFSwapInt64(result.sv.v);
return result.v;
}
static __inline__ __attribute__((always_inline)) CFSwappedFloat32 CFConvertFloatHostToSwapped(float arg) {
union CFSwap {
float v;
CFSwappedFloat32 sv;
} result;
result.v = arg;
result.sv.v = CFSwapInt32(result.sv.v);
return result.sv;
}
static __inline__ __attribute__((always_inline)) float CFConvertFloatSwappedToHost(CFSwappedFloat32 arg) {
union CFSwap {
float v;
CFSwappedFloat32 sv;
} result;
result.sv = arg;
result.sv.v = CFSwapInt32(result.sv.v);
return result.v;
}
static __inline__ __attribute__((always_inline)) CFSwappedFloat64 CFConvertDoubleHostToSwapped(double arg) {
union CFSwap {
double v;
CFSwappedFloat64 sv;
} result;
result.v = arg;
result.sv.v = CFSwapInt64(result.sv.v);
return result.sv;
}
static __inline__ __attribute__((always_inline)) double CFConvertDoubleSwappedToHost(CFSwappedFloat64 arg) {
union CFSwap {
double v;
CFSwappedFloat64 sv;
} result;
result.sv = arg;
result.sv.v = CFSwapInt64(result.sv.v);
return result.v;
}
}
extern "C" {
typedef const void * (*CFDictionaryRetainCallBack)(CFAllocatorRef allocator, const void *value);
typedef void (*CFDictionaryReleaseCallBack)(CFAllocatorRef allocator, const void *value);
typedef CFStringRef (*CFDictionaryCopyDescriptionCallBack)(const void *value);
typedef Boolean (*CFDictionaryEqualCallBack)(const void *value1, const void *value2);
typedef CFHashCode (*CFDictionaryHashCallBack)(const void *value);
typedef struct {
CFIndex version;
CFDictionaryRetainCallBack retain;
CFDictionaryReleaseCallBack release;
CFDictionaryCopyDescriptionCallBack copyDescription;
CFDictionaryEqualCallBack equal;
CFDictionaryHashCallBack hash;
} CFDictionaryKeyCallBacks;
extern
const CFDictionaryKeyCallBacks kCFTypeDictionaryKeyCallBacks;
extern
const CFDictionaryKeyCallBacks kCFCopyStringDictionaryKeyCallBacks;
typedef struct {
CFIndex version;
CFDictionaryRetainCallBack retain;
CFDictionaryReleaseCallBack release;
CFDictionaryCopyDescriptionCallBack copyDescription;
CFDictionaryEqualCallBack equal;
} CFDictionaryValueCallBacks;
extern
const CFDictionaryValueCallBacks kCFTypeDictionaryValueCallBacks;
typedef void (*CFDictionaryApplierFunction)(const void *key, const void *value, void *context);
typedef const struct __attribute__((objc_bridge(NSDictionary))) __CFDictionary * CFDictionaryRef;
typedef struct __attribute__((objc_bridge_mutable(NSMutableDictionary))) __CFDictionary * CFMutableDictionaryRef;
extern
CFTypeID CFDictionaryGetTypeID(void);
extern
CFDictionaryRef CFDictionaryCreate(CFAllocatorRef allocator, const void **keys, const void **values, CFIndex numValues, const CFDictionaryKeyCallBacks *keyCallBacks, const CFDictionaryValueCallBacks *valueCallBacks);
extern
CFDictionaryRef CFDictionaryCreateCopy(CFAllocatorRef allocator, CFDictionaryRef theDict);
extern
CFMutableDictionaryRef CFDictionaryCreateMutable(CFAllocatorRef allocator, CFIndex capacity, const CFDictionaryKeyCallBacks *keyCallBacks, const CFDictionaryValueCallBacks *valueCallBacks);
extern
CFMutableDictionaryRef CFDictionaryCreateMutableCopy(CFAllocatorRef allocator, CFIndex capacity, CFDictionaryRef theDict);
extern
CFIndex CFDictionaryGetCount(CFDictionaryRef theDict);
extern
CFIndex CFDictionaryGetCountOfKey(CFDictionaryRef theDict, const void *key);
extern
CFIndex CFDictionaryGetCountOfValue(CFDictionaryRef theDict, const void *value);
extern
Boolean CFDictionaryContainsKey(CFDictionaryRef theDict, const void *key);
extern
Boolean CFDictionaryContainsValue(CFDictionaryRef theDict, const void *value);
extern
const void *CFDictionaryGetValue(CFDictionaryRef theDict, const void *key);
extern
Boolean CFDictionaryGetValueIfPresent(CFDictionaryRef theDict, const void *key, const void **value);
extern
void CFDictionaryGetKeysAndValues(CFDictionaryRef theDict, const void **keys, const void **values);
extern
void CFDictionaryApplyFunction(CFDictionaryRef theDict, CFDictionaryApplierFunction applier, void *context);
extern
void CFDictionaryAddValue(CFMutableDictionaryRef theDict, const void *key, const void *value);
extern
void CFDictionarySetValue(CFMutableDictionaryRef theDict, const void *key, const void *value);
extern
void CFDictionaryReplaceValue(CFMutableDictionaryRef theDict, const void *key, const void *value);
extern
void CFDictionaryRemoveValue(CFMutableDictionaryRef theDict, const void *key);
extern
void CFDictionaryRemoveAllValues(CFMutableDictionaryRef theDict);
}
extern "C" {
typedef const struct __attribute__((objc_bridge(NSLocale))) __CFLocale *CFLocaleRef;
extern
CFTypeID CFLocaleGetTypeID(void);
extern
CFLocaleRef CFLocaleGetSystem(void);
extern
CFLocaleRef CFLocaleCopyCurrent(void);
extern
CFArrayRef CFLocaleCopyAvailableLocaleIdentifiers(void);
extern
CFArrayRef CFLocaleCopyISOLanguageCodes(void);
extern
CFArrayRef CFLocaleCopyISOCountryCodes(void);
extern
CFArrayRef CFLocaleCopyISOCurrencyCodes(void);
extern
CFArrayRef CFLocaleCopyCommonISOCurrencyCodes(void) __attribute__((availability(macosx,introduced=10.5)));
extern
CFArrayRef CFLocaleCopyPreferredLanguages(void) __attribute__((availability(macosx,introduced=10.5)));
extern
CFStringRef CFLocaleCreateCanonicalLanguageIdentifierFromString(CFAllocatorRef allocator, CFStringRef localeIdentifier);
extern
CFStringRef CFLocaleCreateCanonicalLocaleIdentifierFromString(CFAllocatorRef allocator, CFStringRef localeIdentifier);
extern
CFStringRef CFLocaleCreateCanonicalLocaleIdentifierFromScriptManagerCodes(CFAllocatorRef allocator, LangCode lcode, RegionCode rcode);
extern
CFStringRef CFLocaleCreateLocaleIdentifierFromWindowsLocaleCode(CFAllocatorRef allocator, uint32_t lcid) __attribute__((availability(macosx,introduced=10.6)));
extern
uint32_t CFLocaleGetWindowsLocaleCodeFromLocaleIdentifier(CFStringRef localeIdentifier) __attribute__((availability(macosx,introduced=10.6)));
typedef CFIndex CFLocaleLanguageDirection; enum {
kCFLocaleLanguageDirectionUnknown = 0,
kCFLocaleLanguageDirectionLeftToRight = 1,
kCFLocaleLanguageDirectionRightToLeft = 2,
kCFLocaleLanguageDirectionTopToBottom = 3,
kCFLocaleLanguageDirectionBottomToTop = 4
};
extern
CFLocaleLanguageDirection CFLocaleGetLanguageCharacterDirection(CFStringRef isoLangCode) __attribute__((availability(macosx,introduced=10.6)));
extern
CFLocaleLanguageDirection CFLocaleGetLanguageLineDirection(CFStringRef isoLangCode) __attribute__((availability(macosx,introduced=10.6)));
extern
CFDictionaryRef CFLocaleCreateComponentsFromLocaleIdentifier(CFAllocatorRef allocator, CFStringRef localeID);
extern
CFStringRef CFLocaleCreateLocaleIdentifierFromComponents(CFAllocatorRef allocator, CFDictionaryRef dictionary);
extern
CFLocaleRef CFLocaleCreate(CFAllocatorRef allocator, CFStringRef localeIdentifier);
extern
CFLocaleRef CFLocaleCreateCopy(CFAllocatorRef allocator, CFLocaleRef locale);
extern
CFStringRef CFLocaleGetIdentifier(CFLocaleRef locale);
extern
CFTypeRef CFLocaleGetValue(CFLocaleRef locale, CFStringRef key);
extern
CFStringRef CFLocaleCopyDisplayNameForPropertyValue(CFLocaleRef displayLocale, CFStringRef key, CFStringRef value);
extern const CFStringRef kCFLocaleCurrentLocaleDidChangeNotification __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFLocaleIdentifier;
extern const CFStringRef kCFLocaleLanguageCode;
extern const CFStringRef kCFLocaleCountryCode;
extern const CFStringRef kCFLocaleScriptCode;
extern const CFStringRef kCFLocaleVariantCode;
extern const CFStringRef kCFLocaleExemplarCharacterSet;
extern const CFStringRef kCFLocaleCalendarIdentifier;
extern const CFStringRef kCFLocaleCalendar;
extern const CFStringRef kCFLocaleCollationIdentifier;
extern const CFStringRef kCFLocaleUsesMetricSystem;
extern const CFStringRef kCFLocaleMeasurementSystem;
extern const CFStringRef kCFLocaleDecimalSeparator;
extern const CFStringRef kCFLocaleGroupingSeparator;
extern const CFStringRef kCFLocaleCurrencySymbol;
extern const CFStringRef kCFLocaleCurrencyCode;
extern const CFStringRef kCFLocaleCollatorIdentifier __attribute__((availability(macosx,introduced=10.6)));
extern const CFStringRef kCFLocaleQuotationBeginDelimiterKey __attribute__((availability(macosx,introduced=10.6)));
extern const CFStringRef kCFLocaleQuotationEndDelimiterKey __attribute__((availability(macosx,introduced=10.6)));
extern const CFStringRef kCFLocaleAlternateQuotationBeginDelimiterKey __attribute__((availability(macosx,introduced=10.6)));
extern const CFStringRef kCFLocaleAlternateQuotationEndDelimiterKey __attribute__((availability(macosx,introduced=10.6)));
extern const CFStringRef kCFGregorianCalendar;
extern const CFStringRef kCFBuddhistCalendar;
extern const CFStringRef kCFChineseCalendar;
extern const CFStringRef kCFHebrewCalendar;
extern const CFStringRef kCFIslamicCalendar;
extern const CFStringRef kCFIslamicCivilCalendar;
extern const CFStringRef kCFJapaneseCalendar;
extern const CFStringRef kCFRepublicOfChinaCalendar __attribute__((availability(macosx,introduced=10.6)));
extern const CFStringRef kCFPersianCalendar __attribute__((availability(macosx,introduced=10.6)));
extern const CFStringRef kCFIndianCalendar __attribute__((availability(macosx,introduced=10.6)));
extern const CFStringRef kCFISO8601Calendar __attribute__((availability(macosx,introduced=10.6)));
extern const CFStringRef kCFIslamicTabularCalendar __attribute__((availability(macosx,introduced=10.10)));
extern const CFStringRef kCFIslamicUmmAlQuraCalendar __attribute__((availability(macosx,introduced=10.10)));
}
extern "C" {
typedef double CFTimeInterval;
typedef CFTimeInterval CFAbsoluteTime;
extern
CFAbsoluteTime CFAbsoluteTimeGetCurrent(void);
extern
const CFTimeInterval kCFAbsoluteTimeIntervalSince1970;
extern
const CFTimeInterval kCFAbsoluteTimeIntervalSince1904;
typedef const struct __attribute__((objc_bridge(NSDate))) __CFDate * CFDateRef;
extern
CFTypeID CFDateGetTypeID(void);
extern
CFDateRef CFDateCreate(CFAllocatorRef allocator, CFAbsoluteTime at);
extern
CFAbsoluteTime CFDateGetAbsoluteTime(CFDateRef theDate);
extern
CFTimeInterval CFDateGetTimeIntervalSinceDate(CFDateRef theDate, CFDateRef otherDate);
extern
CFComparisonResult CFDateCompare(CFDateRef theDate, CFDateRef otherDate, void *context);
typedef const struct __attribute__((objc_bridge(NSTimeZone))) __CFTimeZone * CFTimeZoneRef;
typedef struct {
SInt32 year;
SInt8 month;
SInt8 day;
SInt8 hour;
SInt8 minute;
double second;
} CFGregorianDate __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead")));
typedef struct {
SInt32 years;
SInt32 months;
SInt32 days;
SInt32 hours;
SInt32 minutes;
double seconds;
} CFGregorianUnits __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead")));
typedef CFOptionFlags CFGregorianUnitFlags; enum {
kCFGregorianUnitsYears __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead"))) = (1UL << 0),
kCFGregorianUnitsMonths __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead"))) = (1UL << 1),
kCFGregorianUnitsDays __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead"))) = (1UL << 2),
kCFGregorianUnitsHours __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead"))) = (1UL << 3),
kCFGregorianUnitsMinutes __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead"))) = (1UL << 4),
kCFGregorianUnitsSeconds __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead"))) = (1UL << 5),
kCFGregorianAllUnits __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead"))) = 0x00FFFFFF
};
extern
Boolean CFGregorianDateIsValid(CFGregorianDate gdate, CFOptionFlags unitFlags) __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead")));
extern
CFAbsoluteTime CFGregorianDateGetAbsoluteTime(CFGregorianDate gdate, CFTimeZoneRef tz) __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead")));
extern
CFGregorianDate CFAbsoluteTimeGetGregorianDate(CFAbsoluteTime at, CFTimeZoneRef tz) __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead")));
extern
CFAbsoluteTime CFAbsoluteTimeAddGregorianUnits(CFAbsoluteTime at, CFTimeZoneRef tz, CFGregorianUnits units) __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead")));
extern
CFGregorianUnits CFAbsoluteTimeGetDifferenceAsGregorianUnits(CFAbsoluteTime at1, CFAbsoluteTime at2, CFTimeZoneRef tz, CFOptionFlags unitFlags) __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead")));
extern
SInt32 CFAbsoluteTimeGetDayOfWeek(CFAbsoluteTime at, CFTimeZoneRef tz) __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead")));
extern
SInt32 CFAbsoluteTimeGetDayOfYear(CFAbsoluteTime at, CFTimeZoneRef tz) __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead")));
extern
SInt32 CFAbsoluteTimeGetWeekOfYear(CFAbsoluteTime at, CFTimeZoneRef tz) __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use CFCalendar or NSCalendar API instead")));
}
extern "C" {
typedef const struct __attribute__((objc_bridge(NSData))) __CFData * CFDataRef;
typedef struct __attribute__((objc_bridge_mutable(NSMutableData))) __CFData * CFMutableDataRef;
extern
CFTypeID CFDataGetTypeID(void);
extern
CFDataRef CFDataCreate(CFAllocatorRef allocator, const UInt8 *bytes, CFIndex length);
extern
CFDataRef CFDataCreateWithBytesNoCopy(CFAllocatorRef allocator, const UInt8 *bytes, CFIndex length, CFAllocatorRef bytesDeallocator);
extern
CFDataRef CFDataCreateCopy(CFAllocatorRef allocator, CFDataRef theData);
extern
CFMutableDataRef CFDataCreateMutable(CFAllocatorRef allocator, CFIndex capacity);
extern
CFMutableDataRef CFDataCreateMutableCopy(CFAllocatorRef allocator, CFIndex capacity, CFDataRef theData);
extern
CFIndex CFDataGetLength(CFDataRef theData);
extern
const UInt8 *CFDataGetBytePtr(CFDataRef theData);
extern
UInt8 *CFDataGetMutableBytePtr(CFMutableDataRef theData);
extern
void CFDataGetBytes(CFDataRef theData, CFRange range, UInt8 *buffer);
extern
void CFDataSetLength(CFMutableDataRef theData, CFIndex length);
extern
void CFDataIncreaseLength(CFMutableDataRef theData, CFIndex extraLength);
extern
void CFDataAppendBytes(CFMutableDataRef theData, const UInt8 *bytes, CFIndex length);
extern
void CFDataReplaceBytes(CFMutableDataRef theData, CFRange range, const UInt8 *newBytes, CFIndex newLength);
extern
void CFDataDeleteBytes(CFMutableDataRef theData, CFRange range);
typedef CFOptionFlags CFDataSearchFlags; enum {
kCFDataSearchBackwards = 1UL << 0,
kCFDataSearchAnchored = 1UL << 1
} __attribute__((availability(macosx,introduced=10.6)));
extern
CFRange CFDataFind(CFDataRef theData, CFDataRef dataToFind, CFRange searchRange, CFDataSearchFlags compareOptions) __attribute__((availability(macosx,introduced=10.6)));
}
extern "C" {
typedef const struct __attribute__((objc_bridge(NSCharacterSet))) __CFCharacterSet * CFCharacterSetRef;
typedef struct __attribute__((objc_bridge_mutable(NSMutableCharacterSet))) __CFCharacterSet * CFMutableCharacterSetRef;
typedef CFIndex CFCharacterSetPredefinedSet; enum {
kCFCharacterSetControl = 1,
kCFCharacterSetWhitespace,
kCFCharacterSetWhitespaceAndNewline,
kCFCharacterSetDecimalDigit,
kCFCharacterSetLetter,
kCFCharacterSetLowercaseLetter,
kCFCharacterSetUppercaseLetter,
kCFCharacterSetNonBase,
kCFCharacterSetDecomposable,
kCFCharacterSetAlphaNumeric,
kCFCharacterSetPunctuation,
kCFCharacterSetCapitalizedLetter = 13,
kCFCharacterSetSymbol = 14,
kCFCharacterSetNewline __attribute__((availability(macosx,introduced=10.5))) = 15,
kCFCharacterSetIllegal = 12
};
extern
CFTypeID CFCharacterSetGetTypeID(void);
extern
CFCharacterSetRef CFCharacterSetGetPredefined(CFCharacterSetPredefinedSet theSetIdentifier);
extern
CFCharacterSetRef CFCharacterSetCreateWithCharactersInRange(CFAllocatorRef alloc, CFRange theRange);
extern
CFCharacterSetRef CFCharacterSetCreateWithCharactersInString(CFAllocatorRef alloc, CFStringRef theString);
extern
CFCharacterSetRef CFCharacterSetCreateWithBitmapRepresentation(CFAllocatorRef alloc, CFDataRef theData);
extern CFCharacterSetRef CFCharacterSetCreateInvertedSet(CFAllocatorRef alloc, CFCharacterSetRef theSet);
extern Boolean CFCharacterSetIsSupersetOfSet(CFCharacterSetRef theSet, CFCharacterSetRef theOtherset);
extern Boolean CFCharacterSetHasMemberInPlane(CFCharacterSetRef theSet, CFIndex thePlane);
extern
CFMutableCharacterSetRef CFCharacterSetCreateMutable(CFAllocatorRef alloc);
extern
CFCharacterSetRef CFCharacterSetCreateCopy(CFAllocatorRef alloc, CFCharacterSetRef theSet);
extern
CFMutableCharacterSetRef CFCharacterSetCreateMutableCopy(CFAllocatorRef alloc, CFCharacterSetRef theSet);
extern
Boolean CFCharacterSetIsCharacterMember(CFCharacterSetRef theSet, UniChar theChar);
extern Boolean CFCharacterSetIsLongCharacterMember(CFCharacterSetRef theSet, UTF32Char theChar);
extern
CFDataRef CFCharacterSetCreateBitmapRepresentation(CFAllocatorRef alloc, CFCharacterSetRef theSet);
extern
void CFCharacterSetAddCharactersInRange(CFMutableCharacterSetRef theSet, CFRange theRange);
extern
void CFCharacterSetRemoveCharactersInRange(CFMutableCharacterSetRef theSet, CFRange theRange);
extern
void CFCharacterSetAddCharactersInString(CFMutableCharacterSetRef theSet, CFStringRef theString);
extern
void CFCharacterSetRemoveCharactersInString(CFMutableCharacterSetRef theSet, CFStringRef theString);
extern
void CFCharacterSetUnion(CFMutableCharacterSetRef theSet, CFCharacterSetRef theOtherSet);
extern
void CFCharacterSetIntersect(CFMutableCharacterSetRef theSet, CFCharacterSetRef theOtherSet);
extern
void CFCharacterSetInvert(CFMutableCharacterSetRef theSet);
}
extern "C" {
typedef UInt32 CFStringEncoding;
typedef CFStringEncoding CFStringBuiltInEncodings; enum {
kCFStringEncodingMacRoman = 0,
kCFStringEncodingWindowsLatin1 = 0x0500,
kCFStringEncodingISOLatin1 = 0x0201,
kCFStringEncodingNextStepLatin = 0x0B01,
kCFStringEncodingASCII = 0x0600,
kCFStringEncodingUnicode = 0x0100,
kCFStringEncodingUTF8 = 0x08000100,
kCFStringEncodingNonLossyASCII = 0x0BFF,
kCFStringEncodingUTF16 = 0x0100,
kCFStringEncodingUTF16BE = 0x10000100,
kCFStringEncodingUTF16LE = 0x14000100,
kCFStringEncodingUTF32 = 0x0c000100,
kCFStringEncodingUTF32BE = 0x18000100,
kCFStringEncodingUTF32LE = 0x1c000100
};
extern
CFTypeID CFStringGetTypeID(void);
extern
CFStringRef CFStringCreateWithPascalString(CFAllocatorRef alloc, ConstStr255Param pStr, CFStringEncoding encoding);
extern
CFStringRef CFStringCreateWithCString(CFAllocatorRef alloc, const char *cStr, CFStringEncoding encoding);
extern
CFStringRef CFStringCreateWithBytes(CFAllocatorRef alloc, const UInt8 *bytes, CFIndex numBytes, CFStringEncoding encoding, Boolean isExternalRepresentation);
extern
CFStringRef CFStringCreateWithCharacters(CFAllocatorRef alloc, const UniChar *chars, CFIndex numChars);
extern
CFStringRef CFStringCreateWithPascalStringNoCopy(CFAllocatorRef alloc, ConstStr255Param pStr, CFStringEncoding encoding, CFAllocatorRef contentsDeallocator);
extern
CFStringRef CFStringCreateWithCStringNoCopy(CFAllocatorRef alloc, const char *cStr, CFStringEncoding encoding, CFAllocatorRef contentsDeallocator);
extern
CFStringRef CFStringCreateWithBytesNoCopy(CFAllocatorRef alloc, const UInt8 *bytes, CFIndex numBytes, CFStringEncoding encoding, Boolean isExternalRepresentation, CFAllocatorRef contentsDeallocator);
extern
CFStringRef CFStringCreateWithCharactersNoCopy(CFAllocatorRef alloc, const UniChar *chars, CFIndex numChars, CFAllocatorRef contentsDeallocator);
extern
CFStringRef CFStringCreateWithSubstring(CFAllocatorRef alloc, CFStringRef str, CFRange range);
extern
CFStringRef CFStringCreateCopy(CFAllocatorRef alloc, CFStringRef theString);
extern
CFStringRef CFStringCreateWithFormat(CFAllocatorRef alloc, CFDictionaryRef formatOptions, CFStringRef format, ...) __attribute__((format(CFString, 3, 4)));
extern
CFStringRef CFStringCreateWithFormatAndArguments(CFAllocatorRef alloc, CFDictionaryRef formatOptions, CFStringRef format, va_list arguments) __attribute__((format(CFString, 3, 0)));
extern
CFMutableStringRef CFStringCreateMutable(CFAllocatorRef alloc, CFIndex maxLength);
extern
CFMutableStringRef CFStringCreateMutableCopy(CFAllocatorRef alloc, CFIndex maxLength, CFStringRef theString);
extern
CFMutableStringRef CFStringCreateMutableWithExternalCharactersNoCopy(CFAllocatorRef alloc, UniChar *chars, CFIndex numChars, CFIndex capacity, CFAllocatorRef externalCharactersAllocator);
extern
CFIndex CFStringGetLength(CFStringRef theString);
extern
UniChar CFStringGetCharacterAtIndex(CFStringRef theString, CFIndex idx);
extern
void CFStringGetCharacters(CFStringRef theString, CFRange range, UniChar *buffer);
extern
Boolean CFStringGetPascalString(CFStringRef theString, StringPtr buffer, CFIndex bufferSize, CFStringEncoding encoding);
extern
Boolean CFStringGetCString(CFStringRef theString, char *buffer, CFIndex bufferSize, CFStringEncoding encoding);
extern
ConstStringPtr CFStringGetPascalStringPtr(CFStringRef theString, CFStringEncoding encoding);
extern
const char *CFStringGetCStringPtr(CFStringRef theString, CFStringEncoding encoding);
extern
const UniChar *CFStringGetCharactersPtr(CFStringRef theString);
extern
CFIndex CFStringGetBytes(CFStringRef theString, CFRange range, CFStringEncoding encoding, UInt8 lossByte, Boolean isExternalRepresentation, UInt8 *buffer, CFIndex maxBufLen, CFIndex *usedBufLen);
extern
CFStringRef CFStringCreateFromExternalRepresentation(CFAllocatorRef alloc, CFDataRef data, CFStringEncoding encoding);
extern
CFDataRef CFStringCreateExternalRepresentation(CFAllocatorRef alloc, CFStringRef theString, CFStringEncoding encoding, UInt8 lossByte);
extern
CFStringEncoding CFStringGetSmallestEncoding(CFStringRef theString);
extern
CFStringEncoding CFStringGetFastestEncoding(CFStringRef theString);
extern
CFStringEncoding CFStringGetSystemEncoding(void);
extern
CFIndex CFStringGetMaximumSizeForEncoding(CFIndex length, CFStringEncoding encoding);
extern
Boolean CFStringGetFileSystemRepresentation(CFStringRef string, char *buffer, CFIndex maxBufLen);
extern
CFIndex CFStringGetMaximumSizeOfFileSystemRepresentation(CFStringRef string);
extern
CFStringRef CFStringCreateWithFileSystemRepresentation(CFAllocatorRef alloc, const char *buffer);
typedef CFOptionFlags CFStringCompareFlags; enum {
kCFCompareCaseInsensitive = 1,
kCFCompareBackwards = 4,
kCFCompareAnchored = 8,
kCFCompareNonliteral = 16,
kCFCompareLocalized = 32,
kCFCompareNumerically = 64,
kCFCompareDiacriticInsensitive __attribute__((availability(macosx,introduced=10.5))) = 128,
kCFCompareWidthInsensitive __attribute__((availability(macosx,introduced=10.5))) = 256,
kCFCompareForcedOrdering __attribute__((availability(macosx,introduced=10.5))) = 512
};
extern
CFComparisonResult CFStringCompareWithOptionsAndLocale(CFStringRef theString1, CFStringRef theString2, CFRange rangeToCompare, CFStringCompareFlags compareOptions, CFLocaleRef locale) __attribute__((availability(macosx,introduced=10.5)));
extern
CFComparisonResult CFStringCompareWithOptions(CFStringRef theString1, CFStringRef theString2, CFRange rangeToCompare, CFStringCompareFlags compareOptions);
extern
CFComparisonResult CFStringCompare(CFStringRef theString1, CFStringRef theString2, CFStringCompareFlags compareOptions);
extern
Boolean CFStringFindWithOptionsAndLocale(CFStringRef theString, CFStringRef stringToFind, CFRange rangeToSearch, CFStringCompareFlags searchOptions, CFLocaleRef locale, CFRange *result) __attribute__((availability(macosx,introduced=10.5)));
extern
Boolean CFStringFindWithOptions(CFStringRef theString, CFStringRef stringToFind, CFRange rangeToSearch, CFStringCompareFlags searchOptions, CFRange *result);
extern
CFArrayRef CFStringCreateArrayWithFindResults(CFAllocatorRef alloc, CFStringRef theString, CFStringRef stringToFind, CFRange rangeToSearch, CFStringCompareFlags compareOptions);
extern
CFRange CFStringFind(CFStringRef theString, CFStringRef stringToFind, CFStringCompareFlags compareOptions);
extern
Boolean CFStringHasPrefix(CFStringRef theString, CFStringRef prefix);
extern
Boolean CFStringHasSuffix(CFStringRef theString, CFStringRef suffix);
extern CFRange CFStringGetRangeOfComposedCharactersAtIndex(CFStringRef theString, CFIndex theIndex);
extern Boolean CFStringFindCharacterFromSet(CFStringRef theString, CFCharacterSetRef theSet, CFRange rangeToSearch, CFStringCompareFlags searchOptions, CFRange *result);
extern
void CFStringGetLineBounds(CFStringRef theString, CFRange range, CFIndex *lineBeginIndex, CFIndex *lineEndIndex, CFIndex *contentsEndIndex);
extern
void CFStringGetParagraphBounds(CFStringRef string, CFRange range, CFIndex *parBeginIndex, CFIndex *parEndIndex, CFIndex *contentsEndIndex) __attribute__((availability(macosx,introduced=10.5)));
extern
CFIndex CFStringGetHyphenationLocationBeforeIndex(CFStringRef string, CFIndex location, CFRange limitRange, CFOptionFlags options, CFLocaleRef locale, UTF32Char *character) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFStringIsHyphenationAvailableForLocale(CFLocaleRef locale) __attribute__((availability(macosx,introduced=10.7)));
extern
CFStringRef CFStringCreateByCombiningStrings(CFAllocatorRef alloc, CFArrayRef theArray, CFStringRef separatorString);
extern
CFArrayRef CFStringCreateArrayBySeparatingStrings(CFAllocatorRef alloc, CFStringRef theString, CFStringRef separatorString);
extern
SInt32 CFStringGetIntValue(CFStringRef str);
extern
double CFStringGetDoubleValue(CFStringRef str);
extern
void CFStringAppend(CFMutableStringRef theString, CFStringRef appendedString);
extern
void CFStringAppendCharacters(CFMutableStringRef theString, const UniChar *chars, CFIndex numChars);
extern
void CFStringAppendPascalString(CFMutableStringRef theString, ConstStr255Param pStr, CFStringEncoding encoding);
extern
void CFStringAppendCString(CFMutableStringRef theString, const char *cStr, CFStringEncoding encoding);
extern
void CFStringAppendFormat(CFMutableStringRef theString, CFDictionaryRef formatOptions, CFStringRef format, ...) __attribute__((format(CFString, 3, 4)));
extern
void CFStringAppendFormatAndArguments(CFMutableStringRef theString, CFDictionaryRef formatOptions, CFStringRef format, va_list arguments) __attribute__((format(CFString, 3, 0)));
extern
void CFStringInsert(CFMutableStringRef str, CFIndex idx, CFStringRef insertedStr);
extern
void CFStringDelete(CFMutableStringRef theString, CFRange range);
extern
void CFStringReplace(CFMutableStringRef theString, CFRange range, CFStringRef replacement);
extern
void CFStringReplaceAll(CFMutableStringRef theString, CFStringRef replacement);
extern
CFIndex CFStringFindAndReplace(CFMutableStringRef theString, CFStringRef stringToFind, CFStringRef replacementString, CFRange rangeToSearch, CFStringCompareFlags compareOptions);
extern
void CFStringSetExternalCharactersNoCopy(CFMutableStringRef theString, UniChar *chars, CFIndex length, CFIndex capacity);
extern
void CFStringPad(CFMutableStringRef theString, CFStringRef padString, CFIndex length, CFIndex indexIntoPad);
extern
void CFStringTrim(CFMutableStringRef theString, CFStringRef trimString);
extern
void CFStringTrimWhitespace(CFMutableStringRef theString);
extern
void CFStringLowercase(CFMutableStringRef theString, CFLocaleRef locale);
extern
void CFStringUppercase(CFMutableStringRef theString, CFLocaleRef locale);
extern
void CFStringCapitalize(CFMutableStringRef theString, CFLocaleRef locale);
typedef CFIndex CFStringNormalizationForm; enum {
kCFStringNormalizationFormD = 0,
kCFStringNormalizationFormKD,
kCFStringNormalizationFormC,
kCFStringNormalizationFormKC
};
extern void CFStringNormalize(CFMutableStringRef theString, CFStringNormalizationForm theForm);
extern
void CFStringFold(CFMutableStringRef theString, CFStringCompareFlags theFlags, CFLocaleRef theLocale) __attribute__((availability(macosx,introduced=10.5)));
extern
Boolean CFStringTransform(CFMutableStringRef string, CFRange *range, CFStringRef transform, Boolean reverse);
extern const CFStringRef kCFStringTransformStripCombiningMarks;
extern const CFStringRef kCFStringTransformToLatin;
extern const CFStringRef kCFStringTransformFullwidthHalfwidth;
extern const CFStringRef kCFStringTransformLatinKatakana;
extern const CFStringRef kCFStringTransformLatinHiragana;
extern const CFStringRef kCFStringTransformHiraganaKatakana;
extern const CFStringRef kCFStringTransformMandarinLatin;
extern const CFStringRef kCFStringTransformLatinHangul;
extern const CFStringRef kCFStringTransformLatinArabic;
extern const CFStringRef kCFStringTransformLatinHebrew;
extern const CFStringRef kCFStringTransformLatinThai;
extern const CFStringRef kCFStringTransformLatinCyrillic;
extern const CFStringRef kCFStringTransformLatinGreek;
extern const CFStringRef kCFStringTransformToXMLHex;
extern const CFStringRef kCFStringTransformToUnicodeName;
extern const CFStringRef kCFStringTransformStripDiacritics __attribute__((availability(macosx,introduced=10.5)));
extern
Boolean CFStringIsEncodingAvailable(CFStringEncoding encoding);
extern
const CFStringEncoding *CFStringGetListOfAvailableEncodings(void);
extern
CFStringRef CFStringGetNameOfEncoding(CFStringEncoding encoding);
extern
unsigned long CFStringConvertEncodingToNSStringEncoding(CFStringEncoding encoding);
extern
CFStringEncoding CFStringConvertNSStringEncodingToEncoding(unsigned long encoding);
extern
UInt32 CFStringConvertEncodingToWindowsCodepage(CFStringEncoding encoding);
extern
CFStringEncoding CFStringConvertWindowsCodepageToEncoding(UInt32 codepage);
extern
CFStringEncoding CFStringConvertIANACharSetNameToEncoding(CFStringRef theString);
extern
CFStringRef CFStringConvertEncodingToIANACharSetName(CFStringEncoding encoding);
extern
CFStringEncoding CFStringGetMostCompatibleMacStringEncoding(CFStringEncoding encoding);
typedef struct {
UniChar buffer[64];
CFStringRef theString;
const UniChar *directUniCharBuffer;
const char *directCStringBuffer;
CFRange rangeToBuffer;
CFIndex bufferedRangeStart;
CFIndex bufferedRangeEnd;
} CFStringInlineBuffer;
static __inline__ __attribute__((always_inline)) void CFStringInitInlineBuffer(CFStringRef str, CFStringInlineBuffer *buf, CFRange range) {
buf->theString = str;
buf->rangeToBuffer = range;
buf->directCStringBuffer = (buf->directUniCharBuffer = CFStringGetCharactersPtr(str)) ? __null : CFStringGetCStringPtr(str, kCFStringEncodingASCII);
buf->bufferedRangeStart = buf->bufferedRangeEnd = 0;
}
static __inline__ __attribute__((always_inline)) UniChar CFStringGetCharacterFromInlineBuffer(CFStringInlineBuffer *buf, CFIndex idx) {
if (idx < 0 || idx >= buf->rangeToBuffer.length) return 0;
if (buf->directUniCharBuffer) return buf->directUniCharBuffer[idx + buf->rangeToBuffer.location];
if (buf->directCStringBuffer) return (UniChar)(buf->directCStringBuffer[idx + buf->rangeToBuffer.location]);
if (idx >= buf->bufferedRangeEnd || idx < buf->bufferedRangeStart) {
if ((buf->bufferedRangeStart = idx - 4) < 0) buf->bufferedRangeStart = 0;
buf->bufferedRangeEnd = buf->bufferedRangeStart + 64;
if (buf->bufferedRangeEnd > buf->rangeToBuffer.length) buf->bufferedRangeEnd = buf->rangeToBuffer.length;
CFStringGetCharacters(buf->theString, CFRangeMake(buf->rangeToBuffer.location + buf->bufferedRangeStart, buf->bufferedRangeEnd - buf->bufferedRangeStart), buf->buffer);
}
return buf->buffer[idx - buf->bufferedRangeStart];
}
static __inline__ __attribute__((always_inline)) Boolean CFStringIsSurrogateHighCharacter(UniChar character) {
return ((character >= 0xD800UL) && (character <= 0xDBFFUL) ? true : false);
}
static __inline__ __attribute__((always_inline)) Boolean CFStringIsSurrogateLowCharacter(UniChar character) {
return ((character >= 0xDC00UL) && (character <= 0xDFFFUL) ? true : false);
}
static __inline__ __attribute__((always_inline)) UTF32Char CFStringGetLongCharacterForSurrogatePair(UniChar surrogateHigh, UniChar surrogateLow) {
return (UTF32Char)(((surrogateHigh - 0xD800UL) << 10) + (surrogateLow - 0xDC00UL) + 0x0010000UL);
}
static __inline__ __attribute__((always_inline)) Boolean CFStringGetSurrogatePairForLongCharacter(UTF32Char character, UniChar *surrogates) {
if ((character > 0xFFFFUL) && (character < 0x110000UL)) {
character -= 0x10000;
if (__null != surrogates) {
surrogates[0] = (UniChar)((character >> 10) + 0xD800UL);
surrogates[1] = (UniChar)((character & 0x3FF) + 0xDC00UL);
}
return true;
} else {
if (__null != surrogates) *surrogates = (UniChar)character;
return false;
}
}
extern
void CFShow(CFTypeRef obj);
extern
void CFShowStr(CFStringRef str);
extern
CFStringRef __CFStringMakeConstantString(const char *cStr) __attribute__((format_arg(1)));
}
extern "C" {
extern
CFTypeID CFTimeZoneGetTypeID(void);
extern
CFTimeZoneRef CFTimeZoneCopySystem(void);
extern
void CFTimeZoneResetSystem(void);
extern
CFTimeZoneRef CFTimeZoneCopyDefault(void);
extern
void CFTimeZoneSetDefault(CFTimeZoneRef tz);
extern
CFArrayRef CFTimeZoneCopyKnownNames(void);
extern
CFDictionaryRef CFTimeZoneCopyAbbreviationDictionary(void);
extern
void CFTimeZoneSetAbbreviationDictionary(CFDictionaryRef dict);
extern
CFTimeZoneRef CFTimeZoneCreate(CFAllocatorRef allocator, CFStringRef name, CFDataRef data);
extern
CFTimeZoneRef CFTimeZoneCreateWithTimeIntervalFromGMT(CFAllocatorRef allocator, CFTimeInterval ti);
extern
CFTimeZoneRef CFTimeZoneCreateWithName(CFAllocatorRef allocator, CFStringRef name, Boolean tryAbbrev);
extern
CFStringRef CFTimeZoneGetName(CFTimeZoneRef tz);
extern
CFDataRef CFTimeZoneGetData(CFTimeZoneRef tz);
extern
CFTimeInterval CFTimeZoneGetSecondsFromGMT(CFTimeZoneRef tz, CFAbsoluteTime at);
extern
CFStringRef CFTimeZoneCopyAbbreviation(CFTimeZoneRef tz, CFAbsoluteTime at);
extern
Boolean CFTimeZoneIsDaylightSavingTime(CFTimeZoneRef tz, CFAbsoluteTime at);
extern
CFTimeInterval CFTimeZoneGetDaylightSavingTimeOffset(CFTimeZoneRef tz, CFAbsoluteTime at) __attribute__((availability(macosx,introduced=10.5)));
extern
CFAbsoluteTime CFTimeZoneGetNextDaylightSavingTimeTransition(CFTimeZoneRef tz, CFAbsoluteTime at) __attribute__((availability(macosx,introduced=10.5)));
typedef CFIndex CFTimeZoneNameStyle; enum {
kCFTimeZoneNameStyleStandard,
kCFTimeZoneNameStyleShortStandard,
kCFTimeZoneNameStyleDaylightSaving,
kCFTimeZoneNameStyleShortDaylightSaving,
kCFTimeZoneNameStyleGeneric,
kCFTimeZoneNameStyleShortGeneric
} __attribute__((availability(macosx,introduced=10.5)));
extern
CFStringRef CFTimeZoneCopyLocalizedName(CFTimeZoneRef tz, CFTimeZoneNameStyle style, CFLocaleRef locale) __attribute__((availability(macosx,introduced=10.5)));
extern
const CFStringRef kCFTimeZoneSystemTimeZoneDidChangeNotification __attribute__((availability(macosx,introduced=10.5)));
}
extern "C" {
typedef struct __attribute__((objc_bridge_mutable(NSCalendar))) __CFCalendar * CFCalendarRef;
extern
CFTypeID CFCalendarGetTypeID(void);
extern
CFCalendarRef CFCalendarCopyCurrent(void);
extern
CFCalendarRef CFCalendarCreateWithIdentifier(CFAllocatorRef allocator, CFStringRef identifier);
extern
CFStringRef CFCalendarGetIdentifier(CFCalendarRef calendar);
extern
CFLocaleRef CFCalendarCopyLocale(CFCalendarRef calendar);
extern
void CFCalendarSetLocale(CFCalendarRef calendar, CFLocaleRef locale);
extern
CFTimeZoneRef CFCalendarCopyTimeZone(CFCalendarRef calendar);
extern
void CFCalendarSetTimeZone(CFCalendarRef calendar, CFTimeZoneRef tz);
extern
CFIndex CFCalendarGetFirstWeekday(CFCalendarRef calendar);
extern
void CFCalendarSetFirstWeekday(CFCalendarRef calendar, CFIndex wkdy);
extern
CFIndex CFCalendarGetMinimumDaysInFirstWeek(CFCalendarRef calendar);
extern
void CFCalendarSetMinimumDaysInFirstWeek(CFCalendarRef calendar, CFIndex mwd);
typedef CFOptionFlags CFCalendarUnit; enum {
kCFCalendarUnitEra = (1UL << 1),
kCFCalendarUnitYear = (1UL << 2),
kCFCalendarUnitMonth = (1UL << 3),
kCFCalendarUnitDay = (1UL << 4),
kCFCalendarUnitHour = (1UL << 5),
kCFCalendarUnitMinute = (1UL << 6),
kCFCalendarUnitSecond = (1UL << 7),
kCFCalendarUnitWeek __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" ))) = (1UL << 8),
kCFCalendarUnitWeekday = (1UL << 9),
kCFCalendarUnitWeekdayOrdinal = (1UL << 10),
kCFCalendarUnitQuarter __attribute__((availability(macosx,introduced=10.6))) = (1UL << 11),
kCFCalendarUnitWeekOfMonth __attribute__((availability(macosx,introduced=10.7))) = (1UL << 12),
kCFCalendarUnitWeekOfYear __attribute__((availability(macosx,introduced=10.7))) = (1UL << 13),
kCFCalendarUnitYearForWeekOfYear __attribute__((availability(macosx,introduced=10.7))) = (1UL << 14),
};
extern
CFRange CFCalendarGetMinimumRangeOfUnit(CFCalendarRef calendar, CFCalendarUnit unit);
extern
CFRange CFCalendarGetMaximumRangeOfUnit(CFCalendarRef calendar, CFCalendarUnit unit);
extern
CFRange CFCalendarGetRangeOfUnit(CFCalendarRef calendar, CFCalendarUnit smallerUnit, CFCalendarUnit biggerUnit, CFAbsoluteTime at);
extern
CFIndex CFCalendarGetOrdinalityOfUnit(CFCalendarRef calendar, CFCalendarUnit smallerUnit, CFCalendarUnit biggerUnit, CFAbsoluteTime at);
extern
Boolean CFCalendarGetTimeRangeOfUnit(CFCalendarRef calendar, CFCalendarUnit unit, CFAbsoluteTime at, CFAbsoluteTime *startp, CFTimeInterval *tip) __attribute__((availability(macosx,introduced=10.5)));
extern
Boolean CFCalendarComposeAbsoluteTime(CFCalendarRef calendar, CFAbsoluteTime *at, const char *componentDesc, ...);
extern
Boolean CFCalendarDecomposeAbsoluteTime(CFCalendarRef calendar, CFAbsoluteTime at, const char *componentDesc, ...);
enum {
kCFCalendarComponentsWrap = (1UL << 0)
};
extern
Boolean CFCalendarAddComponents(CFCalendarRef calendar, CFAbsoluteTime *at, CFOptionFlags options, const char *componentDesc, ...);
extern
Boolean CFCalendarGetComponentDifference(CFCalendarRef calendar, CFAbsoluteTime startingAT, CFAbsoluteTime resultAT, CFOptionFlags options, const char *componentDesc, ...);
}
extern "C" {
typedef struct __CFDateFormatter *CFDateFormatterRef;
extern
CFStringRef CFDateFormatterCreateDateFormatFromTemplate(CFAllocatorRef allocator, CFStringRef tmplate, CFOptionFlags options, CFLocaleRef locale) __attribute__((availability(macosx,introduced=10.6)));
extern
CFTypeID CFDateFormatterGetTypeID(void);
typedef CFIndex CFDateFormatterStyle; enum {
kCFDateFormatterNoStyle = 0,
kCFDateFormatterShortStyle = 1,
kCFDateFormatterMediumStyle = 2,
kCFDateFormatterLongStyle = 3,
kCFDateFormatterFullStyle = 4
};
extern
CFDateFormatterRef CFDateFormatterCreate(CFAllocatorRef allocator, CFLocaleRef locale, CFDateFormatterStyle dateStyle, CFDateFormatterStyle timeStyle);
extern
CFLocaleRef CFDateFormatterGetLocale(CFDateFormatterRef formatter);
extern
CFDateFormatterStyle CFDateFormatterGetDateStyle(CFDateFormatterRef formatter);
extern
CFDateFormatterStyle CFDateFormatterGetTimeStyle(CFDateFormatterRef formatter);
extern
CFStringRef CFDateFormatterGetFormat(CFDateFormatterRef formatter);
extern
void CFDateFormatterSetFormat(CFDateFormatterRef formatter, CFStringRef formatString);
extern
CFStringRef CFDateFormatterCreateStringWithDate(CFAllocatorRef allocator, CFDateFormatterRef formatter, CFDateRef date);
extern
CFStringRef CFDateFormatterCreateStringWithAbsoluteTime(CFAllocatorRef allocator, CFDateFormatterRef formatter, CFAbsoluteTime at);
extern
CFDateRef CFDateFormatterCreateDateFromString(CFAllocatorRef allocator, CFDateFormatterRef formatter, CFStringRef string, CFRange *rangep);
extern
Boolean CFDateFormatterGetAbsoluteTimeFromString(CFDateFormatterRef formatter, CFStringRef string, CFRange *rangep, CFAbsoluteTime *atp);
extern
void CFDateFormatterSetProperty(CFDateFormatterRef formatter, CFStringRef key, CFTypeRef value);
extern
CFTypeRef CFDateFormatterCopyProperty(CFDateFormatterRef formatter, CFStringRef key);
extern const CFStringRef kCFDateFormatterIsLenient;
extern const CFStringRef kCFDateFormatterTimeZone;
extern const CFStringRef kCFDateFormatterCalendarName;
extern const CFStringRef kCFDateFormatterDefaultFormat;
extern const CFStringRef kCFDateFormatterTwoDigitStartDate;
extern const CFStringRef kCFDateFormatterDefaultDate;
extern const CFStringRef kCFDateFormatterCalendar;
extern const CFStringRef kCFDateFormatterEraSymbols;
extern const CFStringRef kCFDateFormatterMonthSymbols;
extern const CFStringRef kCFDateFormatterShortMonthSymbols;
extern const CFStringRef kCFDateFormatterWeekdaySymbols;
extern const CFStringRef kCFDateFormatterShortWeekdaySymbols;
extern const CFStringRef kCFDateFormatterAMSymbol;
extern const CFStringRef kCFDateFormatterPMSymbol;
extern const CFStringRef kCFDateFormatterLongEraSymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterVeryShortMonthSymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterStandaloneMonthSymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterShortStandaloneMonthSymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterVeryShortStandaloneMonthSymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterVeryShortWeekdaySymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterStandaloneWeekdaySymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterShortStandaloneWeekdaySymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterVeryShortStandaloneWeekdaySymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterQuarterSymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterShortQuarterSymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterStandaloneQuarterSymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterShortStandaloneQuarterSymbols __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterGregorianStartDate __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFDateFormatterDoesRelativeDateFormattingKey __attribute__((availability(macosx,introduced=10.6)));
}
extern "C" {
typedef struct __attribute__((objc_bridge(NSError))) __CFError * CFErrorRef;
extern
CFTypeID CFErrorGetTypeID(void) __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFErrorDomainPOSIX __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFErrorDomainOSStatus __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFErrorDomainMach __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFErrorDomainCocoa __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFErrorLocalizedDescriptionKey __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFErrorLocalizedFailureReasonKey __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFErrorLocalizedRecoverySuggestionKey __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFErrorDescriptionKey __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFErrorUnderlyingErrorKey __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFErrorURLKey __attribute__((availability(macosx,introduced=10.7)));
extern const CFStringRef kCFErrorFilePathKey __attribute__((availability(macosx,introduced=10.7)));
extern
CFErrorRef CFErrorCreate(CFAllocatorRef allocator, CFStringRef domain, CFIndex code, CFDictionaryRef userInfo) __attribute__((availability(macosx,introduced=10.5)));
extern
CFErrorRef CFErrorCreateWithUserInfoKeysAndValues(CFAllocatorRef allocator, CFStringRef domain, CFIndex code, const void *const *userInfoKeys, const void *const *userInfoValues, CFIndex numUserInfoValues) __attribute__((availability(macosx,introduced=10.5)));
extern
CFStringRef CFErrorGetDomain(CFErrorRef err) __attribute__((availability(macosx,introduced=10.5)));
extern
CFIndex CFErrorGetCode(CFErrorRef err) __attribute__((availability(macosx,introduced=10.5)));
extern
CFDictionaryRef CFErrorCopyUserInfo(CFErrorRef err) __attribute__((availability(macosx,introduced=10.5)));
extern
CFStringRef CFErrorCopyDescription(CFErrorRef err) __attribute__((availability(macosx,introduced=10.5)));
extern
CFStringRef CFErrorCopyFailureReason(CFErrorRef err) __attribute__((availability(macosx,introduced=10.5)));
extern
CFStringRef CFErrorCopyRecoverySuggestion(CFErrorRef err) __attribute__((availability(macosx,introduced=10.5)));
}
extern "C" {
typedef const struct __attribute__((objc_bridge(NSNumber))) __CFBoolean * CFBooleanRef;
extern
const CFBooleanRef kCFBooleanTrue;
extern
const CFBooleanRef kCFBooleanFalse;
extern
CFTypeID CFBooleanGetTypeID(void);
extern
Boolean CFBooleanGetValue(CFBooleanRef boolean);
typedef CFIndex CFNumberType; enum {
kCFNumberSInt8Type = 1,
kCFNumberSInt16Type = 2,
kCFNumberSInt32Type = 3,
kCFNumberSInt64Type = 4,
kCFNumberFloat32Type = 5,
kCFNumberFloat64Type = 6,
kCFNumberCharType = 7,
kCFNumberShortType = 8,
kCFNumberIntType = 9,
kCFNumberLongType = 10,
kCFNumberLongLongType = 11,
kCFNumberFloatType = 12,
kCFNumberDoubleType = 13,
kCFNumberCFIndexType = 14,
kCFNumberNSIntegerType __attribute__((availability(macosx,introduced=10.5))) = 15,
kCFNumberCGFloatType __attribute__((availability(macosx,introduced=10.5))) = 16,
kCFNumberMaxType = 16
};
typedef const struct __attribute__((objc_bridge(NSNumber))) __CFNumber * CFNumberRef;
extern
const CFNumberRef kCFNumberPositiveInfinity;
extern
const CFNumberRef kCFNumberNegativeInfinity;
extern
const CFNumberRef kCFNumberNaN;
extern
CFTypeID CFNumberGetTypeID(void);
extern
CFNumberRef CFNumberCreate(CFAllocatorRef allocator, CFNumberType theType, const void *valuePtr);
extern
CFNumberType CFNumberGetType(CFNumberRef number);
extern
CFIndex CFNumberGetByteSize(CFNumberRef number);
extern
Boolean CFNumberIsFloatType(CFNumberRef number);
extern
Boolean CFNumberGetValue(CFNumberRef number, CFNumberType theType, void *valuePtr);
extern
CFComparisonResult CFNumberCompare(CFNumberRef number, CFNumberRef otherNumber, void *context);
}
extern "C" {
typedef struct __CFNumberFormatter *CFNumberFormatterRef;
extern
CFTypeID CFNumberFormatterGetTypeID(void);
typedef CFIndex CFNumberFormatterStyle; enum {
kCFNumberFormatterNoStyle = 0,
kCFNumberFormatterDecimalStyle = 1,
kCFNumberFormatterCurrencyStyle = 2,
kCFNumberFormatterPercentStyle = 3,
kCFNumberFormatterScientificStyle = 4,
kCFNumberFormatterSpellOutStyle = 5
};
extern
CFNumberFormatterRef CFNumberFormatterCreate(CFAllocatorRef allocator, CFLocaleRef locale, CFNumberFormatterStyle style);
extern
CFLocaleRef CFNumberFormatterGetLocale(CFNumberFormatterRef formatter);
extern
CFNumberFormatterStyle CFNumberFormatterGetStyle(CFNumberFormatterRef formatter);
extern
CFStringRef CFNumberFormatterGetFormat(CFNumberFormatterRef formatter);
extern
void CFNumberFormatterSetFormat(CFNumberFormatterRef formatter, CFStringRef formatString);
extern
CFStringRef CFNumberFormatterCreateStringWithNumber(CFAllocatorRef allocator, CFNumberFormatterRef formatter, CFNumberRef number);
extern
CFStringRef CFNumberFormatterCreateStringWithValue(CFAllocatorRef allocator, CFNumberFormatterRef formatter, CFNumberType numberType, const void *valuePtr);
typedef CFOptionFlags CFNumberFormatterOptionFlags; enum {
kCFNumberFormatterParseIntegersOnly = 1
};
extern
CFNumberRef CFNumberFormatterCreateNumberFromString(CFAllocatorRef allocator, CFNumberFormatterRef formatter, CFStringRef string, CFRange *rangep, CFOptionFlags options);
extern
Boolean CFNumberFormatterGetValueFromString(CFNumberFormatterRef formatter, CFStringRef string, CFRange *rangep, CFNumberType numberType, void *valuePtr);
extern
void CFNumberFormatterSetProperty(CFNumberFormatterRef formatter, CFStringRef key, CFTypeRef value);
extern
CFTypeRef CFNumberFormatterCopyProperty(CFNumberFormatterRef formatter, CFStringRef key);
extern const CFStringRef kCFNumberFormatterCurrencyCode;
extern const CFStringRef kCFNumberFormatterDecimalSeparator;
extern const CFStringRef kCFNumberFormatterCurrencyDecimalSeparator;
extern const CFStringRef kCFNumberFormatterAlwaysShowDecimalSeparator;
extern const CFStringRef kCFNumberFormatterGroupingSeparator;
extern const CFStringRef kCFNumberFormatterUseGroupingSeparator;
extern const CFStringRef kCFNumberFormatterPercentSymbol;
extern const CFStringRef kCFNumberFormatterZeroSymbol;
extern const CFStringRef kCFNumberFormatterNaNSymbol;
extern const CFStringRef kCFNumberFormatterInfinitySymbol;
extern const CFStringRef kCFNumberFormatterMinusSign;
extern const CFStringRef kCFNumberFormatterPlusSign;
extern const CFStringRef kCFNumberFormatterCurrencySymbol;
extern const CFStringRef kCFNumberFormatterExponentSymbol;
extern const CFStringRef kCFNumberFormatterMinIntegerDigits;
extern const CFStringRef kCFNumberFormatterMaxIntegerDigits;
extern const CFStringRef kCFNumberFormatterMinFractionDigits;
extern const CFStringRef kCFNumberFormatterMaxFractionDigits;
extern const CFStringRef kCFNumberFormatterGroupingSize;
extern const CFStringRef kCFNumberFormatterSecondaryGroupingSize;
extern const CFStringRef kCFNumberFormatterRoundingMode;
extern const CFStringRef kCFNumberFormatterRoundingIncrement;
extern const CFStringRef kCFNumberFormatterFormatWidth;
extern const CFStringRef kCFNumberFormatterPaddingPosition;
extern const CFStringRef kCFNumberFormatterPaddingCharacter;
extern const CFStringRef kCFNumberFormatterDefaultFormat;
extern const CFStringRef kCFNumberFormatterMultiplier;
extern const CFStringRef kCFNumberFormatterPositivePrefix;
extern const CFStringRef kCFNumberFormatterPositiveSuffix;
extern const CFStringRef kCFNumberFormatterNegativePrefix;
extern const CFStringRef kCFNumberFormatterNegativeSuffix;
extern const CFStringRef kCFNumberFormatterPerMillSymbol;
extern const CFStringRef kCFNumberFormatterInternationalCurrencySymbol;
extern const CFStringRef kCFNumberFormatterCurrencyGroupingSeparator __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFNumberFormatterIsLenient __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFNumberFormatterUseSignificantDigits __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFNumberFormatterMinSignificantDigits __attribute__((availability(macosx,introduced=10.5)));
extern const CFStringRef kCFNumberFormatterMaxSignificantDigits __attribute__((availability(macosx,introduced=10.5)));
typedef CFIndex CFNumberFormatterRoundingMode; enum {
kCFNumberFormatterRoundCeiling = 0,
kCFNumberFormatterRoundFloor = 1,
kCFNumberFormatterRoundDown = 2,
kCFNumberFormatterRoundUp = 3,
kCFNumberFormatterRoundHalfEven = 4,
kCFNumberFormatterRoundHalfDown = 5,
kCFNumberFormatterRoundHalfUp = 6
};
typedef CFIndex CFNumberFormatterPadPosition; enum {
kCFNumberFormatterPadBeforePrefix = 0,
kCFNumberFormatterPadAfterPrefix = 1,
kCFNumberFormatterPadBeforeSuffix = 2,
kCFNumberFormatterPadAfterSuffix = 3
};
extern
Boolean CFNumberFormatterGetDecimalInfoForCurrencyCode(CFStringRef currencyCode, int32_t *defaultFractionDigits, double *roundingIncrement);
}
extern "C" {
extern
const CFStringRef kCFPreferencesAnyApplication;
extern
const CFStringRef kCFPreferencesCurrentApplication;
extern
const CFStringRef kCFPreferencesAnyHost;
extern
const CFStringRef kCFPreferencesCurrentHost;
extern
const CFStringRef kCFPreferencesAnyUser;
extern
const CFStringRef kCFPreferencesCurrentUser;
extern
CFPropertyListRef CFPreferencesCopyAppValue(CFStringRef key, CFStringRef applicationID);
extern
Boolean CFPreferencesGetAppBooleanValue(CFStringRef key, CFStringRef applicationID, Boolean *keyExistsAndHasValidFormat);
extern
CFIndex CFPreferencesGetAppIntegerValue(CFStringRef key, CFStringRef applicationID, Boolean *keyExistsAndHasValidFormat);
extern
void CFPreferencesSetAppValue(CFStringRef key, CFPropertyListRef value, CFStringRef applicationID);
extern
void CFPreferencesAddSuitePreferencesToApp(CFStringRef applicationID, CFStringRef suiteID);
extern
void CFPreferencesRemoveSuitePreferencesFromApp(CFStringRef applicationID, CFStringRef suiteID);
extern
Boolean CFPreferencesAppSynchronize(CFStringRef applicationID);
extern
CFPropertyListRef CFPreferencesCopyValue(CFStringRef key, CFStringRef applicationID, CFStringRef userName, CFStringRef hostName);
extern
CFDictionaryRef CFPreferencesCopyMultiple(CFArrayRef keysToFetch, CFStringRef applicationID, CFStringRef userName, CFStringRef hostName);
extern
void CFPreferencesSetValue(CFStringRef key, CFPropertyListRef value, CFStringRef applicationID, CFStringRef userName, CFStringRef hostName);
extern
void CFPreferencesSetMultiple(CFDictionaryRef keysToSet, CFArrayRef keysToRemove, CFStringRef applicationID, CFStringRef userName, CFStringRef hostName);
extern
Boolean CFPreferencesSynchronize(CFStringRef applicationID, CFStringRef userName, CFStringRef hostName);
extern
CFArrayRef CFPreferencesCopyApplicationList(CFStringRef userName, CFStringRef hostName) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" )));
extern
CFArrayRef CFPreferencesCopyKeyList(CFStringRef applicationID, CFStringRef userName, CFStringRef hostName);
extern
Boolean CFPreferencesAppValueIsForced(CFStringRef key, CFStringRef applicationID);
}
extern "C" {
typedef CFIndex CFURLPathStyle; enum {
kCFURLPOSIXPathStyle = 0,
kCFURLHFSPathStyle __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" ))),
kCFURLWindowsPathStyle
};
typedef const struct __attribute__((objc_bridge(NSURL))) __CFURL * CFURLRef;
extern
CFTypeID CFURLGetTypeID(void);
extern
CFURLRef CFURLCreateWithBytes(CFAllocatorRef allocator, const UInt8 *URLBytes, CFIndex length, CFStringEncoding encoding, CFURLRef baseURL);
extern
CFDataRef CFURLCreateData(CFAllocatorRef allocator, CFURLRef url, CFStringEncoding encoding, Boolean escapeWhitespace);
extern
CFURLRef CFURLCreateWithString(CFAllocatorRef allocator, CFStringRef URLString, CFURLRef baseURL);
extern
CFURLRef CFURLCreateAbsoluteURLWithBytes(CFAllocatorRef alloc, const UInt8 *relativeURLBytes, CFIndex length, CFStringEncoding encoding, CFURLRef baseURL, Boolean useCompatibilityMode);
extern
CFURLRef CFURLCreateWithFileSystemPath(CFAllocatorRef allocator, CFStringRef filePath, CFURLPathStyle pathStyle, Boolean isDirectory);
extern
CFURLRef CFURLCreateFromFileSystemRepresentation(CFAllocatorRef allocator, const UInt8 *buffer, CFIndex bufLen, Boolean isDirectory);
extern
CFURLRef CFURLCreateWithFileSystemPathRelativeToBase(CFAllocatorRef allocator, CFStringRef filePath, CFURLPathStyle pathStyle, Boolean isDirectory, CFURLRef baseURL);
extern
CFURLRef CFURLCreateFromFileSystemRepresentationRelativeToBase(CFAllocatorRef allocator, const UInt8 *buffer, CFIndex bufLen, Boolean isDirectory, CFURLRef baseURL);
extern
Boolean CFURLGetFileSystemRepresentation(CFURLRef url, Boolean resolveAgainstBase, UInt8 *buffer, CFIndex maxBufLen);
extern
CFURLRef CFURLCopyAbsoluteURL(CFURLRef relativeURL);
extern
CFStringRef CFURLGetString(CFURLRef anURL);
extern
CFURLRef CFURLGetBaseURL(CFURLRef anURL);
extern
Boolean CFURLCanBeDecomposed(CFURLRef anURL);
extern
CFStringRef CFURLCopyScheme(CFURLRef anURL);
extern
CFStringRef CFURLCopyNetLocation(CFURLRef anURL);
extern
CFStringRef CFURLCopyPath(CFURLRef anURL);
extern
CFStringRef CFURLCopyStrictPath(CFURLRef anURL, Boolean *isAbsolute);
extern
CFStringRef CFURLCopyFileSystemPath(CFURLRef anURL, CFURLPathStyle pathStyle);
extern
Boolean CFURLHasDirectoryPath(CFURLRef anURL);
extern
CFStringRef CFURLCopyResourceSpecifier(CFURLRef anURL);
extern
CFStringRef CFURLCopyHostName(CFURLRef anURL);
extern
SInt32 CFURLGetPortNumber(CFURLRef anURL);
extern
CFStringRef CFURLCopyUserName(CFURLRef anURL);
extern
CFStringRef CFURLCopyPassword(CFURLRef anURL);
extern
CFStringRef CFURLCopyParameterString(CFURLRef anURL, CFStringRef charactersToLeaveEscaped);
extern
CFStringRef CFURLCopyQueryString(CFURLRef anURL, CFStringRef charactersToLeaveEscaped);
extern
CFStringRef CFURLCopyFragment(CFURLRef anURL, CFStringRef charactersToLeaveEscaped);
extern
CFStringRef CFURLCopyLastPathComponent(CFURLRef url);
extern
CFStringRef CFURLCopyPathExtension(CFURLRef url);
extern
CFURLRef CFURLCreateCopyAppendingPathComponent(CFAllocatorRef allocator, CFURLRef url, CFStringRef pathComponent, Boolean isDirectory);
extern
CFURLRef CFURLCreateCopyDeletingLastPathComponent(CFAllocatorRef allocator, CFURLRef url);
extern
CFURLRef CFURLCreateCopyAppendingPathExtension(CFAllocatorRef allocator, CFURLRef url, CFStringRef extension);
extern
CFURLRef CFURLCreateCopyDeletingPathExtension(CFAllocatorRef allocator, CFURLRef url);
extern
CFIndex CFURLGetBytes(CFURLRef url, UInt8 *buffer, CFIndex bufferLength);
typedef CFIndex CFURLComponentType; enum {
kCFURLComponentScheme = 1,
kCFURLComponentNetLocation = 2,
kCFURLComponentPath = 3,
kCFURLComponentResourceSpecifier = 4,
kCFURLComponentUser = 5,
kCFURLComponentPassword = 6,
kCFURLComponentUserInfo = 7,
kCFURLComponentHost = 8,
kCFURLComponentPort = 9,
kCFURLComponentParameterString = 10,
kCFURLComponentQuery = 11,
kCFURLComponentFragment = 12
};
extern
CFRange CFURLGetByteRangeForComponent(CFURLRef url, CFURLComponentType component, CFRange *rangeIncludingSeparators);
extern
CFStringRef CFURLCreateStringByReplacingPercentEscapes(CFAllocatorRef allocator, CFStringRef originalString, CFStringRef charactersToLeaveEscaped);
extern
CFStringRef CFURLCreateStringByReplacingPercentEscapesUsingEncoding(CFAllocatorRef allocator, CFStringRef origString, CFStringRef charsToLeaveEscaped, CFStringEncoding encoding);
extern
CFStringRef CFURLCreateStringByAddingPercentEscapes(CFAllocatorRef allocator, CFStringRef originalString, CFStringRef charactersToLeaveUnescaped, CFStringRef legalURLCharactersToBeEscaped, CFStringEncoding encoding);
extern
Boolean CFURLIsFileReferenceURL(CFURLRef url) __attribute__((availability(macosx,introduced=10.9)));
extern
CFURLRef CFURLCreateFileReferenceURL(CFAllocatorRef allocator, CFURLRef url, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.6)));
extern
CFURLRef CFURLCreateFilePathURL(CFAllocatorRef allocator, CFURLRef url, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.6)));
struct FSRef;
extern
CFURLRef CFURLCreateFromFSRef(CFAllocatorRef allocator, const struct FSRef *fsRef) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" )));
extern
Boolean CFURLGetFSRef(CFURLRef url, struct FSRef *fsRef) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" )));
extern
Boolean CFURLCopyResourcePropertyForKey(CFURLRef url, CFStringRef key, void *propertyValueTypeRefPtr, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.6)));
extern
CFDictionaryRef CFURLCopyResourcePropertiesForKeys(CFURLRef url, CFArrayRef keys, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.6)));
extern
Boolean CFURLSetResourcePropertyForKey(CFURLRef url, CFStringRef key, CFTypeRef propertyValue, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.6)));
extern
Boolean CFURLSetResourcePropertiesForKeys(CFURLRef url, CFDictionaryRef keyedPropertyValues, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLKeysOfUnsetValuesKey __attribute__((availability(macosx,introduced=10.7)));
extern
void CFURLClearResourcePropertyCacheForKey(CFURLRef url, CFStringRef key) __attribute__((availability(macosx,introduced=10.6)));
extern
void CFURLClearResourcePropertyCache(CFURLRef url) __attribute__((availability(macosx,introduced=10.6)));
extern
void CFURLSetTemporaryResourcePropertyForKey(CFURLRef url, CFStringRef key, CFTypeRef propertyValue) __attribute__((availability(macosx,introduced=10.6)));
extern
Boolean CFURLResourceIsReachable(CFURLRef url, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLNameKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLLocalizedNameKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLIsRegularFileKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLIsDirectoryKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLIsSymbolicLinkKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLIsVolumeKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLIsPackageKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLIsSystemImmutableKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLIsUserImmutableKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLIsHiddenKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLHasHiddenExtensionKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLCreationDateKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLContentAccessDateKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLContentModificationDateKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLAttributeModificationDateKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLLinkCountKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLParentDirectoryURLKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeURLKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLTypeIdentifierKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLLocalizedTypeDescriptionKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLLabelNumberKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLLabelColorKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLLocalizedLabelKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLEffectiveIconKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLCustomIconKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLFileResourceIdentifierKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeIdentifierKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLPreferredIOBlockSizeKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLIsReadableKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLIsWritableKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLIsExecutableKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLFileSecurityKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLIsExcludedFromBackupKey __attribute__((availability(macosx,introduced=10.8)));
extern
const CFStringRef kCFURLTagNamesKey __attribute__((availability(macosx,introduced=10.9)));
extern
const CFStringRef kCFURLPathKey __attribute__((availability(macosx,introduced=10.8)));
extern
const CFStringRef kCFURLIsMountTriggerKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLGenerationIdentifierKey __attribute__((availability(macosx,introduced=10.10)));
extern
const CFStringRef kCFURLDocumentIdentifierKey __attribute__((availability(macosx,introduced=10.10)));
extern
const CFStringRef kCFURLAddedToDirectoryDateKey __attribute__((availability(macosx,introduced=10.10)));
extern
const CFStringRef kCFURLQuarantinePropertiesKey __attribute__((availability(macosx,introduced=10.10)));
extern
const CFStringRef kCFURLFileResourceTypeKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLFileResourceTypeNamedPipe __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLFileResourceTypeCharacterSpecial __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLFileResourceTypeDirectory __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLFileResourceTypeBlockSpecial __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLFileResourceTypeRegular __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLFileResourceTypeSymbolicLink __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLFileResourceTypeSocket __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLFileResourceTypeUnknown __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLFileSizeKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLFileAllocatedSizeKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLTotalFileSizeKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLTotalFileAllocatedSizeKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLIsAliasFileKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeLocalizedFormatDescriptionKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeTotalCapacityKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeAvailableCapacityKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeResourceCountKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeSupportsPersistentIDsKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeSupportsSymbolicLinksKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeSupportsHardLinksKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeSupportsJournalingKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeIsJournalingKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeSupportsSparseFilesKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeSupportsZeroRunsKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeSupportsCaseSensitiveNamesKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeSupportsCasePreservedNamesKey __attribute__((availability(macosx,introduced=10.6)));
extern
const CFStringRef kCFURLVolumeSupportsRootDirectoryDatesKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeSupportsVolumeSizesKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeSupportsRenamingKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeSupportsAdvisoryFileLockingKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeSupportsExtendedSecurityKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeIsBrowsableKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeMaximumFileSizeKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeIsEjectableKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeIsRemovableKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeIsInternalKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeIsAutomountedKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeIsLocalKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeIsReadOnlyKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeCreationDateKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeURLForRemountingKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeUUIDStringKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeNameKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLVolumeLocalizedNameKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLIsUbiquitousItemKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLUbiquitousItemHasUnresolvedConflictsKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLUbiquitousItemIsDownloadedKey __attribute__((availability(macosx,introduced=10.7 ,deprecated=10.9,message="" "Use kCFURLUbiquitousItemDownloadingStatusKey instead")));
extern
const CFStringRef kCFURLUbiquitousItemIsDownloadingKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLUbiquitousItemIsUploadedKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLUbiquitousItemIsUploadingKey __attribute__((availability(macosx,introduced=10.7)));
extern
const CFStringRef kCFURLUbiquitousItemPercentDownloadedKey __attribute__((availability(macosx,introduced=10.7 ,deprecated=10.8,message="" "Use NSMetadataQuery and NSMetadataUbiquitousItemPercentDownloadedKey on NSMetadataItem instead")));
extern
const CFStringRef kCFURLUbiquitousItemPercentUploadedKey __attribute__((availability(macosx,introduced=10.7 ,deprecated=10.8,message="" "Use NSMetadataQuery and NSMetadataUbiquitousItemPercentUploadedKey on NSMetadataItem instead")));
extern
const CFStringRef kCFURLUbiquitousItemDownloadingStatusKey __attribute__((availability(macosx,introduced=10.9)));
extern
const CFStringRef kCFURLUbiquitousItemDownloadingErrorKey __attribute__((availability(macosx,introduced=10.9)));
extern
const CFStringRef kCFURLUbiquitousItemUploadingErrorKey __attribute__((availability(macosx,introduced=10.9)));
extern
const CFStringRef kCFURLUbiquitousItemDownloadingStatusNotDownloaded __attribute__((availability(macosx,introduced=10.9)));
extern
const CFStringRef kCFURLUbiquitousItemDownloadingStatusDownloaded __attribute__((availability(macosx,introduced=10.9)));
extern
const CFStringRef kCFURLUbiquitousItemDownloadingStatusCurrent __attribute__((availability(macosx,introduced=10.9)));
typedef CFOptionFlags CFURLBookmarkCreationOptions; enum {
kCFURLBookmarkCreationMinimalBookmarkMask = ( 1UL << 9 ),
kCFURLBookmarkCreationSuitableForBookmarkFile = ( 1UL << 10 ),
kCFURLBookmarkCreationWithSecurityScope __attribute__((availability(macosx,introduced=10.7))) = ( 1UL << 11 ),
kCFURLBookmarkCreationSecurityScopeAllowOnlyReadAccess __attribute__((availability(macosx,introduced=10.7))) = ( 1UL << 12 ),
kCFURLBookmarkCreationPreferFileIDResolutionMask __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.9,message="" "kCFURLBookmarkCreationPreferFileIDResolutionMask does nothing and has no effect on bookmark resolution"))) = ( 1UL << 8 ),
} __attribute__((availability(macosx,introduced=10.6)));
typedef CFOptionFlags CFURLBookmarkResolutionOptions; enum {
kCFURLBookmarkResolutionWithoutUIMask = ( 1UL << 8 ),
kCFURLBookmarkResolutionWithoutMountingMask = ( 1UL << 9 ),
kCFURLBookmarkResolutionWithSecurityScope __attribute__((availability(macosx,introduced=10.7))) = ( 1UL << 10 ),
kCFBookmarkResolutionWithoutUIMask = kCFURLBookmarkResolutionWithoutUIMask,
kCFBookmarkResolutionWithoutMountingMask = kCFURLBookmarkResolutionWithoutMountingMask,
} __attribute__((availability(macosx,introduced=10.6)));
typedef CFOptionFlags CFURLBookmarkFileCreationOptions;
extern
CFDataRef CFURLCreateBookmarkData ( CFAllocatorRef allocator, CFURLRef url, CFURLBookmarkCreationOptions options, CFArrayRef resourcePropertiesToInclude, CFURLRef relativeToURL, CFErrorRef* error ) __attribute__((availability(macosx,introduced=10.6)));
extern
CFURLRef CFURLCreateByResolvingBookmarkData ( CFAllocatorRef allocator, CFDataRef bookmark, CFURLBookmarkResolutionOptions options, CFURLRef relativeToURL, CFArrayRef resourcePropertiesToInclude, Boolean* isStale, CFErrorRef* error ) __attribute__((availability(macosx,introduced=10.6)));
extern
CFDictionaryRef CFURLCreateResourcePropertiesForKeysFromBookmarkData ( CFAllocatorRef allocator, CFArrayRef resourcePropertiesToReturn, CFDataRef bookmark ) __attribute__((availability(macosx,introduced=10.6)));
extern
CFTypeRef CFURLCreateResourcePropertyForKeyFromBookmarkData( CFAllocatorRef allocator, CFStringRef resourcePropertyKey, CFDataRef bookmark ) __attribute__((availability(macosx,introduced=10.6)));
extern
CFDataRef CFURLCreateBookmarkDataFromFile(CFAllocatorRef allocator, CFURLRef fileURL, CFErrorRef *errorRef ) __attribute__((availability(macosx,introduced=10.6)));
extern
Boolean CFURLWriteBookmarkDataToFile( CFDataRef bookmarkRef, CFURLRef fileURL, CFURLBookmarkFileCreationOptions options, CFErrorRef *errorRef ) __attribute__((availability(macosx,introduced=10.6)));
extern
CFDataRef CFURLCreateBookmarkDataFromAliasRecord ( CFAllocatorRef allocatorRef, CFDataRef aliasRecordDataRef ) __attribute__((availability(macosx,introduced=10.6)));
extern
Boolean CFURLStartAccessingSecurityScopedResource(CFURLRef url) __attribute__((availability(macosx,introduced=10.7)));
extern
void CFURLStopAccessingSecurityScopedResource(CFURLRef url) __attribute__((availability(macosx,introduced=10.7)));
}
typedef unsigned int boolean_t;
typedef __darwin_natural_t natural_t;
typedef int integer_t;
typedef uintptr_t vm_offset_t;
typedef uintptr_t vm_size_t;
typedef uint64_t mach_vm_address_t;
typedef uint64_t mach_vm_offset_t;
typedef uint64_t mach_vm_size_t;
typedef uint64_t vm_map_offset_t;
typedef uint64_t vm_map_address_t;
typedef uint64_t vm_map_size_t;
typedef mach_vm_address_t mach_port_context_t;
typedef natural_t mach_port_name_t;
typedef mach_port_name_t *mach_port_name_array_t;
typedef __darwin_mach_port_t mach_port_t;
typedef mach_port_t *mach_port_array_t;
typedef natural_t mach_port_right_t;
typedef natural_t mach_port_type_t;
typedef mach_port_type_t *mach_port_type_array_t;
typedef natural_t mach_port_urefs_t;
typedef integer_t mach_port_delta_t;
typedef natural_t mach_port_seqno_t;
typedef natural_t mach_port_mscount_t;
typedef natural_t mach_port_msgcount_t;
typedef natural_t mach_port_rights_t;
typedef unsigned int mach_port_srights_t;
typedef struct mach_port_status {
mach_port_rights_t mps_pset;
mach_port_seqno_t mps_seqno;
mach_port_mscount_t mps_mscount;
mach_port_msgcount_t mps_qlimit;
mach_port_msgcount_t mps_msgcount;
mach_port_rights_t mps_sorights;
boolean_t mps_srights;
boolean_t mps_pdrequest;
boolean_t mps_nsrequest;
natural_t mps_flags;
} mach_port_status_t;
typedef struct mach_port_limits {
mach_port_msgcount_t mpl_qlimit;
} mach_port_limits_t;
typedef struct mach_port_info_ext {
mach_port_status_t mpie_status;
mach_port_msgcount_t mpie_boost_cnt;
uint32_t reserved[6];
} mach_port_info_ext_t;
typedef integer_t *mach_port_info_t;
typedef int mach_port_flavor_t;
typedef struct mach_port_qos {
unsigned int name:1;
unsigned int prealloc:1;
boolean_t pad1:30;
natural_t len;
} mach_port_qos_t;
typedef struct mach_port_options {
uint32_t flags;
mach_port_limits_t mpl;
uint64_t reserved[2];
}mach_port_options_t;
typedef mach_port_options_t *mach_port_options_ptr_t;
enum mach_port_guard_exception_codes {
kGUARD_EXC_DESTROY = 1u << 0,
kGUARD_EXC_MOD_REFS = 1u << 1,
kGUARD_EXC_SET_CONTEXT = 1u << 2,
kGUARD_EXC_UNGUARDED = 1u << 3,
kGUARD_EXC_INCORRECT_GUARD = 1u << 4
};
extern "C" {
typedef struct __CFRunLoop * CFRunLoopRef;
typedef struct __CFRunLoopSource * CFRunLoopSourceRef;
typedef struct __CFRunLoopObserver * CFRunLoopObserverRef;
typedef struct __attribute__((objc_bridge_mutable(NSTimer))) __CFRunLoopTimer * CFRunLoopTimerRef;
enum {
kCFRunLoopRunFinished = 1,
kCFRunLoopRunStopped = 2,
kCFRunLoopRunTimedOut = 3,
kCFRunLoopRunHandledSource = 4
};
typedef CFOptionFlags CFRunLoopActivity; enum {
kCFRunLoopEntry = (1UL << 0),
kCFRunLoopBeforeTimers = (1UL << 1),
kCFRunLoopBeforeSources = (1UL << 2),
kCFRunLoopBeforeWaiting = (1UL << 5),
kCFRunLoopAfterWaiting = (1UL << 6),
kCFRunLoopExit = (1UL << 7),
kCFRunLoopAllActivities = 0x0FFFFFFFU
};
extern const CFStringRef kCFRunLoopDefaultMode;
extern const CFStringRef kCFRunLoopCommonModes;
extern CFTypeID CFRunLoopGetTypeID(void);
extern CFRunLoopRef CFRunLoopGetCurrent(void);
extern CFRunLoopRef CFRunLoopGetMain(void);
extern CFStringRef CFRunLoopCopyCurrentMode(CFRunLoopRef rl);
extern CFArrayRef CFRunLoopCopyAllModes(CFRunLoopRef rl);
extern void CFRunLoopAddCommonMode(CFRunLoopRef rl, CFStringRef mode);
extern CFAbsoluteTime CFRunLoopGetNextTimerFireDate(CFRunLoopRef rl, CFStringRef mode);
extern void CFRunLoopRun(void);
extern SInt32 CFRunLoopRunInMode(CFStringRef mode, CFTimeInterval seconds, Boolean returnAfterSourceHandled);
extern Boolean CFRunLoopIsWaiting(CFRunLoopRef rl);
extern void CFRunLoopWakeUp(CFRunLoopRef rl);
extern void CFRunLoopStop(CFRunLoopRef rl);
extern void CFRunLoopPerformBlock(CFRunLoopRef rl, CFTypeRef mode, void (*block)(void)) __attribute__((availability(macosx,introduced=10.6)));
extern Boolean CFRunLoopContainsSource(CFRunLoopRef rl, CFRunLoopSourceRef source, CFStringRef mode);
extern void CFRunLoopAddSource(CFRunLoopRef rl, CFRunLoopSourceRef source, CFStringRef mode);
extern void CFRunLoopRemoveSource(CFRunLoopRef rl, CFRunLoopSourceRef source, CFStringRef mode);
extern Boolean CFRunLoopContainsObserver(CFRunLoopRef rl, CFRunLoopObserverRef observer, CFStringRef mode);
extern void CFRunLoopAddObserver(CFRunLoopRef rl, CFRunLoopObserverRef observer, CFStringRef mode);
extern void CFRunLoopRemoveObserver(CFRunLoopRef rl, CFRunLoopObserverRef observer, CFStringRef mode);
extern Boolean CFRunLoopContainsTimer(CFRunLoopRef rl, CFRunLoopTimerRef timer, CFStringRef mode);
extern void CFRunLoopAddTimer(CFRunLoopRef rl, CFRunLoopTimerRef timer, CFStringRef mode);
extern void CFRunLoopRemoveTimer(CFRunLoopRef rl, CFRunLoopTimerRef timer, CFStringRef mode);
typedef struct {
CFIndex version;
void * info;
const void *(*retain)(const void *info);
void (*release)(const void *info);
CFStringRef (*copyDescription)(const void *info);
Boolean (*equal)(const void *info1, const void *info2);
CFHashCode (*hash)(const void *info);
void (*schedule)(void *info, CFRunLoopRef rl, CFStringRef mode);
void (*cancel)(void *info, CFRunLoopRef rl, CFStringRef mode);
void (*perform)(void *info);
} CFRunLoopSourceContext;
typedef struct {
CFIndex version;
void * info;
const void *(*retain)(const void *info);
void (*release)(const void *info);
CFStringRef (*copyDescription)(const void *info);
Boolean (*equal)(const void *info1, const void *info2);
CFHashCode (*hash)(const void *info);
mach_port_t (*getPort)(void *info);
void * (*perform)(void *msg, CFIndex size, CFAllocatorRef allocator, void *info);
} CFRunLoopSourceContext1;
extern CFTypeID CFRunLoopSourceGetTypeID(void);
extern CFRunLoopSourceRef CFRunLoopSourceCreate(CFAllocatorRef allocator, CFIndex order, CFRunLoopSourceContext *context);
extern CFIndex CFRunLoopSourceGetOrder(CFRunLoopSourceRef source);
extern void CFRunLoopSourceInvalidate(CFRunLoopSourceRef source);
extern Boolean CFRunLoopSourceIsValid(CFRunLoopSourceRef source);
extern void CFRunLoopSourceGetContext(CFRunLoopSourceRef source, CFRunLoopSourceContext *context);
extern void CFRunLoopSourceSignal(CFRunLoopSourceRef source);
typedef struct {
CFIndex version;
void * info;
const void *(*retain)(const void *info);
void (*release)(const void *info);
CFStringRef (*copyDescription)(const void *info);
} CFRunLoopObserverContext;
typedef void (*CFRunLoopObserverCallBack)(CFRunLoopObserverRef observer, CFRunLoopActivity activity, void *info);
extern CFTypeID CFRunLoopObserverGetTypeID(void);
extern CFRunLoopObserverRef CFRunLoopObserverCreate(CFAllocatorRef allocator, CFOptionFlags activities, Boolean repeats, CFIndex order, CFRunLoopObserverCallBack callout, CFRunLoopObserverContext *context);
extern CFRunLoopObserverRef CFRunLoopObserverCreateWithHandler(CFAllocatorRef allocator, CFOptionFlags activities, Boolean repeats, CFIndex order, void (*block) (CFRunLoopObserverRef observer, CFRunLoopActivity activity)) __attribute__((availability(macosx,introduced=10.7)));
extern CFOptionFlags CFRunLoopObserverGetActivities(CFRunLoopObserverRef observer);
extern Boolean CFRunLoopObserverDoesRepeat(CFRunLoopObserverRef observer);
extern CFIndex CFRunLoopObserverGetOrder(CFRunLoopObserverRef observer);
extern void CFRunLoopObserverInvalidate(CFRunLoopObserverRef observer);
extern Boolean CFRunLoopObserverIsValid(CFRunLoopObserverRef observer);
extern void CFRunLoopObserverGetContext(CFRunLoopObserverRef observer, CFRunLoopObserverContext *context);
typedef struct {
CFIndex version;
void * info;
const void *(*retain)(const void *info);
void (*release)(const void *info);
CFStringRef (*copyDescription)(const void *info);
} CFRunLoopTimerContext;
typedef void (*CFRunLoopTimerCallBack)(CFRunLoopTimerRef timer, void *info);
extern CFTypeID CFRunLoopTimerGetTypeID(void);
extern CFRunLoopTimerRef CFRunLoopTimerCreate(CFAllocatorRef allocator, CFAbsoluteTime fireDate, CFTimeInterval interval, CFOptionFlags flags, CFIndex order, CFRunLoopTimerCallBack callout, CFRunLoopTimerContext *context);
extern CFRunLoopTimerRef CFRunLoopTimerCreateWithHandler(CFAllocatorRef allocator, CFAbsoluteTime fireDate, CFTimeInterval interval, CFOptionFlags flags, CFIndex order, void (*block) (CFRunLoopTimerRef timer)) __attribute__((availability(macosx,introduced=10.7)));
extern CFAbsoluteTime CFRunLoopTimerGetNextFireDate(CFRunLoopTimerRef timer);
extern void CFRunLoopTimerSetNextFireDate(CFRunLoopTimerRef timer, CFAbsoluteTime fireDate);
extern CFTimeInterval CFRunLoopTimerGetInterval(CFRunLoopTimerRef timer);
extern Boolean CFRunLoopTimerDoesRepeat(CFRunLoopTimerRef timer);
extern CFIndex CFRunLoopTimerGetOrder(CFRunLoopTimerRef timer);
extern void CFRunLoopTimerInvalidate(CFRunLoopTimerRef timer);
extern Boolean CFRunLoopTimerIsValid(CFRunLoopTimerRef timer);
extern void CFRunLoopTimerGetContext(CFRunLoopTimerRef timer, CFRunLoopTimerContext *context);
extern CFTimeInterval CFRunLoopTimerGetTolerance(CFRunLoopTimerRef timer) __attribute__((availability(macosx,introduced=10.9)));
extern void CFRunLoopTimerSetTolerance(CFRunLoopTimerRef timer, CFTimeInterval tolerance) __attribute__((availability(macosx,introduced=10.9)));
}
extern "C" {
typedef struct __CFSocket * CFSocketRef;
typedef CFIndex CFSocketError; enum {
kCFSocketSuccess = 0,
kCFSocketError = -1L,
kCFSocketTimeout = -2L
};
typedef struct {
SInt32 protocolFamily;
SInt32 socketType;
SInt32 protocol;
CFDataRef address;
} CFSocketSignature;
typedef CFOptionFlags CFSocketCallBackType; enum {
kCFSocketNoCallBack = 0,
kCFSocketReadCallBack = 1,
kCFSocketAcceptCallBack = 2,
kCFSocketDataCallBack = 3,
kCFSocketConnectCallBack = 4,
kCFSocketWriteCallBack = 8
};
enum {
kCFSocketAutomaticallyReenableReadCallBack = 1,
kCFSocketAutomaticallyReenableAcceptCallBack = 2,
kCFSocketAutomaticallyReenableDataCallBack = 3,
kCFSocketAutomaticallyReenableWriteCallBack = 8,
kCFSocketLeaveErrors __attribute__((availability(macosx,introduced=10.5))) = 64,
kCFSocketCloseOnInvalidate = 128
};
typedef void (*CFSocketCallBack)(CFSocketRef s, CFSocketCallBackType type, CFDataRef address, const void *data, void *info);
typedef struct {
CFIndex version;
void * info;
const void *(*retain)(const void *info);
void (*release)(const void *info);
CFStringRef (*copyDescription)(const void *info);
} CFSocketContext;
typedef int CFSocketNativeHandle;
extern CFTypeID CFSocketGetTypeID(void);
extern CFSocketRef CFSocketCreate(CFAllocatorRef allocator, SInt32 protocolFamily, SInt32 socketType, SInt32 protocol, CFOptionFlags callBackTypes, CFSocketCallBack callout, const CFSocketContext *context);
extern CFSocketRef CFSocketCreateWithNative(CFAllocatorRef allocator, CFSocketNativeHandle sock, CFOptionFlags callBackTypes, CFSocketCallBack callout, const CFSocketContext *context);
extern CFSocketRef CFSocketCreateWithSocketSignature(CFAllocatorRef allocator, const CFSocketSignature *signature, CFOptionFlags callBackTypes, CFSocketCallBack callout, const CFSocketContext *context);
extern CFSocketRef CFSocketCreateConnectedToSocketSignature(CFAllocatorRef allocator, const CFSocketSignature *signature, CFOptionFlags callBackTypes, CFSocketCallBack callout, const CFSocketContext *context, CFTimeInterval timeout);
extern CFSocketError CFSocketSetAddress(CFSocketRef s, CFDataRef address);
extern CFSocketError CFSocketConnectToAddress(CFSocketRef s, CFDataRef address, CFTimeInterval timeout);
extern void CFSocketInvalidate(CFSocketRef s);
extern Boolean CFSocketIsValid(CFSocketRef s);
extern CFDataRef CFSocketCopyAddress(CFSocketRef s);
extern CFDataRef CFSocketCopyPeerAddress(CFSocketRef s);
extern void CFSocketGetContext(CFSocketRef s, CFSocketContext *context);
extern CFSocketNativeHandle CFSocketGetNative(CFSocketRef s);
extern CFRunLoopSourceRef CFSocketCreateRunLoopSource(CFAllocatorRef allocator, CFSocketRef s, CFIndex order);
extern CFOptionFlags CFSocketGetSocketFlags(CFSocketRef s);
extern void CFSocketSetSocketFlags(CFSocketRef s, CFOptionFlags flags);
extern void CFSocketDisableCallBacks(CFSocketRef s, CFOptionFlags callBackTypes);
extern void CFSocketEnableCallBacks(CFSocketRef s, CFOptionFlags callBackTypes);
extern CFSocketError CFSocketSendData(CFSocketRef s, CFDataRef address, CFDataRef data, CFTimeInterval timeout);
extern CFSocketError CFSocketRegisterValue(const CFSocketSignature *nameServerSignature, CFTimeInterval timeout, CFStringRef name, CFPropertyListRef value);
extern CFSocketError CFSocketCopyRegisteredValue(const CFSocketSignature *nameServerSignature, CFTimeInterval timeout, CFStringRef name, CFPropertyListRef *value, CFDataRef *nameServerAddress);
extern CFSocketError CFSocketRegisterSocketSignature(const CFSocketSignature *nameServerSignature, CFTimeInterval timeout, CFStringRef name, const CFSocketSignature *signature);
extern CFSocketError CFSocketCopyRegisteredSocketSignature(const CFSocketSignature *nameServerSignature, CFTimeInterval timeout, CFStringRef name, CFSocketSignature *signature, CFDataRef *nameServerAddress);
extern CFSocketError CFSocketUnregister(const CFSocketSignature *nameServerSignature, CFTimeInterval timeout, CFStringRef name);
extern void CFSocketSetDefaultNameRegistryPortNumber(UInt16 port);
extern UInt16 CFSocketGetDefaultNameRegistryPortNumber(void);
extern const CFStringRef kCFSocketCommandKey;
extern const CFStringRef kCFSocketNameKey;
extern const CFStringRef kCFSocketValueKey;
extern const CFStringRef kCFSocketResultKey;
extern const CFStringRef kCFSocketErrorKey;
extern const CFStringRef kCFSocketRegisterCommand;
extern const CFStringRef kCFSocketRetrieveCommand;
}
struct accessx_descriptor {
unsigned int ad_name_offset;
int ad_flags;
int ad_pad[2];
};
extern "C" {
int getattrlistbulk(int, void *, void *, size_t, uint64_t) __attribute__((availability(macosx,introduced=10.10)));
}
extern "C" {
int faccessat(int, const char *, int, int) __attribute__((availability(macosx,introduced=10.10)));
int fchownat(int, const char *, uid_t, gid_t, int) __attribute__((availability(macosx,introduced=10.10)));
int linkat(int, const char *, int, const char *, int) __attribute__((availability(macosx,introduced=10.10)));
ssize_t readlinkat(int, const char *, char *, size_t) __attribute__((availability(macosx,introduced=10.10)));
int symlinkat(const char *, int, const char *) __attribute__((availability(macosx,introduced=10.10)));
int unlinkat(int, const char *, int) __attribute__((availability(macosx,introduced=10.10)));
int getattrlistat(int, const char *, void *, void *, size_t, unsigned long) __attribute__((availability(macosx,introduced=10.10)));
}
extern "C" {
void _exit(int) __attribute__((noreturn));
int access(const char *, int);
unsigned int
alarm(unsigned int);
int chdir(const char *);
int chown(const char *, uid_t, gid_t);
int close(int) __asm("_" "close" );
int dup(int);
int dup2(int, int);
int execl(const char *, const char *, ...);
int execle(const char *, const char *, ...);
int execlp(const char *, const char *, ...);
int execv(const char *, char * const *);
int execve(const char *, char * const *, char * const *);
int execvp(const char *, char * const *);
pid_t fork(void);
long fpathconf(int, int);
char *getcwd(char *, size_t);
gid_t getegid(void);
uid_t geteuid(void);
gid_t getgid(void);
int getgroups(int, gid_t []);
char *getlogin(void);
pid_t getpgrp(void);
pid_t getpid(void);
pid_t getppid(void);
uid_t getuid(void);
int isatty(int);
int link(const char *, const char *);
off_t lseek(int, off_t, int);
long pathconf(const char *, int);
int pause(void) __asm("_" "pause" );
int pipe(int [2]);
ssize_t read(int, void *, size_t) __asm("_" "read" );
int rmdir(const char *);
int setgid(gid_t);
int setpgid(pid_t, pid_t);
pid_t setsid(void);
int setuid(uid_t);
unsigned int
sleep(unsigned int) __asm("_" "sleep" );
long sysconf(int);
pid_t tcgetpgrp(int);
int tcsetpgrp(int, pid_t);
char *ttyname(int);
int ttyname_r(int, char *, size_t) __asm("_" "ttyname_r" );
int unlink(const char *);
ssize_t write(int, const void *, size_t) __asm("_" "write" );
}
extern "C" {
size_t confstr(int, char *, size_t) __asm("_" "confstr" );
int getopt(int, char * const [], const char *) __asm("_" "getopt" );
extern char *optarg;
extern int optind, opterr, optopt;
}
extern "C" {
__attribute__((deprecated))
void *brk(const void *);
int chroot(const char *) ;
char *crypt(const char *, const char *);
void encrypt(char *, int) __asm("_" "encrypt" );
int fchdir(int);
long gethostid(void);
pid_t getpgid(pid_t);
pid_t getsid(pid_t);
int getdtablesize(void) ;
int getpagesize(void) __attribute__((const)) ;
char *getpass(const char *) ;
char *getwd(char *) ;
int lchown(const char *, uid_t, gid_t) __asm("_" "lchown" );
int lockf(int, int, off_t) __asm("_" "lockf" );
int nice(int) __asm("_" "nice" );
ssize_t pread(int, void *, size_t, off_t) __asm("_" "pread" );
ssize_t pwrite(int, const void *, size_t, off_t) __asm("_" "pwrite" );
__attribute__((deprecated))
void *sbrk(int);
pid_t setpgrp(void) __asm("_" "setpgrp" );
int setregid(gid_t, gid_t) __asm("_" "setregid" );
int setreuid(uid_t, uid_t) __asm("_" "setreuid" );
void swab(const void * , void * , ssize_t);
void sync(void);
int truncate(const char *, off_t);
useconds_t ualarm(useconds_t, useconds_t);
int usleep(useconds_t) __asm("_" "usleep" );
pid_t vfork(void);
int fsync(int) __asm("_" "fsync" );
int ftruncate(int, off_t);
int getlogin_r(char *, size_t);
}
extern "C" {
int fchown(int, uid_t, gid_t);
int gethostname(char *, size_t);
ssize_t readlink(const char * , char * , size_t);
int setegid(gid_t);
int seteuid(uid_t);
int symlink(const char *, const char *);
}
extern "C" {
int pselect(int, fd_set * , fd_set * ,
fd_set * , const struct timespec * ,
const sigset_t * )
__asm("_" "pselect" "$1050")
;
int select(int, fd_set * , fd_set * ,
fd_set * , struct timeval * )
__asm("_" "select" "$1050")
;
}
typedef __darwin_uuid_t uuid_t;
extern "C" {
void _Exit(int) __attribute__((noreturn));
int accessx_np(const struct accessx_descriptor *, size_t, int *, uid_t);
int acct(const char *);
int add_profil(char *, size_t, unsigned long, unsigned int);
void endusershell(void);
int execvP(const char *, const char *, char * const *);
char *fflagstostr(unsigned long);
int getdomainname(char *, int);
int getgrouplist(const char *, int, int *, int *);
int gethostuuid(uuid_t, const struct timespec *) __attribute__((availability(macosx,introduced=10.5)));
mode_t getmode(const void *, mode_t);
int getpeereid(int, uid_t *, gid_t *);
int getsgroups_np(int *, uuid_t);
char *getusershell(void);
int getwgroups_np(int *, uuid_t);
int initgroups(const char *, int);
int iruserok(unsigned long, int, const char *, const char *);
int iruserok_sa(const void *, int, int, const char *, const char *);
int issetugid(void);
char *mkdtemp(char *);
int mknod(const char *, mode_t, dev_t);
int mkpath_np(const char *path, mode_t omode) __attribute__((availability(macosx,introduced=10.8)));
int mkstemp(char *);
int mkstemps(char *, int);
char *mktemp(char *);
int nfssvc(int, void *);
int profil(char *, size_t, unsigned long, unsigned int);
int pthread_setugid_np(uid_t, gid_t);
int pthread_getugid_np( uid_t *, gid_t *);
int rcmd(char **, int, const char *, const char *, const char *, int *);
int rcmd_af(char **, int, const char *, const char *, const char *, int *,
int);
int reboot(int);
int revoke(const char *);
int rresvport(int *);
int rresvport_af(int *, int);
int ruserok(const char *, int, const char *, const char *);
int setdomainname(const char *, int);
int setgroups(int, const gid_t *);
void sethostid(long);
int sethostname(const char *, int);
void setkey(const char *) __asm("_" "setkey" );
int setlogin(const char *);
void *setmode(const char *) __asm("_" "setmode" );
int setrgid(gid_t);
int setruid(uid_t);
int setsgroups_np(int, const uuid_t);
void setusershell(void);
int setwgroups_np(int, const uuid_t);
int strtofflags(char **, unsigned long *, unsigned long *);
int swapon(const char *);
int syscall(int, ...);
int ttyslot(void);
int undelete(const char *);
int unwhiteout(const char *);
void *valloc(size_t);
extern char *suboptarg;
int getsubopt(char **, char * const *, char **);
int fgetattrlist(int,void*,void*,size_t,unsigned int) __attribute__((availability(macosx,introduced=10.6)));
int fsetattrlist(int,void*,void*,size_t,unsigned int) __attribute__((availability(macosx,introduced=10.6)));
int getattrlist(const char*,void*,void*,size_t,unsigned int) __asm("_" "getattrlist" );
int setattrlist(const char*,void*,void*,size_t,unsigned int) __asm("_" "setattrlist" );
int exchangedata(const char*,const char*,unsigned int);
int getdirentriesattr(int,void*,void*,size_t,unsigned int*,unsigned int*,unsigned int*,unsigned int);
struct fssearchblock;
struct searchstate;
int searchfs(const char *, struct fssearchblock *, unsigned long *, unsigned int, unsigned int, struct searchstate *);
int fsctl(const char *,unsigned long,void*,unsigned int);
int ffsctl(int,unsigned long,void*,unsigned int) __attribute__((availability(macosx,introduced=10.6)));
int fsync_volume_np(int, int) __attribute__((availability(macosx,introduced=10.8)));
int sync_volume_np(const char *, int) __attribute__((availability(macosx,introduced=10.8)));
extern int optreset;
}
struct flock {
off_t l_start;
off_t l_len;
pid_t l_pid;
short l_type;
short l_whence;
};
struct flocktimeout {
struct flock fl;
struct timespec timeout;
};
struct radvisory {
off_t ra_offset;
int ra_count;
};
typedef struct fcodeblobs {
void *f_cd_hash;
size_t f_hash_size;
void *f_cd_buffer;
size_t f_cd_size;
unsigned int *f_out_size;
int f_arch;
int __padding;
} fcodeblobs_t;
typedef struct fsignatures {
off_t fs_file_start;
void *fs_blob_start;
size_t fs_blob_size;
} fsignatures_t;
typedef struct fstore {
unsigned int fst_flags;
int fst_posmode;
off_t fst_offset;
off_t fst_length;
off_t fst_bytesalloc;
} fstore_t;
typedef struct fbootstraptransfer {
off_t fbt_offset;
size_t fbt_length;
void *fbt_buffer;
} fbootstraptransfer_t;
#pragma pack(4)
struct log2phys {
unsigned int l2p_flags;
off_t l2p_contigbytes;
off_t l2p_devoffset;
};
#pragma pack()
struct _filesec;
typedef struct _filesec *filesec_t;
typedef enum {
FILESEC_OWNER = 1,
FILESEC_GROUP = 2,
FILESEC_UUID = 3,
FILESEC_MODE = 4,
FILESEC_ACL = 5,
FILESEC_GRPUUID = 6,
FILESEC_ACL_RAW = 100,
FILESEC_ACL_ALLOCSIZE = 101
} filesec_property_t;
extern "C" {
int open(const char *, int, ...) __asm("_" "open" );
int openat(int, const char *, int, ...) __asm("_" "openat" ) __attribute__((availability(macosx,introduced=10.10)));
int creat(const char *, mode_t) __asm("_" "creat" );
int fcntl(int, int, ...) __asm("_" "fcntl" );
int openx_np(const char *, int, filesec_t);
int open_dprotected_np ( const char *, int, int, int, ...);
int flock(int, int);
filesec_t filesec_init(void);
filesec_t filesec_dup(filesec_t);
void filesec_free(filesec_t);
int filesec_get_property(filesec_t, filesec_property_t, void *);
int filesec_query_property(filesec_t, filesec_property_t, int *);
int filesec_set_property(filesec_t, filesec_property_t, const void *);
int filesec_unset_property(filesec_t, filesec_property_t) __attribute__((availability(macosx,introduced=10.6)));
}
typedef struct objc_class *Class;
struct objc_object {
Class isa __attribute__((deprecated));
};
typedef struct objc_object *id;
typedef struct objc_selector *SEL;
typedef id (*IMP)(id, SEL, ...);
typedef signed char BOOL;
extern "C" __attribute__((visibility("default"))) const char *sel_getName(SEL sel)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" __attribute__((visibility("default"))) SEL sel_registerName(const char *str)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" __attribute__((visibility("default"))) const char *object_getClassName(id obj)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" __attribute__((visibility("default"))) void *object_getIndexedIvars(id obj)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" __attribute__((visibility("default"))) BOOL sel_isMapped(SEL sel)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" __attribute__((visibility("default"))) SEL sel_getUid(const char *str)
__attribute__((availability(macosx,introduced=10.0)));
typedef const void* objc_objectptr_t;
typedef long NSInteger;
typedef unsigned long NSUInteger;
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSMethodSignature
#define _REWRITER_typedef_NSMethodSignature
typedef struct objc_object NSMethodSignature;
typedef struct {} _objc_exc_NSMethodSignature;
#endif
#ifndef _REWRITER_typedef_NSInvocation
#define _REWRITER_typedef_NSInvocation
typedef struct objc_object NSInvocation;
typedef struct {} _objc_exc_NSInvocation;
#endif
// @protocol NSObject
// - (BOOL)isEqual:(id)object;
// @property (readonly) NSUInteger hash;
// @property (readonly) Class superclass;
// - (Class)class;
// - (instancetype)self;
// - (id)performSelector:(SEL)aSelector;
// - (id)performSelector:(SEL)aSelector withObject:(id)object;
// - (id)performSelector:(SEL)aSelector withObject:(id)object1 withObject:(id)object2;
// - (BOOL)isProxy;
// - (BOOL)isKindOfClass:(Class)aClass;
// - (BOOL)isMemberOfClass:(Class)aClass;
// - (BOOL)conformsToProtocol:(Protocol *)aProtocol;
// - (BOOL)respondsToSelector:(SEL)aSelector;
// - (instancetype)retain ;
// - (oneway void)release ;
// - (instancetype)autorelease ;
// - (NSUInteger)retainCount ;
// - (struct _NSZone *)zone ;
// @property (readonly, copy) NSString *description;
/* @optional */
// @property (readonly, copy) NSString *debugDescription;
/* @end */
__attribute__((availability(macosx,introduced=10.0)))
__attribute__((objc_root_class))
extern "C" __attribute__((visibility("default")))
#ifndef _REWRITER_typedef_NSObject
#define _REWRITER_typedef_NSObject
typedef struct objc_object NSObject;
typedef struct {} _objc_exc_NSObject;
#endif
struct NSObject_IMPL {
Class isa;
};
// + (void)load;
// + (void)initialize;
// - (instancetype)init;
// + (instancetype)new;
// + (instancetype)allocWithZone:(struct _NSZone *)zone;
// + (instancetype)alloc;
// - (void)dealloc;
// - (void)finalize;
// - (id)copy;
// - (id)mutableCopy;
// + (id)copyWithZone:(struct _NSZone *)zone ;
// + (id)mutableCopyWithZone:(struct _NSZone *)zone ;
// + (BOOL)instancesRespondToSelector:(SEL)aSelector;
// + (BOOL)conformsToProtocol:(Protocol *)protocol;
// - (IMP)methodForSelector:(SEL)aSelector;
// + (IMP)instanceMethodForSelector:(SEL)aSelector;
// - (void)doesNotRecognizeSelector:(SEL)aSelector;
// - (id)forwardingTargetForSelector:(SEL)aSelector __attribute__((availability(macosx,introduced=10.5)));
// - (void)forwardInvocation:(NSInvocation *)anInvocation;
// - (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector;
// + (NSMethodSignature *)instanceMethodSignatureForSelector:(SEL)aSelector;
// - (BOOL)allowsWeakReference __attribute__((unavailable));
// - (BOOL)retainWeakReference __attribute__((unavailable));
// + (BOOL)isSubclassOfClass:(Class)aClass;
// + (BOOL)resolveClassMethod:(SEL)sel __attribute__((availability(macosx,introduced=10.5)));
// + (BOOL)resolveInstanceMethod:(SEL)sel __attribute__((availability(macosx,introduced=10.5)));
// + (NSUInteger)hash;
// + (Class)superclass;
// + (Class)class;
// + (NSString *)description;
// + (NSString *)debugDescription;
/* @end */
extern "C" {
__attribute__((availability(macosx,introduced=10.10)))
extern __attribute__((__visibility__("default")))
void*
os_retain(void *object);
__attribute__((availability(macosx,introduced=10.10)))
extern __attribute__((__visibility__("default")))
void
os_release(void *object);
}
typedef void (*dispatch_function_t)(void *);
struct time_value {
integer_t seconds;
integer_t microseconds;
};
typedef struct time_value time_value_t;
typedef int alarm_type_t;
typedef int sleep_type_t;
typedef int clock_id_t;
typedef int clock_flavor_t;
typedef int *clock_attr_t;
typedef int clock_res_t;
struct mach_timespec {
unsigned int tv_sec;
clock_res_t tv_nsec;
};
typedef struct mach_timespec mach_timespec_t;
extern "C" {
struct timespec;
typedef uint64_t dispatch_time_t;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_time_t
dispatch_time(dispatch_time_t when, int64_t delta);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_time_t
dispatch_walltime(const struct timespec *when, int64_t delta);
}
// @protocol OS_dispatch_object /* @end */
typedef NSObject/*<OS_dispatch_object>*/ *dispatch_object_t;
static __inline__ __attribute__((__always_inline__)) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
_dispatch_object_validate(dispatch_object_t object) {
void *isa = *(void* volatile*)( void*)object;
(void)isa;
}
typedef void (*dispatch_block_t)(void);
extern "C" {
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_retain(dispatch_object_t object);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_release(dispatch_object_t object);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__pure__)) __attribute__((__warn_unused_result__))
__attribute__((__nothrow__))
void *
dispatch_get_context(dispatch_object_t object);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nothrow__))
void
dispatch_set_context(dispatch_object_t object, void *context);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nothrow__))
void
dispatch_set_finalizer_f(dispatch_object_t object,
dispatch_function_t finalizer);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_suspend(dispatch_object_t object);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_resume(dispatch_object_t object);
__attribute__((__unavailable__))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
long
dispatch_wait(void *object, dispatch_time_t timeout);
__attribute__((__unavailable__))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_notify(void *object, dispatch_object_t queue,
dispatch_block_t notification_block);
__attribute__((__unavailable__))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_cancel(void *object);
__attribute__((__unavailable__))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__warn_unused_result__)) __attribute__((__pure__))
__attribute__((__nothrow__))
long
dispatch_testcancel(void *object);
__attribute__((availability(macosx,introduced=10.6,deprecated=10.9)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(2))) __attribute__((__nothrow__))
__attribute__((__format__(printf,2,3)))
void
dispatch_debug(dispatch_object_t object, const char *message, ...);
__attribute__((availability(macosx,introduced=10.6,deprecated=10.9)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(2))) __attribute__((__nothrow__))
__attribute__((__format__(printf,2,0)))
void
dispatch_debugv(dispatch_object_t object, const char *message, va_list ap);
}
// @protocol OS_dispatch_queue <OS_dispatch_object> /* @end */
typedef NSObject/*<OS_dispatch_queue>*/ *dispatch_queue_t;
extern "C" {
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_async(dispatch_queue_t queue, dispatch_block_t block);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(3))) __attribute__((__nothrow__))
void
dispatch_async_f(dispatch_queue_t queue,
void *context,
dispatch_function_t work);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_sync(dispatch_queue_t queue, dispatch_block_t block);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(3))) __attribute__((__nothrow__))
void
dispatch_sync_f(dispatch_queue_t queue,
void *context,
dispatch_function_t work);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(3))) __attribute__((__nothrow__))
void
dispatch_apply(size_t iterations, dispatch_queue_t queue,
void (*block)(size_t));
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(4))) __attribute__((__nothrow__))
void
dispatch_apply_f(size_t iterations, dispatch_queue_t queue,
void *context,
void (*work)(void *, size_t));
__attribute__((availability(macosx,introduced=10.6,deprecated=10.9)))
extern __attribute__((visibility("default"))) __attribute__((__pure__)) __attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_queue_t
dispatch_get_current_queue(void);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) struct dispatch_queue_s _dispatch_main_q;
static __inline__ __attribute__((__always_inline__)) __attribute__((__const__)) __attribute__((__nothrow__))
dispatch_queue_t
dispatch_get_main_queue(void)
{
return (( dispatch_queue_t)&(_dispatch_main_q));
}
typedef long dispatch_queue_priority_t;
typedef enum : unsigned int { QOS_CLASS_USER_INTERACTIVE __attribute__((availability(macosx,introduced=10.10))) = 0x21, QOS_CLASS_USER_INITIATED __attribute__((availability(macosx,introduced=10.10))) = 0x19, QOS_CLASS_DEFAULT __attribute__((availability(macosx,introduced=10.10))) = 0x15, QOS_CLASS_UTILITY __attribute__((availability(macosx,introduced=10.10))) = 0x11, QOS_CLASS_BACKGROUND __attribute__((availability(macosx,introduced=10.10))) = 0x09, QOS_CLASS_UNSPECIFIED __attribute__((availability(macosx,introduced=10.10))) = 0x00, } qos_class_t;
extern "C" {
__attribute__((availability(macosx,introduced=10.10)))
qos_class_t
qos_class_self(void);
__attribute__((availability(macosx,introduced=10.10)))
qos_class_t
qos_class_main(void);
}
typedef qos_class_t dispatch_qos_class_t;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__const__)) __attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_queue_t
dispatch_get_global_queue(long identifier, unsigned long flags);
// @protocol OS_dispatch_queue_attr <OS_dispatch_object> /* @end */
typedef NSObject/*<OS_dispatch_queue_attr>*/ *dispatch_queue_attr_t;
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default")))
struct dispatch_queue_attr_s _dispatch_queue_attr_concurrent;
__attribute__((availability(macosx,introduced=10.10)))
extern __attribute__((visibility("default"))) __attribute__((__warn_unused_result__)) __attribute__((__pure__)) __attribute__((__nothrow__))
dispatch_queue_attr_t
dispatch_queue_attr_make_with_qos_class(dispatch_queue_attr_t attr,
dispatch_qos_class_t qos_class, int relative_priority);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__malloc__)) __attribute__((__ns_returns_retained__)) __attribute__((__warn_unused_result__))
__attribute__((__nothrow__))
dispatch_queue_t
dispatch_queue_create(const char *label, dispatch_queue_attr_t attr);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__pure__)) __attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
const char *
dispatch_queue_get_label(dispatch_queue_t queue);
__attribute__((availability(macosx,introduced=10.10)))
extern __attribute__((visibility("default"))) __attribute__((__warn_unused_result__)) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
dispatch_qos_class_t
dispatch_queue_get_qos_class(dispatch_queue_t queue,
int *relative_priority_ptr);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nothrow__))
void
dispatch_set_target_queue(dispatch_object_t object, dispatch_queue_t queue);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nothrow__)) __attribute__((__noreturn__))
void
dispatch_main(void);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(2))) __attribute__((__nonnull__(3))) __attribute__((__nothrow__))
void
dispatch_after(dispatch_time_t when,
dispatch_queue_t queue,
dispatch_block_t block);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(2))) __attribute__((__nonnull__(4))) __attribute__((__nothrow__))
void
dispatch_after_f(dispatch_time_t when,
dispatch_queue_t queue,
void *context,
dispatch_function_t work);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_barrier_async(dispatch_queue_t queue, dispatch_block_t block);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(3))) __attribute__((__nothrow__))
void
dispatch_barrier_async_f(dispatch_queue_t queue,
void *context,
dispatch_function_t work);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_barrier_sync(dispatch_queue_t queue, dispatch_block_t block);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(3))) __attribute__((__nothrow__))
void
dispatch_barrier_sync_f(dispatch_queue_t queue,
void *context,
dispatch_function_t work);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(2))) __attribute__((__nothrow__))
void
dispatch_queue_set_specific(dispatch_queue_t queue, const void *key,
void *context, dispatch_function_t destructor);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__pure__)) __attribute__((__warn_unused_result__))
__attribute__((__nothrow__))
void *
dispatch_queue_get_specific(dispatch_queue_t queue, const void *key);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__pure__)) __attribute__((__warn_unused_result__))
__attribute__((__nothrow__))
void *
dispatch_get_specific(const void *key);
}
extern "C" {
typedef enum : unsigned long { DISPATCH_BLOCK_BARRIER __attribute__((availability(macosx,introduced=10.10))) = 0x1, DISPATCH_BLOCK_DETACHED __attribute__((availability(macosx,introduced=10.10))) = 0x2, DISPATCH_BLOCK_ASSIGN_CURRENT __attribute__((availability(macosx,introduced=10.10))) = 0x4, DISPATCH_BLOCK_NO_QOS_CLASS __attribute__((availability(macosx,introduced=10.10))) = 0x8, DISPATCH_BLOCK_INHERIT_QOS_CLASS __attribute__((availability(macosx,introduced=10.10))) = 0x10, DISPATCH_BLOCK_ENFORCE_QOS_CLASS __attribute__((availability(macosx,introduced=10.10))) = 0x20, } dispatch_block_flags_t;
__attribute__((availability(macosx,introduced=10.10)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(2))) __attribute__((__ns_returns_retained__))
__attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_block_t
dispatch_block_create(dispatch_block_flags_t flags, dispatch_block_t block);
__attribute__((availability(macosx,introduced=10.10)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(4))) __attribute__((__ns_returns_retained__))
__attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_block_t
dispatch_block_create_with_qos_class(dispatch_block_flags_t flags,
dispatch_qos_class_t qos_class, int relative_priority,
dispatch_block_t block);
__attribute__((availability(macosx,introduced=10.10)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(2))) __attribute__((__nothrow__))
void
dispatch_block_perform(dispatch_block_flags_t flags, dispatch_block_t block);
__attribute__((availability(macosx,introduced=10.10)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
long
dispatch_block_wait(dispatch_block_t block, dispatch_time_t timeout);
__attribute__((availability(macosx,introduced=10.10)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_block_notify(dispatch_block_t block, dispatch_queue_t queue,
dispatch_block_t notification_block);
__attribute__((availability(macosx,introduced=10.10)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_block_cancel(dispatch_block_t block);
__attribute__((availability(macosx,introduced=10.10)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__warn_unused_result__)) __attribute__((__pure__))
__attribute__((__nothrow__))
long
dispatch_block_testcancel(dispatch_block_t block);
}
typedef int kern_return_t;
typedef natural_t mach_msg_timeout_t;
typedef unsigned int mach_msg_bits_t;
typedef natural_t mach_msg_size_t;
typedef integer_t mach_msg_id_t;
typedef unsigned int mach_msg_type_name_t;
typedef unsigned int mach_msg_copy_options_t;
typedef unsigned int mach_msg_descriptor_type_t;
#pragma pack(4)
typedef struct
{
natural_t pad1;
mach_msg_size_t pad2;
unsigned int pad3 : 24;
mach_msg_descriptor_type_t type : 8;
} mach_msg_type_descriptor_t;
typedef struct
{
mach_port_t name;
mach_msg_size_t pad1;
unsigned int pad2 : 16;
mach_msg_type_name_t disposition : 8;
mach_msg_descriptor_type_t type : 8;
} mach_msg_port_descriptor_t;
typedef struct
{
uint32_t address;
mach_msg_size_t size;
boolean_t deallocate: 8;
mach_msg_copy_options_t copy: 8;
unsigned int pad1: 8;
mach_msg_descriptor_type_t type: 8;
} mach_msg_ool_descriptor32_t;
typedef struct
{
uint64_t address;
boolean_t deallocate: 8;
mach_msg_copy_options_t copy: 8;
unsigned int pad1: 8;
mach_msg_descriptor_type_t type: 8;
mach_msg_size_t size;
} mach_msg_ool_descriptor64_t;
typedef struct
{
void* address;
boolean_t deallocate: 8;
mach_msg_copy_options_t copy: 8;
unsigned int pad1: 8;
mach_msg_descriptor_type_t type: 8;
mach_msg_size_t size;
} mach_msg_ool_descriptor_t;
typedef struct
{
uint32_t address;
mach_msg_size_t count;
boolean_t deallocate: 8;
mach_msg_copy_options_t copy: 8;
mach_msg_type_name_t disposition : 8;
mach_msg_descriptor_type_t type : 8;
} mach_msg_ool_ports_descriptor32_t;
typedef struct
{
uint64_t address;
boolean_t deallocate: 8;
mach_msg_copy_options_t copy: 8;
mach_msg_type_name_t disposition : 8;
mach_msg_descriptor_type_t type : 8;
mach_msg_size_t count;
} mach_msg_ool_ports_descriptor64_t;
typedef struct
{
void* address;
boolean_t deallocate: 8;
mach_msg_copy_options_t copy: 8;
mach_msg_type_name_t disposition : 8;
mach_msg_descriptor_type_t type : 8;
mach_msg_size_t count;
} mach_msg_ool_ports_descriptor_t;
typedef union
{
mach_msg_port_descriptor_t port;
mach_msg_ool_descriptor_t out_of_line;
mach_msg_ool_ports_descriptor_t ool_ports;
mach_msg_type_descriptor_t type;
} mach_msg_descriptor_t;
typedef struct
{
mach_msg_size_t msgh_descriptor_count;
} mach_msg_body_t;
typedef struct
{
mach_msg_bits_t msgh_bits;
mach_msg_size_t msgh_size;
mach_port_t msgh_remote_port;
mach_port_t msgh_local_port;
mach_port_name_t msgh_voucher_port;
mach_msg_id_t msgh_id;
} mach_msg_header_t;
typedef struct
{
mach_msg_header_t header;
mach_msg_body_t body;
} mach_msg_base_t;
typedef unsigned int mach_msg_trailer_type_t;
typedef unsigned int mach_msg_trailer_size_t;
typedef char *mach_msg_trailer_info_t;
typedef struct
{
mach_msg_trailer_type_t msgh_trailer_type;
mach_msg_trailer_size_t msgh_trailer_size;
} mach_msg_trailer_t;
typedef struct
{
mach_msg_trailer_type_t msgh_trailer_type;
mach_msg_trailer_size_t msgh_trailer_size;
mach_port_seqno_t msgh_seqno;
} mach_msg_seqno_trailer_t;
typedef struct
{
unsigned int val[2];
} security_token_t;
typedef struct
{
mach_msg_trailer_type_t msgh_trailer_type;
mach_msg_trailer_size_t msgh_trailer_size;
mach_port_seqno_t msgh_seqno;
security_token_t msgh_sender;
} mach_msg_security_trailer_t;
typedef struct
{
unsigned int val[8];
} audit_token_t;
typedef struct
{
mach_msg_trailer_type_t msgh_trailer_type;
mach_msg_trailer_size_t msgh_trailer_size;
mach_port_seqno_t msgh_seqno;
security_token_t msgh_sender;
audit_token_t msgh_audit;
} mach_msg_audit_trailer_t;
typedef struct
{
mach_msg_trailer_type_t msgh_trailer_type;
mach_msg_trailer_size_t msgh_trailer_size;
mach_port_seqno_t msgh_seqno;
security_token_t msgh_sender;
audit_token_t msgh_audit;
mach_port_context_t msgh_context;
} mach_msg_context_trailer_t;
typedef struct
{
mach_port_name_t sender;
} msg_labels_t;
typedef struct
{
mach_msg_trailer_type_t msgh_trailer_type;
mach_msg_trailer_size_t msgh_trailer_size;
mach_port_seqno_t msgh_seqno;
security_token_t msgh_sender;
audit_token_t msgh_audit;
mach_port_context_t msgh_context;
int msgh_ad;
msg_labels_t msgh_labels;
} mach_msg_mac_trailer_t;
typedef mach_msg_mac_trailer_t mach_msg_max_trailer_t;
typedef mach_msg_security_trailer_t mach_msg_format_0_trailer_t;
extern security_token_t KERNEL_SECURITY_TOKEN;
extern audit_token_t KERNEL_AUDIT_TOKEN;
typedef integer_t mach_msg_options_t;
typedef struct
{
mach_msg_header_t header;
} mach_msg_empty_send_t;
typedef struct
{
mach_msg_header_t header;
mach_msg_trailer_t trailer;
} mach_msg_empty_rcv_t;
typedef union
{
mach_msg_empty_send_t send;
mach_msg_empty_rcv_t rcv;
} mach_msg_empty_t;
#pragma pack()
typedef natural_t mach_msg_type_size_t;
typedef natural_t mach_msg_type_number_t;
typedef integer_t mach_msg_option_t;
typedef kern_return_t mach_msg_return_t;
extern "C" {
extern mach_msg_return_t mach_msg_overwrite(
mach_msg_header_t *msg,
mach_msg_option_t option,
mach_msg_size_t send_size,
mach_msg_size_t rcv_size,
mach_port_name_t rcv_name,
mach_msg_timeout_t timeout,
mach_port_name_t notify,
mach_msg_header_t *rcv_msg,
mach_msg_size_t rcv_limit);
extern mach_msg_return_t mach_msg(
mach_msg_header_t *msg,
mach_msg_option_t option,
mach_msg_size_t send_size,
mach_msg_size_t rcv_size,
mach_port_name_t rcv_name,
mach_msg_timeout_t timeout,
mach_port_name_t notify);
extern kern_return_t mach_voucher_deallocate(
mach_port_name_t voucher);
}
// @protocol OS_dispatch_source <OS_dispatch_object> /* @end */
typedef NSObject/*<OS_dispatch_source>*/ *dispatch_source_t;
typedef const struct dispatch_source_type_s *dispatch_source_type_t;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) const struct dispatch_source_type_s _dispatch_source_type_data_add;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) const struct dispatch_source_type_s _dispatch_source_type_data_or;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) const struct dispatch_source_type_s _dispatch_source_type_mach_send;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) const struct dispatch_source_type_s _dispatch_source_type_mach_recv;
__attribute__((availability(macosx,introduced=10.9)))
extern __attribute__((visibility("default"))) const struct dispatch_source_type_s _dispatch_source_type_memorypressure;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) const struct dispatch_source_type_s _dispatch_source_type_proc;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) const struct dispatch_source_type_s _dispatch_source_type_read;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) const struct dispatch_source_type_s _dispatch_source_type_signal;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) const struct dispatch_source_type_s _dispatch_source_type_timer;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) const struct dispatch_source_type_s _dispatch_source_type_vnode;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) const struct dispatch_source_type_s _dispatch_source_type_write;
typedef unsigned long dispatch_source_mach_send_flags_t;
typedef unsigned long dispatch_source_memorypressure_flags_t;
typedef unsigned long dispatch_source_proc_flags_t;
typedef unsigned long dispatch_source_vnode_flags_t;
typedef unsigned long dispatch_source_timer_flags_t;
extern "C" {
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__malloc__)) __attribute__((__ns_returns_retained__)) __attribute__((__warn_unused_result__))
__attribute__((__nothrow__))
dispatch_source_t
dispatch_source_create(dispatch_source_type_t type,
uintptr_t handle,
unsigned long mask,
dispatch_queue_t queue);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
void
dispatch_source_set_event_handler(dispatch_source_t source,
dispatch_block_t handler);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
void
dispatch_source_set_event_handler_f(dispatch_source_t source,
dispatch_function_t handler);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
void
dispatch_source_set_cancel_handler(dispatch_source_t source,
dispatch_block_t handler);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
void
dispatch_source_set_cancel_handler_f(dispatch_source_t source,
dispatch_function_t handler);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_source_cancel(dispatch_source_t source);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__warn_unused_result__)) __attribute__((__pure__))
__attribute__((__nothrow__))
long
dispatch_source_testcancel(dispatch_source_t source);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__warn_unused_result__)) __attribute__((__pure__))
__attribute__((__nothrow__))
uintptr_t
dispatch_source_get_handle(dispatch_source_t source);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__warn_unused_result__)) __attribute__((__pure__))
__attribute__((__nothrow__))
unsigned long
dispatch_source_get_mask(dispatch_source_t source);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__warn_unused_result__)) __attribute__((__pure__))
__attribute__((__nothrow__))
unsigned long
dispatch_source_get_data(dispatch_source_t source);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_source_merge_data(dispatch_source_t source, unsigned long value);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_source_set_timer(dispatch_source_t source,
dispatch_time_t start,
uint64_t interval,
uint64_t leeway);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
void
dispatch_source_set_registration_handler(dispatch_source_t source,
dispatch_block_t handler);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
void
dispatch_source_set_registration_handler_f(dispatch_source_t source,
dispatch_function_t handler);
}
// @protocol OS_dispatch_group <OS_dispatch_object> /* @end */
typedef NSObject/*<OS_dispatch_group>*/ *dispatch_group_t;
extern "C" {
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__malloc__)) __attribute__((__ns_returns_retained__)) __attribute__((__warn_unused_result__))
__attribute__((__nothrow__))
dispatch_group_t
dispatch_group_create(void);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_group_async(dispatch_group_t group,
dispatch_queue_t queue,
dispatch_block_t block);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(2))) __attribute__((__nonnull__(4)))
__attribute__((__nothrow__))
void
dispatch_group_async_f(dispatch_group_t group,
dispatch_queue_t queue,
void *context,
dispatch_function_t work);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
long
dispatch_group_wait(dispatch_group_t group, dispatch_time_t timeout);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_group_notify(dispatch_group_t group,
dispatch_queue_t queue,
dispatch_block_t block);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(2))) __attribute__((__nonnull__(4)))
__attribute__((__nothrow__))
void
dispatch_group_notify_f(dispatch_group_t group,
dispatch_queue_t queue,
void *context,
dispatch_function_t work);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_group_enter(dispatch_group_t group);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_group_leave(dispatch_group_t group);
}
// @protocol OS_dispatch_semaphore <OS_dispatch_object> /* @end */
typedef NSObject/*<OS_dispatch_semaphore>*/ *dispatch_semaphore_t;
extern "C" {
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__malloc__)) __attribute__((__ns_returns_retained__)) __attribute__((__warn_unused_result__))
__attribute__((__nothrow__))
dispatch_semaphore_t
dispatch_semaphore_create(long value);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
long
dispatch_semaphore_wait(dispatch_semaphore_t dsema, dispatch_time_t timeout);
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
long
dispatch_semaphore_signal(dispatch_semaphore_t dsema);
}
extern "C" {
typedef long dispatch_once_t;
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_once(dispatch_once_t *predicate, dispatch_block_t block);
static __inline__ __attribute__((__always_inline__)) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
_dispatch_once(dispatch_once_t *predicate, dispatch_block_t block)
{
if (__builtin_expect((*predicate), (~0l)) != ~0l) {
dispatch_once(predicate, block);
}
}
__attribute__((availability(macosx,introduced=10.6)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(3))) __attribute__((__nothrow__))
void
dispatch_once_f(dispatch_once_t *predicate, void *context,
dispatch_function_t function);
static __inline__ __attribute__((__always_inline__)) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(3)))
__attribute__((__nothrow__))
void
_dispatch_once_f(dispatch_once_t *predicate, void *context,
dispatch_function_t function)
{
if (__builtin_expect((*predicate), (~0l)) != ~0l) {
dispatch_once_f(predicate, context, function);
}
}
}
extern "C" {
// @protocol OS_dispatch_data <OS_dispatch_object> /* @end */
typedef NSObject/*<OS_dispatch_data>*/ *dispatch_data_t;
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) struct dispatch_data_s _dispatch_data_empty;
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) const dispatch_block_t _dispatch_data_destructor_free;
__attribute__((availability(macosx,introduced=10.9)))
extern __attribute__((visibility("default"))) const dispatch_block_t _dispatch_data_destructor_munmap;
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__ns_returns_retained__)) __attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_data_t
dispatch_data_create(const void *buffer,
size_t size,
dispatch_queue_t queue,
dispatch_block_t destructor);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__pure__)) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
size_t
dispatch_data_get_size(dispatch_data_t data);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__ns_returns_retained__))
__attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_data_t
dispatch_data_create_map(dispatch_data_t data,
const void **buffer_ptr,
size_t *size_ptr);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__ns_returns_retained__))
__attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_data_t
dispatch_data_create_concat(dispatch_data_t data1, dispatch_data_t data2);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__ns_returns_retained__))
__attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_data_t
dispatch_data_create_subrange(dispatch_data_t data,
size_t offset,
size_t length);
typedef bool (*dispatch_data_applier_t)(dispatch_data_t region,
size_t offset,
const void *buffer,
size_t size);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
bool
dispatch_data_apply(dispatch_data_t data, dispatch_data_applier_t applier);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(3))) __attribute__((__ns_returns_retained__))
__attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_data_t
dispatch_data_copy_region(dispatch_data_t data,
size_t location,
size_t *offset_ptr);
}
extern "C" {
typedef int dispatch_fd_t;
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(3))) __attribute__((__nonnull__(4))) __attribute__((__nothrow__))
void
dispatch_read(dispatch_fd_t fd,
size_t length,
dispatch_queue_t queue,
void (*handler)(dispatch_data_t data, int error));
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(2))) __attribute__((__nonnull__(3))) __attribute__((__nonnull__(4)))
__attribute__((__nothrow__))
void
dispatch_write(dispatch_fd_t fd,
dispatch_data_t data,
dispatch_queue_t queue,
void (*handler)(dispatch_data_t data, int error));
// @protocol OS_dispatch_io <OS_dispatch_object> /* @end */
typedef NSObject/*<OS_dispatch_io>*/ *dispatch_io_t;
typedef unsigned long dispatch_io_type_t;
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__malloc__)) __attribute__((__ns_returns_retained__)) __attribute__((__warn_unused_result__))
__attribute__((__nothrow__))
dispatch_io_t
dispatch_io_create(dispatch_io_type_t type,
dispatch_fd_t fd,
dispatch_queue_t queue,
void (*cleanup_handler)(int error));
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(2))) __attribute__((__malloc__)) __attribute__((__ns_returns_retained__))
__attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_io_t
dispatch_io_create_with_path(dispatch_io_type_t type,
const char *path, int oflag, mode_t mode,
dispatch_queue_t queue,
void (*cleanup_handler)(int error));
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(2))) __attribute__((__malloc__)) __attribute__((__ns_returns_retained__))
__attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_io_t
dispatch_io_create_with_io(dispatch_io_type_t type,
dispatch_io_t io,
dispatch_queue_t queue,
void (*cleanup_handler)(int error));
typedef void (*dispatch_io_handler_t)(bool done, dispatch_data_t data,
int error);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(4))) __attribute__((__nonnull__(5)))
__attribute__((__nothrow__))
void
dispatch_io_read(dispatch_io_t channel,
off_t offset,
size_t length,
dispatch_queue_t queue,
dispatch_io_handler_t io_handler);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nonnull__(3))) __attribute__((__nonnull__(4)))
__attribute__((__nonnull__(5))) __attribute__((__nothrow__))
void
dispatch_io_write(dispatch_io_t channel,
off_t offset,
dispatch_data_t data,
dispatch_queue_t queue,
dispatch_io_handler_t io_handler);
typedef unsigned long dispatch_io_close_flags_t;
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
void
dispatch_io_close(dispatch_io_t channel, dispatch_io_close_flags_t flags);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__nothrow__))
void
dispatch_io_barrier(dispatch_io_t channel, dispatch_block_t barrier);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__)) __attribute__((__warn_unused_result__)) __attribute__((__nothrow__))
dispatch_fd_t
dispatch_io_get_descriptor(dispatch_io_t channel);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
void
dispatch_io_set_high_water(dispatch_io_t channel, size_t high_water);
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
void
dispatch_io_set_low_water(dispatch_io_t channel, size_t low_water);
typedef unsigned long dispatch_io_interval_flags_t;
__attribute__((availability(macosx,introduced=10.7)))
extern __attribute__((visibility("default"))) __attribute__((__nonnull__(1))) __attribute__((__nothrow__))
void
dispatch_io_set_interval(dispatch_io_t channel,
uint64_t interval,
dispatch_io_interval_flags_t flags);
}
extern "C" {
typedef CFIndex CFStreamStatus; enum {
kCFStreamStatusNotOpen = 0,
kCFStreamStatusOpening,
kCFStreamStatusOpen,
kCFStreamStatusReading,
kCFStreamStatusWriting,
kCFStreamStatusAtEnd,
kCFStreamStatusClosed,
kCFStreamStatusError
};
typedef CFOptionFlags CFStreamEventType; enum {
kCFStreamEventNone = 0,
kCFStreamEventOpenCompleted = 1,
kCFStreamEventHasBytesAvailable = 2,
kCFStreamEventCanAcceptBytes = 4,
kCFStreamEventErrorOccurred = 8,
kCFStreamEventEndEncountered = 16
};
typedef struct {
CFIndex version;
void *info;
void *(*retain)(void *info);
void (*release)(void *info);
CFStringRef (*copyDescription)(void *info);
} CFStreamClientContext;
typedef struct __attribute__((objc_bridge_mutable(NSInputStream))) __CFReadStream * CFReadStreamRef;
typedef struct __attribute__((objc_bridge_mutable(NSOutputStream))) __CFWriteStream * CFWriteStreamRef;
typedef void (*CFReadStreamClientCallBack)(CFReadStreamRef stream, CFStreamEventType type, void *clientCallBackInfo);
typedef void (*CFWriteStreamClientCallBack)(CFWriteStreamRef stream, CFStreamEventType type, void *clientCallBackInfo);
extern
CFTypeID CFReadStreamGetTypeID(void);
extern
CFTypeID CFWriteStreamGetTypeID(void);
extern
const CFStringRef kCFStreamPropertyDataWritten;
extern
CFReadStreamRef CFReadStreamCreateWithBytesNoCopy(CFAllocatorRef alloc, const UInt8 *bytes, CFIndex length, CFAllocatorRef bytesDeallocator);
extern
CFWriteStreamRef CFWriteStreamCreateWithBuffer(CFAllocatorRef alloc, UInt8 *buffer, CFIndex bufferCapacity);
extern
CFWriteStreamRef CFWriteStreamCreateWithAllocatedBuffers(CFAllocatorRef alloc, CFAllocatorRef bufferAllocator);
extern
CFReadStreamRef CFReadStreamCreateWithFile(CFAllocatorRef alloc, CFURLRef fileURL);
extern
CFWriteStreamRef CFWriteStreamCreateWithFile(CFAllocatorRef alloc, CFURLRef fileURL);
extern
void CFStreamCreateBoundPair(CFAllocatorRef alloc, CFReadStreamRef *readStream, CFWriteStreamRef *writeStream, CFIndex transferBufferSize);
extern
const CFStringRef kCFStreamPropertyAppendToFile;
extern
const CFStringRef kCFStreamPropertyFileCurrentOffset;
extern
const CFStringRef kCFStreamPropertySocketNativeHandle;
extern
const CFStringRef kCFStreamPropertySocketRemoteHostName;
extern
const CFStringRef kCFStreamPropertySocketRemotePortNumber;
extern
void CFStreamCreatePairWithSocket(CFAllocatorRef alloc, CFSocketNativeHandle sock, CFReadStreamRef *readStream, CFWriteStreamRef *writeStream);
extern
void CFStreamCreatePairWithSocketToHost(CFAllocatorRef alloc, CFStringRef host, UInt32 port, CFReadStreamRef *readStream, CFWriteStreamRef *writeStream);
extern
void CFStreamCreatePairWithPeerSocketSignature(CFAllocatorRef alloc, const CFSocketSignature *signature, CFReadStreamRef *readStream, CFWriteStreamRef *writeStream);
extern
CFStreamStatus CFReadStreamGetStatus(CFReadStreamRef stream);
extern
CFStreamStatus CFWriteStreamGetStatus(CFWriteStreamRef stream);
extern
CFErrorRef CFReadStreamCopyError(CFReadStreamRef stream) __attribute__((availability(macosx,introduced=10.5)));
extern
CFErrorRef CFWriteStreamCopyError(CFWriteStreamRef stream) __attribute__((availability(macosx,introduced=10.5)));
extern
Boolean CFReadStreamOpen(CFReadStreamRef stream);
extern
Boolean CFWriteStreamOpen(CFWriteStreamRef stream);
extern
void CFReadStreamClose(CFReadStreamRef stream);
extern
void CFWriteStreamClose(CFWriteStreamRef stream);
extern
Boolean CFReadStreamHasBytesAvailable(CFReadStreamRef stream);
extern
CFIndex CFReadStreamRead(CFReadStreamRef stream, UInt8 *buffer, CFIndex bufferLength);
extern
const UInt8 *CFReadStreamGetBuffer(CFReadStreamRef stream, CFIndex maxBytesToRead, CFIndex *numBytesRead);
extern
Boolean CFWriteStreamCanAcceptBytes(CFWriteStreamRef stream);
extern
CFIndex CFWriteStreamWrite(CFWriteStreamRef stream, const UInt8 *buffer, CFIndex bufferLength);
extern
CFTypeRef CFReadStreamCopyProperty(CFReadStreamRef stream, CFStringRef propertyName);
extern
CFTypeRef CFWriteStreamCopyProperty(CFWriteStreamRef stream, CFStringRef propertyName);
extern
Boolean CFReadStreamSetProperty(CFReadStreamRef stream, CFStringRef propertyName, CFTypeRef propertyValue);
extern
Boolean CFWriteStreamSetProperty(CFWriteStreamRef stream, CFStringRef propertyName, CFTypeRef propertyValue);
extern
Boolean CFReadStreamSetClient(CFReadStreamRef stream, CFOptionFlags streamEvents, CFReadStreamClientCallBack clientCB, CFStreamClientContext *clientContext);
extern
Boolean CFWriteStreamSetClient(CFWriteStreamRef stream, CFOptionFlags streamEvents, CFWriteStreamClientCallBack clientCB, CFStreamClientContext *clientContext);
extern
void CFReadStreamScheduleWithRunLoop(CFReadStreamRef stream, CFRunLoopRef runLoop, CFStringRef runLoopMode);
extern
void CFWriteStreamScheduleWithRunLoop(CFWriteStreamRef stream, CFRunLoopRef runLoop, CFStringRef runLoopMode);
extern
void CFReadStreamUnscheduleFromRunLoop(CFReadStreamRef stream, CFRunLoopRef runLoop, CFStringRef runLoopMode);
extern
void CFWriteStreamUnscheduleFromRunLoop(CFWriteStreamRef stream, CFRunLoopRef runLoop, CFStringRef runLoopMode);
extern
void CFReadStreamSetDispatchQueue(CFReadStreamRef stream, dispatch_queue_t q) __attribute__((availability(macosx,introduced=10.9)));
extern
void CFWriteStreamSetDispatchQueue(CFWriteStreamRef stream, dispatch_queue_t q) __attribute__((availability(macosx,introduced=10.9)));
extern
dispatch_queue_t CFReadStreamCopyDispatchQueue(CFReadStreamRef stream) __attribute__((availability(macosx,introduced=10.9)));
extern
dispatch_queue_t CFWriteStreamCopyDispatchQueue(CFWriteStreamRef stream) __attribute__((availability(macosx,introduced=10.9)));
typedef CFIndex CFStreamErrorDomain; enum {
kCFStreamErrorDomainCustom = -1L,
kCFStreamErrorDomainPOSIX = 1,
kCFStreamErrorDomainMacOSStatus
};
typedef struct {
CFIndex domain;
SInt32 error;
} CFStreamError;
extern
CFStreamError CFReadStreamGetError(CFReadStreamRef stream);
extern
CFStreamError CFWriteStreamGetError(CFWriteStreamRef stream);
}
extern "C" {
typedef CFOptionFlags CFPropertyListMutabilityOptions; enum {
kCFPropertyListImmutable = 0,
kCFPropertyListMutableContainers,
kCFPropertyListMutableContainersAndLeaves
};
extern
CFPropertyListRef CFPropertyListCreateFromXMLData(CFAllocatorRef allocator, CFDataRef xmlData, CFOptionFlags mutabilityOption, CFStringRef *errorString) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.10,message="" "Use CFPropertyListCreateWithData instead.")));
extern
CFDataRef CFPropertyListCreateXMLData(CFAllocatorRef allocator, CFPropertyListRef propertyList) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.10,message="" "Use CFPropertyListCreateData instead.")));
extern
CFPropertyListRef CFPropertyListCreateDeepCopy(CFAllocatorRef allocator, CFPropertyListRef propertyList, CFOptionFlags mutabilityOption);
typedef CFIndex CFPropertyListFormat; enum {
kCFPropertyListOpenStepFormat = 1,
kCFPropertyListXMLFormat_v1_0 = 100,
kCFPropertyListBinaryFormat_v1_0 = 200
};
extern
Boolean CFPropertyListIsValid(CFPropertyListRef plist, CFPropertyListFormat format);
extern
CFIndex CFPropertyListWriteToStream(CFPropertyListRef propertyList, CFWriteStreamRef stream, CFPropertyListFormat format, CFStringRef *errorString) __attribute__((availability(macosx,introduced=10.2 ,deprecated=10.10,message="" "Use CFPropertyListWrite instead.")));
extern
CFPropertyListRef CFPropertyListCreateFromStream(CFAllocatorRef allocator, CFReadStreamRef stream, CFIndex streamLength, CFOptionFlags mutabilityOption, CFPropertyListFormat *format, CFStringRef *errorString) __attribute__((availability(macosx,introduced=10.2 ,deprecated=10.10,message="" "Use CFPropertyListCreateWithStream instead.")));
enum {
kCFPropertyListReadCorruptError = 3840,
kCFPropertyListReadUnknownVersionError = 3841,
kCFPropertyListReadStreamError = 3842,
kCFPropertyListWriteStreamError = 3851,
} __attribute__((availability(macosx,introduced=10.6)));
extern
CFPropertyListRef CFPropertyListCreateWithData(CFAllocatorRef allocator, CFDataRef data, CFOptionFlags options, CFPropertyListFormat *format, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.6)));
extern
CFPropertyListRef CFPropertyListCreateWithStream(CFAllocatorRef allocator, CFReadStreamRef stream, CFIndex streamLength, CFOptionFlags options, CFPropertyListFormat *format, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.6)));
extern
CFIndex CFPropertyListWrite(CFPropertyListRef propertyList, CFWriteStreamRef stream, CFPropertyListFormat format, CFOptionFlags options, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.6)));
extern
CFDataRef CFPropertyListCreateData(CFAllocatorRef allocator, CFPropertyListRef propertyList, CFPropertyListFormat format, CFOptionFlags options, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.6)));
}
extern "C" {
typedef const void * (*CFSetRetainCallBack)(CFAllocatorRef allocator, const void *value);
typedef void (*CFSetReleaseCallBack)(CFAllocatorRef allocator, const void *value);
typedef CFStringRef (*CFSetCopyDescriptionCallBack)(const void *value);
typedef Boolean (*CFSetEqualCallBack)(const void *value1, const void *value2);
typedef CFHashCode (*CFSetHashCallBack)(const void *value);
typedef struct {
CFIndex version;
CFSetRetainCallBack retain;
CFSetReleaseCallBack release;
CFSetCopyDescriptionCallBack copyDescription;
CFSetEqualCallBack equal;
CFSetHashCallBack hash;
} CFSetCallBacks;
extern
const CFSetCallBacks kCFTypeSetCallBacks;
extern
const CFSetCallBacks kCFCopyStringSetCallBacks;
typedef void (*CFSetApplierFunction)(const void *value, void *context);
typedef const struct __attribute__((objc_bridge(NSSet))) __CFSet * CFSetRef;
typedef struct __attribute__((objc_bridge_mutable(NSMutableSet))) __CFSet * CFMutableSetRef;
extern
CFTypeID CFSetGetTypeID(void);
extern
CFSetRef CFSetCreate(CFAllocatorRef allocator, const void **values, CFIndex numValues, const CFSetCallBacks *callBacks);
extern
CFSetRef CFSetCreateCopy(CFAllocatorRef allocator, CFSetRef theSet);
extern
CFMutableSetRef CFSetCreateMutable(CFAllocatorRef allocator, CFIndex capacity, const CFSetCallBacks *callBacks);
extern
CFMutableSetRef CFSetCreateMutableCopy(CFAllocatorRef allocator, CFIndex capacity, CFSetRef theSet);
extern
CFIndex CFSetGetCount(CFSetRef theSet);
extern
CFIndex CFSetGetCountOfValue(CFSetRef theSet, const void *value);
extern
Boolean CFSetContainsValue(CFSetRef theSet, const void *value);
extern
const void *CFSetGetValue(CFSetRef theSet, const void *value);
extern
Boolean CFSetGetValueIfPresent(CFSetRef theSet, const void *candidate, const void **value);
extern
void CFSetGetValues(CFSetRef theSet, const void **values);
extern
void CFSetApplyFunction(CFSetRef theSet, CFSetApplierFunction applier, void *context);
extern
void CFSetAddValue(CFMutableSetRef theSet, const void *value);
extern
void CFSetReplaceValue(CFMutableSetRef theSet, const void *value);
extern
void CFSetSetValue(CFMutableSetRef theSet, const void *value);
extern
void CFSetRemoveValue(CFMutableSetRef theSet, const void *value);
extern
void CFSetRemoveAllValues(CFMutableSetRef theSet);
}
extern "C" {
typedef CFIndex CFStringEncodings; enum {
kCFStringEncodingMacJapanese = 1,
kCFStringEncodingMacChineseTrad = 2,
kCFStringEncodingMacKorean = 3,
kCFStringEncodingMacArabic = 4,
kCFStringEncodingMacHebrew = 5,
kCFStringEncodingMacGreek = 6,
kCFStringEncodingMacCyrillic = 7,
kCFStringEncodingMacDevanagari = 9,
kCFStringEncodingMacGurmukhi = 10,
kCFStringEncodingMacGujarati = 11,
kCFStringEncodingMacOriya = 12,
kCFStringEncodingMacBengali = 13,
kCFStringEncodingMacTamil = 14,
kCFStringEncodingMacTelugu = 15,
kCFStringEncodingMacKannada = 16,
kCFStringEncodingMacMalayalam = 17,
kCFStringEncodingMacSinhalese = 18,
kCFStringEncodingMacBurmese = 19,
kCFStringEncodingMacKhmer = 20,
kCFStringEncodingMacThai = 21,
kCFStringEncodingMacLaotian = 22,
kCFStringEncodingMacGeorgian = 23,
kCFStringEncodingMacArmenian = 24,
kCFStringEncodingMacChineseSimp = 25,
kCFStringEncodingMacTibetan = 26,
kCFStringEncodingMacMongolian = 27,
kCFStringEncodingMacEthiopic = 28,
kCFStringEncodingMacCentralEurRoman = 29,
kCFStringEncodingMacVietnamese = 30,
kCFStringEncodingMacExtArabic = 31,
kCFStringEncodingMacSymbol = 33,
kCFStringEncodingMacDingbats = 34,
kCFStringEncodingMacTurkish = 35,
kCFStringEncodingMacCroatian = 36,
kCFStringEncodingMacIcelandic = 37,
kCFStringEncodingMacRomanian = 38,
kCFStringEncodingMacCeltic = 39,
kCFStringEncodingMacGaelic = 40,
kCFStringEncodingMacFarsi = 0x8C,
kCFStringEncodingMacUkrainian = 0x98,
kCFStringEncodingMacInuit = 0xEC,
kCFStringEncodingMacVT100 = 0xFC,
kCFStringEncodingMacHFS = 0xFF,
kCFStringEncodingISOLatin2 = 0x0202,
kCFStringEncodingISOLatin3 = 0x0203,
kCFStringEncodingISOLatin4 = 0x0204,
kCFStringEncodingISOLatinCyrillic = 0x0205,
kCFStringEncodingISOLatinArabic = 0x0206,
kCFStringEncodingISOLatinGreek = 0x0207,
kCFStringEncodingISOLatinHebrew = 0x0208,
kCFStringEncodingISOLatin5 = 0x0209,
kCFStringEncodingISOLatin6 = 0x020A,
kCFStringEncodingISOLatinThai = 0x020B,
kCFStringEncodingISOLatin7 = 0x020D,
kCFStringEncodingISOLatin8 = 0x020E,
kCFStringEncodingISOLatin9 = 0x020F,
kCFStringEncodingISOLatin10 = 0x0210,
kCFStringEncodingDOSLatinUS = 0x0400,
kCFStringEncodingDOSGreek = 0x0405,
kCFStringEncodingDOSBalticRim = 0x0406,
kCFStringEncodingDOSLatin1 = 0x0410,
kCFStringEncodingDOSGreek1 = 0x0411,
kCFStringEncodingDOSLatin2 = 0x0412,
kCFStringEncodingDOSCyrillic = 0x0413,
kCFStringEncodingDOSTurkish = 0x0414,
kCFStringEncodingDOSPortuguese = 0x0415,
kCFStringEncodingDOSIcelandic = 0x0416,
kCFStringEncodingDOSHebrew = 0x0417,
kCFStringEncodingDOSCanadianFrench = 0x0418,
kCFStringEncodingDOSArabic = 0x0419,
kCFStringEncodingDOSNordic = 0x041A,
kCFStringEncodingDOSRussian = 0x041B,
kCFStringEncodingDOSGreek2 = 0x041C,
kCFStringEncodingDOSThai = 0x041D,
kCFStringEncodingDOSJapanese = 0x0420,
kCFStringEncodingDOSChineseSimplif = 0x0421,
kCFStringEncodingDOSKorean = 0x0422,
kCFStringEncodingDOSChineseTrad = 0x0423,
kCFStringEncodingWindowsLatin2 = 0x0501,
kCFStringEncodingWindowsCyrillic = 0x0502,
kCFStringEncodingWindowsGreek = 0x0503,
kCFStringEncodingWindowsLatin5 = 0x0504,
kCFStringEncodingWindowsHebrew = 0x0505,
kCFStringEncodingWindowsArabic = 0x0506,
kCFStringEncodingWindowsBalticRim = 0x0507,
kCFStringEncodingWindowsVietnamese = 0x0508,
kCFStringEncodingWindowsKoreanJohab = 0x0510,
kCFStringEncodingANSEL = 0x0601,
kCFStringEncodingJIS_X0201_76 = 0x0620,
kCFStringEncodingJIS_X0208_83 = 0x0621,
kCFStringEncodingJIS_X0208_90 = 0x0622,
kCFStringEncodingJIS_X0212_90 = 0x0623,
kCFStringEncodingJIS_C6226_78 = 0x0624,
kCFStringEncodingShiftJIS_X0213 __attribute__((availability(macosx,introduced=10.5))) = 0x0628,
kCFStringEncodingShiftJIS_X0213_MenKuTen = 0x0629,
kCFStringEncodingGB_2312_80 = 0x0630,
kCFStringEncodingGBK_95 = 0x0631,
kCFStringEncodingGB_18030_2000 = 0x0632,
kCFStringEncodingKSC_5601_87 = 0x0640,
kCFStringEncodingKSC_5601_92_Johab = 0x0641,
kCFStringEncodingCNS_11643_92_P1 = 0x0651,
kCFStringEncodingCNS_11643_92_P2 = 0x0652,
kCFStringEncodingCNS_11643_92_P3 = 0x0653,
kCFStringEncodingISO_2022_JP = 0x0820,
kCFStringEncodingISO_2022_JP_2 = 0x0821,
kCFStringEncodingISO_2022_JP_1 = 0x0822,
kCFStringEncodingISO_2022_JP_3 = 0x0823,
kCFStringEncodingISO_2022_CN = 0x0830,
kCFStringEncodingISO_2022_CN_EXT = 0x0831,
kCFStringEncodingISO_2022_KR = 0x0840,
kCFStringEncodingEUC_JP = 0x0920,
kCFStringEncodingEUC_CN = 0x0930,
kCFStringEncodingEUC_TW = 0x0931,
kCFStringEncodingEUC_KR = 0x0940,
kCFStringEncodingShiftJIS = 0x0A01,
kCFStringEncodingKOI8_R = 0x0A02,
kCFStringEncodingBig5 = 0x0A03,
kCFStringEncodingMacRomanLatin1 = 0x0A04,
kCFStringEncodingHZ_GB_2312 = 0x0A05,
kCFStringEncodingBig5_HKSCS_1999 = 0x0A06,
kCFStringEncodingVISCII = 0x0A07,
kCFStringEncodingKOI8_U = 0x0A08,
kCFStringEncodingBig5_E = 0x0A09,
kCFStringEncodingNextStepJapanese = 0x0B02,
kCFStringEncodingEBCDIC_US = 0x0C01,
kCFStringEncodingEBCDIC_CP037 = 0x0C02,
kCFStringEncodingUTF7 __attribute__((availability(macosx,introduced=10.6))) = 0x04000100,
kCFStringEncodingUTF7_IMAP __attribute__((availability(macosx,introduced=10.6))) = 0x0A10,
kCFStringEncodingShiftJIS_X0213_00 = 0x0628
};
}
extern "C" {
typedef const void * (*CFTreeRetainCallBack)(const void *info);
typedef void (*CFTreeReleaseCallBack)(const void *info);
typedef CFStringRef (*CFTreeCopyDescriptionCallBack)(const void *info);
typedef struct {
CFIndex version;
void * info;
CFTreeRetainCallBack retain;
CFTreeReleaseCallBack release;
CFTreeCopyDescriptionCallBack copyDescription;
} CFTreeContext;
typedef void (*CFTreeApplierFunction)(const void *value, void *context);
typedef struct __CFTree * CFTreeRef;
extern
CFTypeID CFTreeGetTypeID(void);
extern
CFTreeRef CFTreeCreate(CFAllocatorRef allocator, const CFTreeContext *context);
extern
CFTreeRef CFTreeGetParent(CFTreeRef tree);
extern
CFTreeRef CFTreeGetNextSibling(CFTreeRef tree);
extern
CFTreeRef CFTreeGetFirstChild(CFTreeRef tree);
extern
void CFTreeGetContext(CFTreeRef tree, CFTreeContext *context);
extern
CFIndex CFTreeGetChildCount(CFTreeRef tree);
extern
CFTreeRef CFTreeGetChildAtIndex(CFTreeRef tree, CFIndex idx);
extern
void CFTreeGetChildren(CFTreeRef tree, CFTreeRef *children);
extern
void CFTreeApplyFunctionToChildren(CFTreeRef tree, CFTreeApplierFunction applier, void *context);
extern
CFTreeRef CFTreeFindRoot(CFTreeRef tree);
extern
void CFTreeSetContext(CFTreeRef tree, const CFTreeContext *context);
extern
void CFTreePrependChild(CFTreeRef tree, CFTreeRef newChild);
extern
void CFTreeAppendChild(CFTreeRef tree, CFTreeRef newChild);
extern
void CFTreeInsertSibling(CFTreeRef tree, CFTreeRef newSibling);
extern
void CFTreeRemove(CFTreeRef tree);
extern
void CFTreeRemoveAllChildren(CFTreeRef tree);
extern
void CFTreeSortChildren(CFTreeRef tree, CFComparatorFunction comparator, void *context);
}
extern "C" {
extern
Boolean CFURLCreateDataAndPropertiesFromResource(CFAllocatorRef alloc, CFURLRef url, CFDataRef *resourceData, CFDictionaryRef *properties, CFArrayRef desiredProperties, SInt32 *errorCode) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "For resource data, use the CFReadStream API. For file resource properties, use CFURLCopyResourcePropertiesForKeys.")));
extern
Boolean CFURLWriteDataAndPropertiesToResource(CFURLRef url, CFDataRef dataToWrite, CFDictionaryRef propertiesToWrite, SInt32 *errorCode) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "For resource data, use the CFWriteStream API. For file resource properties, use CFURLSetResourcePropertiesForKeys.")));
extern
Boolean CFURLDestroyResource(CFURLRef url, SInt32 *errorCode) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "Use CFURLGetFileSystemRepresentation and removefile(3) instead.")));
extern
CFTypeRef CFURLCreatePropertyFromResource(CFAllocatorRef alloc, CFURLRef url, CFStringRef property, SInt32 *errorCode) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "For file resource properties, use CFURLCopyResourcePropertyForKey.")));
typedef CFIndex CFURLError; enum {
kCFURLUnknownError = -10L,
kCFURLUnknownSchemeError = -11L,
kCFURLResourceNotFoundError = -12L,
kCFURLResourceAccessViolationError = -13L,
kCFURLRemoteHostUnavailableError = -14L,
kCFURLImproperArgumentsError = -15L,
kCFURLUnknownPropertyKeyError = -16L,
kCFURLPropertyKeyUnavailableError = -17L,
kCFURLTimeoutError = -18L
} __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" )));
extern
const CFStringRef kCFURLFileExists __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "Use CFURLResourceIsReachable instead.")));
extern
const CFStringRef kCFURLFileDirectoryContents __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "Use the CFURLEnumerator API instead.")));
extern
const CFStringRef kCFURLFileLength __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "Use CFURLCopyResourcePropertyForKey with kCFURLFileSizeKey instead.")));
extern
const CFStringRef kCFURLFileLastModificationTime __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "Use CFURLCopyResourcePropertyForKey with kCFURLContentModificationDateKey instead.")));
extern
const CFStringRef kCFURLFilePOSIXMode __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "Use CFURLCopyResourcePropertyForKey with kCFURLFileSecurityKey and then the CFFileSecurity API instead.")));
extern
const CFStringRef kCFURLFileOwnerID __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "Use CFURLCopyResourcePropertyForKey with kCFURLFileSecurityKey and then the CFFileSecurity API instead.")));
extern
const CFStringRef kCFURLHTTPStatusCode __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "Use NSHTTPURLResponse methods instead.")));
extern
const CFStringRef kCFURLHTTPStatusLine __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.9,message="" "Use NSHTTPURLResponse methods instead.")));
}
extern "C" {
typedef const struct __CFUUID * CFUUIDRef;
typedef struct {
UInt8 byte0;
UInt8 byte1;
UInt8 byte2;
UInt8 byte3;
UInt8 byte4;
UInt8 byte5;
UInt8 byte6;
UInt8 byte7;
UInt8 byte8;
UInt8 byte9;
UInt8 byte10;
UInt8 byte11;
UInt8 byte12;
UInt8 byte13;
UInt8 byte14;
UInt8 byte15;
} CFUUIDBytes;
extern
CFTypeID CFUUIDGetTypeID(void);
extern
CFUUIDRef CFUUIDCreate(CFAllocatorRef alloc);
extern
CFUUIDRef CFUUIDCreateWithBytes(CFAllocatorRef alloc, UInt8 byte0, UInt8 byte1, UInt8 byte2, UInt8 byte3, UInt8 byte4, UInt8 byte5, UInt8 byte6, UInt8 byte7, UInt8 byte8, UInt8 byte9, UInt8 byte10, UInt8 byte11, UInt8 byte12, UInt8 byte13, UInt8 byte14, UInt8 byte15);
extern
CFUUIDRef CFUUIDCreateFromString(CFAllocatorRef alloc, CFStringRef uuidStr);
extern
CFStringRef CFUUIDCreateString(CFAllocatorRef alloc, CFUUIDRef uuid);
extern
CFUUIDRef CFUUIDGetConstantUUIDWithBytes(CFAllocatorRef alloc, UInt8 byte0, UInt8 byte1, UInt8 byte2, UInt8 byte3, UInt8 byte4, UInt8 byte5, UInt8 byte6, UInt8 byte7, UInt8 byte8, UInt8 byte9, UInt8 byte10, UInt8 byte11, UInt8 byte12, UInt8 byte13, UInt8 byte14, UInt8 byte15);
extern
CFUUIDBytes CFUUIDGetUUIDBytes(CFUUIDRef uuid);
extern
CFUUIDRef CFUUIDCreateFromUUIDBytes(CFAllocatorRef alloc, CFUUIDBytes bytes);
}
extern "C" {
extern
CFURLRef CFCopyHomeDirectoryURL(void) __attribute__((availability(macosx,unavailable)));
}
extern "C" {
typedef struct __CFBundle *CFBundleRef;
typedef struct __CFBundle *CFPlugInRef;
extern
const CFStringRef kCFBundleInfoDictionaryVersionKey;
extern
const CFStringRef kCFBundleExecutableKey;
extern
const CFStringRef kCFBundleIdentifierKey;
extern
const CFStringRef kCFBundleVersionKey;
extern
const CFStringRef kCFBundleDevelopmentRegionKey;
extern
const CFStringRef kCFBundleNameKey;
extern
const CFStringRef kCFBundleLocalizationsKey;
extern
CFBundleRef CFBundleGetMainBundle(void);
extern
CFBundleRef CFBundleGetBundleWithIdentifier(CFStringRef bundleID);
extern
CFArrayRef CFBundleGetAllBundles(void);
extern
CFTypeID CFBundleGetTypeID(void);
extern
CFBundleRef CFBundleCreate(CFAllocatorRef allocator, CFURLRef bundleURL);
extern
CFArrayRef CFBundleCreateBundlesFromDirectory(CFAllocatorRef allocator, CFURLRef directoryURL, CFStringRef bundleType);
extern
CFURLRef CFBundleCopyBundleURL(CFBundleRef bundle);
extern
CFTypeRef CFBundleGetValueForInfoDictionaryKey(CFBundleRef bundle, CFStringRef key);
extern
CFDictionaryRef CFBundleGetInfoDictionary(CFBundleRef bundle);
extern
CFDictionaryRef CFBundleGetLocalInfoDictionary(CFBundleRef bundle);
extern
void CFBundleGetPackageInfo(CFBundleRef bundle, UInt32 *packageType, UInt32 *packageCreator);
extern
CFStringRef CFBundleGetIdentifier(CFBundleRef bundle);
extern
UInt32 CFBundleGetVersionNumber(CFBundleRef bundle);
extern
CFStringRef CFBundleGetDevelopmentRegion(CFBundleRef bundle);
extern
CFURLRef CFBundleCopySupportFilesDirectoryURL(CFBundleRef bundle);
extern
CFURLRef CFBundleCopyResourcesDirectoryURL(CFBundleRef bundle);
extern
CFURLRef CFBundleCopyPrivateFrameworksURL(CFBundleRef bundle);
extern
CFURLRef CFBundleCopySharedFrameworksURL(CFBundleRef bundle);
extern
CFURLRef CFBundleCopySharedSupportURL(CFBundleRef bundle);
extern
CFURLRef CFBundleCopyBuiltInPlugInsURL(CFBundleRef bundle);
extern
CFDictionaryRef CFBundleCopyInfoDictionaryInDirectory(CFURLRef bundleURL);
extern
Boolean CFBundleGetPackageInfoInDirectory(CFURLRef url, UInt32 *packageType, UInt32 *packageCreator);
extern
CFURLRef CFBundleCopyResourceURL(CFBundleRef bundle, CFStringRef resourceName, CFStringRef resourceType, CFStringRef subDirName);
extern
CFArrayRef CFBundleCopyResourceURLsOfType(CFBundleRef bundle, CFStringRef resourceType, CFStringRef subDirName);
extern
CFStringRef CFBundleCopyLocalizedString(CFBundleRef bundle, CFStringRef key, CFStringRef value, CFStringRef tableName) __attribute__((format_arg(2)));
extern
CFURLRef CFBundleCopyResourceURLInDirectory(CFURLRef bundleURL, CFStringRef resourceName, CFStringRef resourceType, CFStringRef subDirName);
extern
CFArrayRef CFBundleCopyResourceURLsOfTypeInDirectory(CFURLRef bundleURL, CFStringRef resourceType, CFStringRef subDirName);
extern
CFArrayRef CFBundleCopyBundleLocalizations(CFBundleRef bundle);
extern
CFArrayRef CFBundleCopyPreferredLocalizationsFromArray(CFArrayRef locArray);
extern
CFArrayRef CFBundleCopyLocalizationsForPreferences(CFArrayRef locArray, CFArrayRef prefArray);
extern
CFURLRef CFBundleCopyResourceURLForLocalization(CFBundleRef bundle, CFStringRef resourceName, CFStringRef resourceType, CFStringRef subDirName, CFStringRef localizationName);
extern
CFArrayRef CFBundleCopyResourceURLsOfTypeForLocalization(CFBundleRef bundle, CFStringRef resourceType, CFStringRef subDirName, CFStringRef localizationName);
extern
CFDictionaryRef CFBundleCopyInfoDictionaryForURL(CFURLRef url);
extern
CFArrayRef CFBundleCopyLocalizationsForURL(CFURLRef url);
extern
CFArrayRef CFBundleCopyExecutableArchitecturesForURL(CFURLRef url) __attribute__((availability(macosx,introduced=10.5)));
extern
CFURLRef CFBundleCopyExecutableURL(CFBundleRef bundle);
enum {
kCFBundleExecutableArchitectureI386 = 0x00000007,
kCFBundleExecutableArchitecturePPC = 0x00000012,
kCFBundleExecutableArchitectureX86_64 = 0x01000007,
kCFBundleExecutableArchitecturePPC64 = 0x01000012
} __attribute__((availability(macosx,introduced=10.5)));
extern
CFArrayRef CFBundleCopyExecutableArchitectures(CFBundleRef bundle) __attribute__((availability(macosx,introduced=10.5)));
extern
Boolean CFBundlePreflightExecutable(CFBundleRef bundle, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.5)));
extern
Boolean CFBundleLoadExecutableAndReturnError(CFBundleRef bundle, CFErrorRef *error) __attribute__((availability(macosx,introduced=10.5)));
extern
Boolean CFBundleLoadExecutable(CFBundleRef bundle);
extern
Boolean CFBundleIsExecutableLoaded(CFBundleRef bundle);
extern
void CFBundleUnloadExecutable(CFBundleRef bundle);
extern
void *CFBundleGetFunctionPointerForName(CFBundleRef bundle, CFStringRef functionName);
extern
void CFBundleGetFunctionPointersForNames(CFBundleRef bundle, CFArrayRef functionNames, void *ftbl[]);
extern
void *CFBundleGetDataPointerForName(CFBundleRef bundle, CFStringRef symbolName);
extern
void CFBundleGetDataPointersForNames(CFBundleRef bundle, CFArrayRef symbolNames, void *stbl[]);
extern
CFURLRef CFBundleCopyAuxiliaryExecutableURL(CFBundleRef bundle, CFStringRef executableName);
extern
CFPlugInRef CFBundleGetPlugIn(CFBundleRef bundle);
typedef int CFBundleRefNum;
extern
CFBundleRefNum CFBundleOpenBundleResourceMap(CFBundleRef bundle);
extern
SInt32 CFBundleOpenBundleResourceFiles(CFBundleRef bundle, CFBundleRefNum *refNum, CFBundleRefNum *localizedRefNum);
extern
void CFBundleCloseBundleResourceMap(CFBundleRef bundle, CFBundleRefNum refNum);
}
extern "C" {
typedef struct __attribute__((objc_bridge_mutable(NSMessagePort))) __CFMessagePort * CFMessagePortRef;
enum {
kCFMessagePortSuccess = 0,
kCFMessagePortSendTimeout = -1,
kCFMessagePortReceiveTimeout = -2,
kCFMessagePortIsInvalid = -3,
kCFMessagePortTransportError = -4,
kCFMessagePortBecameInvalidError = -5
};
typedef struct {
CFIndex version;
void * info;
const void *(*retain)(const void *info);
void (*release)(const void *info);
CFStringRef (*copyDescription)(const void *info);
} CFMessagePortContext;
typedef CFDataRef (*CFMessagePortCallBack)(CFMessagePortRef local, SInt32 msgid, CFDataRef data, void *info);
typedef void (*CFMessagePortInvalidationCallBack)(CFMessagePortRef ms, void *info);
extern CFTypeID CFMessagePortGetTypeID(void);
extern CFMessagePortRef CFMessagePortCreateLocal(CFAllocatorRef allocator, CFStringRef name, CFMessagePortCallBack callout, CFMessagePortContext *context, Boolean *shouldFreeInfo);
extern CFMessagePortRef CFMessagePortCreateRemote(CFAllocatorRef allocator, CFStringRef name);
extern Boolean CFMessagePortIsRemote(CFMessagePortRef ms);
extern CFStringRef CFMessagePortGetName(CFMessagePortRef ms);
extern Boolean CFMessagePortSetName(CFMessagePortRef ms, CFStringRef newName);
extern void CFMessagePortGetContext(CFMessagePortRef ms, CFMessagePortContext *context);
extern void CFMessagePortInvalidate(CFMessagePortRef ms);
extern Boolean CFMessagePortIsValid(CFMessagePortRef ms);
extern CFMessagePortInvalidationCallBack CFMessagePortGetInvalidationCallBack(CFMessagePortRef ms);
extern void CFMessagePortSetInvalidationCallBack(CFMessagePortRef ms, CFMessagePortInvalidationCallBack callout);
extern SInt32 CFMessagePortSendRequest(CFMessagePortRef remote, SInt32 msgid, CFDataRef data, CFTimeInterval sendTimeout, CFTimeInterval rcvTimeout, CFStringRef replyMode, CFDataRef *returnData);
extern CFRunLoopSourceRef CFMessagePortCreateRunLoopSource(CFAllocatorRef allocator, CFMessagePortRef local, CFIndex order);
extern void CFMessagePortSetDispatchQueue(CFMessagePortRef ms, dispatch_queue_t queue) __attribute__((availability(macosx,introduced=10.6)));
}
extern "C" {
extern const CFStringRef kCFPlugInDynamicRegistrationKey;
extern const CFStringRef kCFPlugInDynamicRegisterFunctionKey;
extern const CFStringRef kCFPlugInUnloadFunctionKey;
extern const CFStringRef kCFPlugInFactoriesKey;
extern const CFStringRef kCFPlugInTypesKey;
typedef void (*CFPlugInDynamicRegisterFunction)(CFPlugInRef plugIn);
typedef void (*CFPlugInUnloadFunction)(CFPlugInRef plugIn);
typedef void *(*CFPlugInFactoryFunction)(CFAllocatorRef allocator, CFUUIDRef typeUUID);
extern CFTypeID CFPlugInGetTypeID(void);
extern CFPlugInRef CFPlugInCreate(CFAllocatorRef allocator, CFURLRef plugInURL);
extern CFBundleRef CFPlugInGetBundle(CFPlugInRef plugIn);
extern void CFPlugInSetLoadOnDemand(CFPlugInRef plugIn, Boolean flag);
extern Boolean CFPlugInIsLoadOnDemand(CFPlugInRef plugIn);
extern CFArrayRef CFPlugInFindFactoriesForPlugInType(CFUUIDRef typeUUID) __attribute__((cf_returns_retained));
extern CFArrayRef CFPlugInFindFactoriesForPlugInTypeInPlugIn(CFUUIDRef typeUUID, CFPlugInRef plugIn) __attribute__((cf_returns_retained));
extern void *CFPlugInInstanceCreate(CFAllocatorRef allocator, CFUUIDRef factoryUUID, CFUUIDRef typeUUID);
extern Boolean CFPlugInRegisterFactoryFunction(CFUUIDRef factoryUUID, CFPlugInFactoryFunction func);
extern Boolean CFPlugInRegisterFactoryFunctionByName(CFUUIDRef factoryUUID, CFPlugInRef plugIn, CFStringRef functionName);
extern Boolean CFPlugInUnregisterFactory(CFUUIDRef factoryUUID);
extern Boolean CFPlugInRegisterPlugInType(CFUUIDRef factoryUUID, CFUUIDRef typeUUID);
extern Boolean CFPlugInUnregisterPlugInType(CFUUIDRef factoryUUID, CFUUIDRef typeUUID);
extern void CFPlugInAddInstanceForFactory(CFUUIDRef factoryID);
extern void CFPlugInRemoveInstanceForFactory(CFUUIDRef factoryID);
typedef struct __CFPlugInInstance *CFPlugInInstanceRef;
typedef Boolean (*CFPlugInInstanceGetInterfaceFunction)(CFPlugInInstanceRef instance, CFStringRef interfaceName, void **ftbl);
typedef void (*CFPlugInInstanceDeallocateInstanceDataFunction)(void *instanceData);
extern Boolean CFPlugInInstanceGetInterfaceFunctionTable(CFPlugInInstanceRef instance, CFStringRef interfaceName, void **ftbl);
extern CFStringRef CFPlugInInstanceGetFactoryName(CFPlugInInstanceRef instance) __attribute__((cf_returns_retained));
extern void *CFPlugInInstanceGetInstanceData(CFPlugInInstanceRef instance);
extern CFTypeID CFPlugInInstanceGetTypeID(void);
extern CFPlugInInstanceRef CFPlugInInstanceCreateWithInstanceDataSize(CFAllocatorRef allocator, CFIndex instanceDataSize, CFPlugInInstanceDeallocateInstanceDataFunction deallocateInstanceFunction, CFStringRef factoryName, CFPlugInInstanceGetInterfaceFunction getInterfaceFunction);
}
extern "C" {
typedef const struct __attribute__((objc_bridge(NSAttributedString))) __CFAttributedString *CFAttributedStringRef;
typedef struct __attribute__((objc_bridge_mutable(NSMutableAttributedString))) __CFAttributedString *CFMutableAttributedStringRef;
extern CFTypeID CFAttributedStringGetTypeID(void);
extern CFAttributedStringRef CFAttributedStringCreate(CFAllocatorRef alloc, CFStringRef str, CFDictionaryRef attributes);
extern CFAttributedStringRef CFAttributedStringCreateWithSubstring(CFAllocatorRef alloc, CFAttributedStringRef aStr, CFRange range);
extern CFAttributedStringRef CFAttributedStringCreateCopy(CFAllocatorRef alloc, CFAttributedStringRef aStr);
extern CFStringRef CFAttributedStringGetString(CFAttributedStringRef aStr);
extern CFIndex CFAttributedStringGetLength(CFAttributedStringRef aStr);
extern CFDictionaryRef CFAttributedStringGetAttributes(CFAttributedStringRef aStr, CFIndex loc, CFRange *effectiveRange);
extern CFTypeRef CFAttributedStringGetAttribute(CFAttributedStringRef aStr, CFIndex loc, CFStringRef attrName, CFRange *effectiveRange);
extern CFDictionaryRef CFAttributedStringGetAttributesAndLongestEffectiveRange(CFAttributedStringRef aStr, CFIndex loc, CFRange inRange, CFRange *longestEffectiveRange);
extern CFTypeRef CFAttributedStringGetAttributeAndLongestEffectiveRange(CFAttributedStringRef aStr, CFIndex loc, CFStringRef attrName, CFRange inRange, CFRange *longestEffectiveRange);
extern CFMutableAttributedStringRef CFAttributedStringCreateMutableCopy(CFAllocatorRef alloc, CFIndex maxLength, CFAttributedStringRef aStr);
extern CFMutableAttributedStringRef CFAttributedStringCreateMutable(CFAllocatorRef alloc, CFIndex maxLength);
extern void CFAttributedStringReplaceString(CFMutableAttributedStringRef aStr, CFRange range, CFStringRef replacement);
extern CFMutableStringRef CFAttributedStringGetMutableString(CFMutableAttributedStringRef aStr);
extern void CFAttributedStringSetAttributes(CFMutableAttributedStringRef aStr, CFRange range, CFDictionaryRef replacement, Boolean clearOtherAttributes);
extern void CFAttributedStringSetAttribute(CFMutableAttributedStringRef aStr, CFRange range, CFStringRef attrName, CFTypeRef value);
extern void CFAttributedStringRemoveAttribute(CFMutableAttributedStringRef aStr, CFRange range, CFStringRef attrName);
extern void CFAttributedStringReplaceAttributedString(CFMutableAttributedStringRef aStr, CFRange range, CFAttributedStringRef replacement);
extern void CFAttributedStringBeginEditing(CFMutableAttributedStringRef aStr);
extern void CFAttributedStringEndEditing(CFMutableAttributedStringRef aStr);
}
extern "C" {
typedef struct __CFNotificationCenter * CFNotificationCenterRef;
typedef void (*CFNotificationCallback)(CFNotificationCenterRef center, void *observer, CFStringRef name, const void *object, CFDictionaryRef userInfo);
typedef CFIndex CFNotificationSuspensionBehavior; enum {
CFNotificationSuspensionBehaviorDrop = 1,
CFNotificationSuspensionBehaviorCoalesce = 2,
CFNotificationSuspensionBehaviorHold = 3,
CFNotificationSuspensionBehaviorDeliverImmediately = 4
};
extern CFTypeID CFNotificationCenterGetTypeID(void);
extern CFNotificationCenterRef CFNotificationCenterGetLocalCenter(void);
extern CFNotificationCenterRef CFNotificationCenterGetDistributedCenter(void);
extern CFNotificationCenterRef CFNotificationCenterGetDarwinNotifyCenter(void);
extern void CFNotificationCenterAddObserver(CFNotificationCenterRef center, const void *observer, CFNotificationCallback callBack, CFStringRef name, const void *object, CFNotificationSuspensionBehavior suspensionBehavior);
extern void CFNotificationCenterRemoveObserver(CFNotificationCenterRef center, const void *observer, CFStringRef name, const void *object);
extern void CFNotificationCenterRemoveEveryObserver(CFNotificationCenterRef center, const void *observer);
extern void CFNotificationCenterPostNotification(CFNotificationCenterRef center, CFStringRef name, const void *object, CFDictionaryRef userInfo, Boolean deliverImmediately);
enum {
kCFNotificationDeliverImmediately = (1UL << 0),
kCFNotificationPostToAllSessions = (1UL << 1)
};
extern void CFNotificationCenterPostNotificationWithOptions(CFNotificationCenterRef center, CFStringRef name, const void *object, CFDictionaryRef userInfo, CFOptionFlags options);
}
extern "C" {
typedef const struct __CFURLEnumerator *CFURLEnumeratorRef;
extern
CFTypeID CFURLEnumeratorGetTypeID( void ) __attribute__((availability(macosx,introduced=10.6)));
typedef CFOptionFlags CFURLEnumeratorOptions; enum {
kCFURLEnumeratorDefaultBehavior = 0,
kCFURLEnumeratorDescendRecursively = 1UL << 0,
kCFURLEnumeratorSkipInvisibles = 1UL << 1,
kCFURLEnumeratorGenerateFileReferenceURLs = 1UL << 2,
kCFURLEnumeratorSkipPackageContents = 1UL << 3,
kCFURLEnumeratorIncludeDirectoriesPreOrder = 1UL << 4,
kCFURLEnumeratorIncludeDirectoriesPostOrder = 1UL << 5,
};
extern
CFURLEnumeratorRef CFURLEnumeratorCreateForDirectoryURL( CFAllocatorRef alloc, CFURLRef directoryURL, CFURLEnumeratorOptions option, CFArrayRef propertyKeys ) __attribute__((availability(macosx,introduced=10.6)));
extern
CFURLEnumeratorRef CFURLEnumeratorCreateForMountedVolumes( CFAllocatorRef alloc, CFURLEnumeratorOptions option, CFArrayRef propertyKeys ) __attribute__((availability(macosx,introduced=10.6)));
typedef CFIndex CFURLEnumeratorResult; enum {
kCFURLEnumeratorSuccess = 1,
kCFURLEnumeratorEnd = 2,
kCFURLEnumeratorError = 3,
kCFURLEnumeratorDirectoryPostOrderSuccess = 4,
};
extern
CFURLEnumeratorResult CFURLEnumeratorGetNextURL( CFURLEnumeratorRef enumerator, CFURLRef *url, CFErrorRef *error ) __attribute__((availability(macosx,introduced=10.6)));
extern
void CFURLEnumeratorSkipDescendents( CFURLEnumeratorRef enumerator ) __attribute__((availability(macosx,introduced=10.6)));
extern
CFIndex CFURLEnumeratorGetDescendentLevel( CFURLEnumeratorRef enumerator ) __attribute__((availability(macosx,introduced=10.6)));
extern
Boolean CFURLEnumeratorGetSourceDidChange( CFURLEnumeratorRef enumerator ) __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.7,message="" )));
}
typedef struct {
unsigned char g_guid[16];
} guid_t;
#pragma pack(1)
typedef struct {
u_int8_t sid_kind;
u_int8_t sid_authcount;
u_int8_t sid_authority[6];
u_int32_t sid_authorities[16];
} ntsid_t;
#pragma pack()
struct kauth_identity_extlookup {
u_int32_t el_seqno;
u_int32_t el_result;
u_int32_t el_flags;
__darwin_pid_t el_info_pid;
u_int64_t el_extend;
u_int32_t el_info_reserved_1;
uid_t el_uid;
guid_t el_uguid;
u_int32_t el_uguid_valid;
ntsid_t el_usid;
u_int32_t el_usid_valid;
gid_t el_gid;
guid_t el_gguid;
u_int32_t el_gguid_valid;
ntsid_t el_gsid;
u_int32_t el_gsid_valid;
u_int32_t el_member_valid;
u_int32_t el_sup_grp_cnt;
gid_t el_sup_groups[16];
};
struct kauth_cache_sizes {
u_int32_t kcs_group_size;
u_int32_t kcs_id_size;
};
typedef u_int32_t kauth_ace_rights_t;
struct kauth_ace {
guid_t ace_applicable;
u_int32_t ace_flags;
kauth_ace_rights_t ace_rights;
};
typedef struct kauth_ace *kauth_ace_t;
struct kauth_acl {
u_int32_t acl_entrycount;
u_int32_t acl_flags;
struct kauth_ace acl_ace[1];
};
typedef struct kauth_acl *kauth_acl_t;
struct kauth_filesec {
u_int32_t fsec_magic;
guid_t fsec_owner;
guid_t fsec_group;
struct kauth_acl fsec_acl;
};
typedef struct kauth_filesec *kauth_filesec_t;
typedef enum {
ACL_READ_DATA = (1<<1),
ACL_LIST_DIRECTORY = (1<<1),
ACL_WRITE_DATA = (1<<2),
ACL_ADD_FILE = (1<<2),
ACL_EXECUTE = (1<<3),
ACL_SEARCH = (1<<3),
ACL_DELETE = (1<<4),
ACL_APPEND_DATA = (1<<5),
ACL_ADD_SUBDIRECTORY = (1<<5),
ACL_DELETE_CHILD = (1<<6),
ACL_READ_ATTRIBUTES = (1<<7),
ACL_WRITE_ATTRIBUTES = (1<<8),
ACL_READ_EXTATTRIBUTES = (1<<9),
ACL_WRITE_EXTATTRIBUTES = (1<<10),
ACL_READ_SECURITY = (1<<11),
ACL_WRITE_SECURITY = (1<<12),
ACL_CHANGE_OWNER = (1<<13),
ACL_SYNCHRONIZE = (1<<20),
} acl_perm_t;
typedef enum {
ACL_UNDEFINED_TAG = 0,
ACL_EXTENDED_ALLOW = 1,
ACL_EXTENDED_DENY = 2
} acl_tag_t;
typedef enum {
ACL_TYPE_EXTENDED = 0x00000100,
ACL_TYPE_ACCESS = 0x00000000,
ACL_TYPE_DEFAULT = 0x00000001,
ACL_TYPE_AFS = 0x00000002,
ACL_TYPE_CODA = 0x00000003,
ACL_TYPE_NTFS = 0x00000004,
ACL_TYPE_NWFS = 0x00000005
} acl_type_t;
typedef enum {
ACL_FIRST_ENTRY = 0,
ACL_NEXT_ENTRY = -1,
ACL_LAST_ENTRY = -2
} acl_entry_id_t;
typedef enum {
ACL_FLAG_DEFER_INHERIT = (1 << 0),
ACL_FLAG_NO_INHERIT = (1<<17),
ACL_ENTRY_INHERITED = (1<<4),
ACL_ENTRY_FILE_INHERIT = (1<<5),
ACL_ENTRY_DIRECTORY_INHERIT = (1<<6),
ACL_ENTRY_LIMIT_INHERIT = (1<<7),
ACL_ENTRY_ONLY_INHERIT = (1<<8)
} acl_flag_t;
struct _acl;
struct _acl_entry;
struct _acl_permset;
struct _acl_flagset;
typedef struct _acl *acl_t;
typedef struct _acl_entry *acl_entry_t;
typedef struct _acl_permset *acl_permset_t;
typedef struct _acl_flagset *acl_flagset_t;
typedef u_int64_t acl_permset_mask_t;
extern "C" {
extern acl_t acl_dup(acl_t acl);
extern int acl_free(void *obj_p);
extern acl_t acl_init(int count);
extern int acl_copy_entry(acl_entry_t dest_d, acl_entry_t src_d);
extern int acl_create_entry(acl_t *acl_p, acl_entry_t *entry_p);
extern int acl_create_entry_np(acl_t *acl_p, acl_entry_t *entry_p, int entry_index);
extern int acl_delete_entry(acl_t acl, acl_entry_t entry_d);
extern int acl_get_entry(acl_t acl, int entry_id, acl_entry_t *entry_p);
extern int acl_valid(acl_t acl);
extern int acl_valid_fd_np(int fd, acl_type_t type, acl_t acl);
extern int acl_valid_file_np(const char *path, acl_type_t type, acl_t acl);
extern int acl_valid_link_np(const char *path, acl_type_t type, acl_t acl);
extern int acl_add_perm(acl_permset_t permset_d, acl_perm_t perm);
extern int acl_calc_mask(acl_t *acl_p);
extern int acl_clear_perms(acl_permset_t permset_d);
extern int acl_delete_perm(acl_permset_t permset_d, acl_perm_t perm);
extern int acl_get_perm_np(acl_permset_t permset_d, acl_perm_t perm);
extern int acl_get_permset(acl_entry_t entry_d, acl_permset_t *permset_p);
extern int acl_set_permset(acl_entry_t entry_d, acl_permset_t permset_d);
extern int acl_maximal_permset_mask_np(acl_permset_mask_t * mask_p) __attribute__((availability(macosx,introduced=10.7)));
extern int acl_get_permset_mask_np(acl_entry_t entry_d, acl_permset_mask_t * mask_p) __attribute__((availability(macosx,introduced=10.7)));
extern int acl_set_permset_mask_np(acl_entry_t entry_d, acl_permset_mask_t mask) __attribute__((availability(macosx,introduced=10.7)));
extern int acl_add_flag_np(acl_flagset_t flagset_d, acl_flag_t flag);
extern int acl_clear_flags_np(acl_flagset_t flagset_d);
extern int acl_delete_flag_np(acl_flagset_t flagset_d, acl_flag_t flag);
extern int acl_get_flag_np(acl_flagset_t flagset_d, acl_flag_t flag);
extern int acl_get_flagset_np(void *obj_p, acl_flagset_t *flagset_p);
extern int acl_set_flagset_np(void *obj_p, acl_flagset_t flagset_d);
extern void *acl_get_qualifier(acl_entry_t entry_d);
extern int acl_get_tag_type(acl_entry_t entry_d, acl_tag_t *tag_type_p);
extern int acl_set_qualifier(acl_entry_t entry_d, const void *tag_qualifier_p);
extern int acl_set_tag_type(acl_entry_t entry_d, acl_tag_t tag_type);
extern int acl_delete_def_file(const char *path_p);
extern acl_t acl_get_fd(int fd);
extern acl_t acl_get_fd_np(int fd, acl_type_t type);
extern acl_t acl_get_file(const char *path_p, acl_type_t type);
extern acl_t acl_get_link_np(const char *path_p, acl_type_t type);
extern int acl_set_fd(int fd, acl_t acl);
extern int acl_set_fd_np(int fd, acl_t acl, acl_type_t acl_type);
extern int acl_set_file(const char *path_p, acl_type_t type, acl_t acl);
extern int acl_set_link_np(const char *path_p, acl_type_t type, acl_t acl);
extern ssize_t acl_copy_ext(void *buf_p, acl_t acl, ssize_t size);
extern ssize_t acl_copy_ext_native(void *buf_p, acl_t acl, ssize_t size);
extern acl_t acl_copy_int(const void *buf_p);
extern acl_t acl_copy_int_native(const void *buf_p);
extern acl_t acl_from_text(const char *buf_p);
extern ssize_t acl_size(acl_t acl);
extern char *acl_to_text(acl_t acl, ssize_t *len_p);
}
extern "C" {
typedef struct __attribute__((objc_bridge_mutable(NSFileSecurity))) __CFFileSecurity* CFFileSecurityRef;
extern
CFTypeID CFFileSecurityGetTypeID(void) __attribute__((availability(macosx,introduced=10.7)));
extern
CFFileSecurityRef CFFileSecurityCreate(CFAllocatorRef allocator) __attribute__((availability(macosx,introduced=10.7)));
extern
CFFileSecurityRef CFFileSecurityCreateCopy(CFAllocatorRef allocator, CFFileSecurityRef fileSec) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecurityCopyOwnerUUID(CFFileSecurityRef fileSec, CFUUIDRef *ownerUUID) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecuritySetOwnerUUID(CFFileSecurityRef fileSec, CFUUIDRef ownerUUID) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecurityCopyGroupUUID(CFFileSecurityRef fileSec, CFUUIDRef *groupUUID) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecuritySetGroupUUID(CFFileSecurityRef fileSec, CFUUIDRef groupUUID) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecurityCopyAccessControlList(CFFileSecurityRef fileSec, acl_t *accessControlList) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecuritySetAccessControlList(CFFileSecurityRef fileSec, acl_t accessControlList) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecurityGetOwner(CFFileSecurityRef fileSec, uid_t *owner) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecuritySetOwner(CFFileSecurityRef fileSec, uid_t owner) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecurityGetGroup(CFFileSecurityRef fileSec, gid_t *group) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecuritySetGroup(CFFileSecurityRef fileSec, gid_t group) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecurityGetMode(CFFileSecurityRef fileSec, mode_t *mode) __attribute__((availability(macosx,introduced=10.7)));
extern
Boolean CFFileSecuritySetMode(CFFileSecurityRef fileSec, mode_t mode) __attribute__((availability(macosx,introduced=10.7)));
typedef CFOptionFlags CFFileSecurityClearOptions; enum {
kCFFileSecurityClearOwner = 1UL << 0,
kCFFileSecurityClearGroup = 1UL << 1,
kCFFileSecurityClearMode = 1UL << 2,
kCFFileSecurityClearOwnerUUID = 1UL << 3,
kCFFileSecurityClearGroupUUID = 1UL << 4,
kCFFileSecurityClearAccessControlList = 1UL << 5
} __attribute__((availability(macosx,introduced=10.8)));
extern
Boolean CFFileSecurityClearProperties(CFFileSecurityRef fileSec, CFFileSecurityClearOptions clearPropertyMask) __attribute__((availability(macosx,introduced=10.8)));
}
extern "C" {
typedef struct __attribute__((objc_bridge_mutable(NSMachPort))) __CFMachPort * CFMachPortRef;
typedef struct {
CFIndex version;
void * info;
const void *(*retain)(const void *info);
void (*release)(const void *info);
CFStringRef (*copyDescription)(const void *info);
} CFMachPortContext;
typedef void (*CFMachPortCallBack)(CFMachPortRef port, void *msg, CFIndex size, void *info);
typedef void (*CFMachPortInvalidationCallBack)(CFMachPortRef port, void *info);
extern CFTypeID CFMachPortGetTypeID(void);
extern CFMachPortRef CFMachPortCreate(CFAllocatorRef allocator, CFMachPortCallBack callout, CFMachPortContext *context, Boolean *shouldFreeInfo);
extern CFMachPortRef CFMachPortCreateWithPort(CFAllocatorRef allocator, mach_port_t portNum, CFMachPortCallBack callout, CFMachPortContext *context, Boolean *shouldFreeInfo);
extern mach_port_t CFMachPortGetPort(CFMachPortRef port);
extern void CFMachPortGetContext(CFMachPortRef port, CFMachPortContext *context);
extern void CFMachPortInvalidate(CFMachPortRef port);
extern Boolean CFMachPortIsValid(CFMachPortRef port);
extern CFMachPortInvalidationCallBack CFMachPortGetInvalidationCallBack(CFMachPortRef port);
extern void CFMachPortSetInvalidationCallBack(CFMachPortRef port, CFMachPortInvalidationCallBack callout);
extern CFRunLoopSourceRef CFMachPortCreateRunLoopSource(CFAllocatorRef allocator, CFMachPortRef port, CFIndex order);
}
extern "C" {
extern
CFStringRef CFStringTokenizerCopyBestStringLanguage(CFStringRef string, CFRange range) __attribute__((availability(macosx,introduced=10.5)));
typedef struct __CFStringTokenizer * CFStringTokenizerRef;
enum {
kCFStringTokenizerUnitWord = 0,
kCFStringTokenizerUnitSentence = 1,
kCFStringTokenizerUnitParagraph = 2,
kCFStringTokenizerUnitLineBreak = 3,
kCFStringTokenizerUnitWordBoundary = 4,
kCFStringTokenizerAttributeLatinTranscription = 1UL << 16,
kCFStringTokenizerAttributeLanguage = 1UL << 17,
};
typedef CFOptionFlags CFStringTokenizerTokenType; enum {
kCFStringTokenizerTokenNone = 0,
kCFStringTokenizerTokenNormal = 1UL << 0,
kCFStringTokenizerTokenHasSubTokensMask = 1UL << 1,
kCFStringTokenizerTokenHasDerivedSubTokensMask = 1UL << 2,
kCFStringTokenizerTokenHasHasNumbersMask = 1UL << 3,
kCFStringTokenizerTokenHasNonLettersMask = 1UL << 4,
kCFStringTokenizerTokenIsCJWordMask = 1UL << 5
};
extern
CFTypeID CFStringTokenizerGetTypeID(void) __attribute__((availability(macosx,introduced=10.5)));
extern
CFStringTokenizerRef CFStringTokenizerCreate(CFAllocatorRef alloc, CFStringRef string, CFRange range, CFOptionFlags options, CFLocaleRef locale) __attribute__((availability(macosx,introduced=10.5)));
extern
void CFStringTokenizerSetString(CFStringTokenizerRef tokenizer, CFStringRef string, CFRange range) __attribute__((availability(macosx,introduced=10.5)));
extern
CFStringTokenizerTokenType CFStringTokenizerGoToTokenAtIndex(CFStringTokenizerRef tokenizer, CFIndex index) __attribute__((availability(macosx,introduced=10.5)));
extern
CFStringTokenizerTokenType CFStringTokenizerAdvanceToNextToken(CFStringTokenizerRef tokenizer) __attribute__((availability(macosx,introduced=10.5)));
extern
CFRange CFStringTokenizerGetCurrentTokenRange(CFStringTokenizerRef tokenizer) __attribute__((availability(macosx,introduced=10.5)));
extern
CFTypeRef CFStringTokenizerCopyCurrentTokenAttribute(CFStringTokenizerRef tokenizer, CFOptionFlags attribute) __attribute__((availability(macosx,introduced=10.5)));
extern
CFIndex CFStringTokenizerGetCurrentSubTokens(CFStringTokenizerRef tokenizer, CFRange *ranges, CFIndex maxRangeLength, CFMutableArrayRef derivedSubTokens) __attribute__((availability(macosx,introduced=10.5)));
}
extern "C" {
typedef int CFFileDescriptorNativeDescriptor;
typedef struct __CFFileDescriptor * CFFileDescriptorRef;
enum {
kCFFileDescriptorReadCallBack = 1UL << 0,
kCFFileDescriptorWriteCallBack = 1UL << 1
};
typedef void (*CFFileDescriptorCallBack)(CFFileDescriptorRef f, CFOptionFlags callBackTypes, void *info);
typedef struct {
CFIndex version;
void * info;
void * (*retain)(void *info);
void (*release)(void *info);
CFStringRef (*copyDescription)(void *info);
} CFFileDescriptorContext;
extern CFTypeID CFFileDescriptorGetTypeID(void) __attribute__((availability(macosx,introduced=10.5)));
extern CFFileDescriptorRef CFFileDescriptorCreate(CFAllocatorRef allocator, CFFileDescriptorNativeDescriptor fd, Boolean closeOnInvalidate, CFFileDescriptorCallBack callout, const CFFileDescriptorContext *context) __attribute__((availability(macosx,introduced=10.5)));
extern CFFileDescriptorNativeDescriptor CFFileDescriptorGetNativeDescriptor(CFFileDescriptorRef f) __attribute__((availability(macosx,introduced=10.5)));
extern void CFFileDescriptorGetContext(CFFileDescriptorRef f, CFFileDescriptorContext *context) __attribute__((availability(macosx,introduced=10.5)));
extern void CFFileDescriptorEnableCallBacks(CFFileDescriptorRef f, CFOptionFlags callBackTypes) __attribute__((availability(macosx,introduced=10.5)));
extern void CFFileDescriptorDisableCallBacks(CFFileDescriptorRef f, CFOptionFlags callBackTypes) __attribute__((availability(macosx,introduced=10.5)));
extern void CFFileDescriptorInvalidate(CFFileDescriptorRef f) __attribute__((availability(macosx,introduced=10.5)));
extern Boolean CFFileDescriptorIsValid(CFFileDescriptorRef f) __attribute__((availability(macosx,introduced=10.5)));
extern CFRunLoopSourceRef CFFileDescriptorCreateRunLoopSource(CFAllocatorRef allocator, CFFileDescriptorRef f, CFIndex order) __attribute__((availability(macosx,introduced=10.5)));
}
extern "C" {
typedef struct __CFUserNotification * CFUserNotificationRef;
typedef void (*CFUserNotificationCallBack)(CFUserNotificationRef userNotification, CFOptionFlags responseFlags);
extern
CFTypeID CFUserNotificationGetTypeID(void);
extern
CFUserNotificationRef CFUserNotificationCreate(CFAllocatorRef allocator, CFTimeInterval timeout, CFOptionFlags flags, SInt32 *error, CFDictionaryRef dictionary);
extern
SInt32 CFUserNotificationReceiveResponse(CFUserNotificationRef userNotification, CFTimeInterval timeout, CFOptionFlags *responseFlags);
extern
CFStringRef CFUserNotificationGetResponseValue(CFUserNotificationRef userNotification, CFStringRef key, CFIndex idx);
extern
CFDictionaryRef CFUserNotificationGetResponseDictionary(CFUserNotificationRef userNotification);
extern
SInt32 CFUserNotificationUpdate(CFUserNotificationRef userNotification, CFTimeInterval timeout, CFOptionFlags flags, CFDictionaryRef dictionary);
extern
SInt32 CFUserNotificationCancel(CFUserNotificationRef userNotification);
extern
CFRunLoopSourceRef CFUserNotificationCreateRunLoopSource(CFAllocatorRef allocator, CFUserNotificationRef userNotification, CFUserNotificationCallBack callout, CFIndex order);
extern
SInt32 CFUserNotificationDisplayNotice(CFTimeInterval timeout, CFOptionFlags flags, CFURLRef iconURL, CFURLRef soundURL, CFURLRef localizationURL, CFStringRef alertHeader, CFStringRef alertMessage, CFStringRef defaultButtonTitle);
extern
SInt32 CFUserNotificationDisplayAlert(CFTimeInterval timeout, CFOptionFlags flags, CFURLRef iconURL, CFURLRef soundURL, CFURLRef localizationURL, CFStringRef alertHeader, CFStringRef alertMessage, CFStringRef defaultButtonTitle, CFStringRef alternateButtonTitle, CFStringRef otherButtonTitle, CFOptionFlags *responseFlags);
enum {
kCFUserNotificationStopAlertLevel = 0,
kCFUserNotificationNoteAlertLevel = 1,
kCFUserNotificationCautionAlertLevel = 2,
kCFUserNotificationPlainAlertLevel = 3
};
enum {
kCFUserNotificationDefaultResponse = 0,
kCFUserNotificationAlternateResponse = 1,
kCFUserNotificationOtherResponse = 2,
kCFUserNotificationCancelResponse = 3
};
enum {
kCFUserNotificationNoDefaultButtonFlag = (1UL << 5),
kCFUserNotificationUseRadioButtonsFlag = (1UL << 6)
};
static __inline__ __attribute__((always_inline)) CFOptionFlags CFUserNotificationCheckBoxChecked(CFIndex i) {return ((CFOptionFlags)(1UL << (8 + i)));}
static __inline__ __attribute__((always_inline)) CFOptionFlags CFUserNotificationSecureTextField(CFIndex i) {return ((CFOptionFlags)(1UL << (16 + i)));}
static __inline__ __attribute__((always_inline)) CFOptionFlags CFUserNotificationPopUpSelection(CFIndex n) {return ((CFOptionFlags)(n << 24));}
extern
const CFStringRef kCFUserNotificationIconURLKey;
extern
const CFStringRef kCFUserNotificationSoundURLKey;
extern
const CFStringRef kCFUserNotificationLocalizationURLKey;
extern
const CFStringRef kCFUserNotificationAlertHeaderKey;
extern
const CFStringRef kCFUserNotificationAlertMessageKey;
extern
const CFStringRef kCFUserNotificationDefaultButtonTitleKey;
extern
const CFStringRef kCFUserNotificationAlternateButtonTitleKey;
extern
const CFStringRef kCFUserNotificationOtherButtonTitleKey;
extern
const CFStringRef kCFUserNotificationProgressIndicatorValueKey;
extern
const CFStringRef kCFUserNotificationPopUpTitlesKey;
extern
const CFStringRef kCFUserNotificationTextFieldTitlesKey;
extern
const CFStringRef kCFUserNotificationCheckBoxTitlesKey;
extern
const CFStringRef kCFUserNotificationTextFieldValuesKey;
extern
const CFStringRef kCFUserNotificationPopUpSelectionKey __attribute__((availability(macosx,introduced=10.3)));
}
extern "C" {
enum {
kCFXMLNodeCurrentVersion = 1
};
typedef const struct __CFXMLNode * CFXMLNodeRef;
typedef CFTreeRef CFXMLTreeRef;
typedef CFIndex CFXMLNodeTypeCode; enum {
kCFXMLNodeTypeDocument = 1,
kCFXMLNodeTypeElement = 2,
kCFXMLNodeTypeAttribute = 3,
kCFXMLNodeTypeProcessingInstruction = 4,
kCFXMLNodeTypeComment = 5,
kCFXMLNodeTypeText = 6,
kCFXMLNodeTypeCDATASection = 7,
kCFXMLNodeTypeDocumentFragment = 8,
kCFXMLNodeTypeEntity = 9,
kCFXMLNodeTypeEntityReference = 10,
kCFXMLNodeTypeDocumentType = 11,
kCFXMLNodeTypeWhitespace = 12,
kCFXMLNodeTypeNotation = 13,
kCFXMLNodeTypeElementTypeDeclaration = 14,
kCFXMLNodeTypeAttributeListDeclaration = 15
};
typedef struct {
CFDictionaryRef attributes;
CFArrayRef attributeOrder;
Boolean isEmpty;
char _reserved[3];
} CFXMLElementInfo;
typedef struct {
CFStringRef dataString;
} CFXMLProcessingInstructionInfo;
typedef struct {
CFURLRef sourceURL;
CFStringEncoding encoding;
} CFXMLDocumentInfo;
typedef struct {
CFURLRef systemID;
CFStringRef publicID;
} CFXMLExternalID;
typedef struct {
CFXMLExternalID externalID;
} CFXMLDocumentTypeInfo;
typedef struct {
CFXMLExternalID externalID;
} CFXMLNotationInfo;
typedef struct {
CFStringRef contentDescription;
} CFXMLElementTypeDeclarationInfo;
typedef struct {
CFStringRef attributeName;
CFStringRef typeString;
CFStringRef defaultString;
} CFXMLAttributeDeclarationInfo;
typedef struct {
CFIndex numberOfAttributes;
CFXMLAttributeDeclarationInfo *attributes;
} CFXMLAttributeListDeclarationInfo;
typedef CFIndex CFXMLEntityTypeCode; enum {
kCFXMLEntityTypeParameter,
kCFXMLEntityTypeParsedInternal,
kCFXMLEntityTypeParsedExternal,
kCFXMLEntityTypeUnparsed,
kCFXMLEntityTypeCharacter
};
typedef struct {
CFXMLEntityTypeCode entityType;
CFStringRef replacementText;
CFXMLExternalID entityID;
CFStringRef notationName;
} CFXMLEntityInfo;
typedef struct {
CFXMLEntityTypeCode entityType;
} CFXMLEntityReferenceInfo;
extern
CFTypeID CFXMLNodeGetTypeID(void) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFXMLNodeRef CFXMLNodeCreate(CFAllocatorRef alloc, CFXMLNodeTypeCode xmlType, CFStringRef dataString, const void *additionalInfoPtr, CFIndex version) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFXMLNodeRef CFXMLNodeCreateCopy(CFAllocatorRef alloc, CFXMLNodeRef origNode) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFXMLNodeTypeCode CFXMLNodeGetTypeCode(CFXMLNodeRef node) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFStringRef CFXMLNodeGetString(CFXMLNodeRef node) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
const void *CFXMLNodeGetInfoPtr(CFXMLNodeRef node) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFIndex CFXMLNodeGetVersion(CFXMLNodeRef node) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFXMLTreeRef CFXMLTreeCreateWithNode(CFAllocatorRef allocator, CFXMLNodeRef node) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFXMLNodeRef CFXMLTreeGetNode(CFXMLTreeRef xmlTree) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
}
extern "C" {
typedef struct __CFXMLParser * CFXMLParserRef;
typedef CFOptionFlags CFXMLParserOptions; enum {
kCFXMLParserValidateDocument = (1UL << 0),
kCFXMLParserSkipMetaData = (1UL << 1),
kCFXMLParserReplacePhysicalEntities = (1UL << 2),
kCFXMLParserSkipWhitespace = (1UL << 3),
kCFXMLParserResolveExternalEntities = (1UL << 4),
kCFXMLParserAddImpliedAttributes = (1UL << 5),
kCFXMLParserAllOptions = 0x00FFFFFF,
kCFXMLParserNoOptions = 0
};
typedef CFIndex CFXMLParserStatusCode; enum {
kCFXMLStatusParseNotBegun = -2,
kCFXMLStatusParseInProgress = -1,
kCFXMLStatusParseSuccessful = 0,
kCFXMLErrorUnexpectedEOF = 1,
kCFXMLErrorUnknownEncoding,
kCFXMLErrorEncodingConversionFailure,
kCFXMLErrorMalformedProcessingInstruction,
kCFXMLErrorMalformedDTD,
kCFXMLErrorMalformedName,
kCFXMLErrorMalformedCDSect,
kCFXMLErrorMalformedCloseTag,
kCFXMLErrorMalformedStartTag,
kCFXMLErrorMalformedDocument,
kCFXMLErrorElementlessDocument,
kCFXMLErrorMalformedComment,
kCFXMLErrorMalformedCharacterReference,
kCFXMLErrorMalformedParsedCharacterData,
kCFXMLErrorNoData
};
typedef void * (*CFXMLParserCreateXMLStructureCallBack)(CFXMLParserRef parser, CFXMLNodeRef nodeDesc, void *info);
typedef void (*CFXMLParserAddChildCallBack)(CFXMLParserRef parser, void *parent, void *child, void *info);
typedef void (*CFXMLParserEndXMLStructureCallBack)(CFXMLParserRef parser, void *xmlType, void *info);
typedef CFDataRef (*CFXMLParserResolveExternalEntityCallBack)(CFXMLParserRef parser, CFXMLExternalID *extID, void *info);
typedef Boolean (*CFXMLParserHandleErrorCallBack)(CFXMLParserRef parser, CFXMLParserStatusCode error, void *info);
typedef struct {
CFIndex version;
CFXMLParserCreateXMLStructureCallBack createXMLStructure;
CFXMLParserAddChildCallBack addChild;
CFXMLParserEndXMLStructureCallBack endXMLStructure;
CFXMLParserResolveExternalEntityCallBack resolveExternalEntity;
CFXMLParserHandleErrorCallBack handleError;
} CFXMLParserCallBacks;
typedef const void * (*CFXMLParserRetainCallBack)(const void *info);
typedef void (*CFXMLParserReleaseCallBack)(const void *info);
typedef CFStringRef (*CFXMLParserCopyDescriptionCallBack)(const void *info);
typedef struct {
CFIndex version;
void * info;
CFXMLParserRetainCallBack retain;
CFXMLParserReleaseCallBack release;
CFXMLParserCopyDescriptionCallBack copyDescription;
} CFXMLParserContext;
extern
CFTypeID CFXMLParserGetTypeID(void) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFXMLParserRef CFXMLParserCreate(CFAllocatorRef allocator, CFDataRef xmlData, CFURLRef dataSource, CFOptionFlags parseOptions, CFIndex versionOfNodes, CFXMLParserCallBacks *callBacks, CFXMLParserContext *context) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFXMLParserRef CFXMLParserCreateWithDataFromURL(CFAllocatorRef allocator, CFURLRef dataSource, CFOptionFlags parseOptions, CFIndex versionOfNodes, CFXMLParserCallBacks *callBacks, CFXMLParserContext *context) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
void CFXMLParserGetContext(CFXMLParserRef parser, CFXMLParserContext *context) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
void CFXMLParserGetCallBacks(CFXMLParserRef parser, CFXMLParserCallBacks *callBacks) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFURLRef CFXMLParserGetSourceURL(CFXMLParserRef parser) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFIndex CFXMLParserGetLocation(CFXMLParserRef parser) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFIndex CFXMLParserGetLineNumber(CFXMLParserRef parser) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
void *CFXMLParserGetDocument(CFXMLParserRef parser) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFXMLParserStatusCode CFXMLParserGetStatusCode(CFXMLParserRef parser) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFStringRef CFXMLParserCopyErrorDescription(CFXMLParserRef parser) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
void CFXMLParserAbort(CFXMLParserRef parser, CFXMLParserStatusCode errorCode, CFStringRef errorDescription) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
Boolean CFXMLParserParse(CFXMLParserRef parser) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFXMLTreeRef CFXMLTreeCreateFromData(CFAllocatorRef allocator, CFDataRef xmlData, CFURLRef dataSource, CFOptionFlags parseOptions, CFIndex versionOfNodes) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFXMLTreeRef CFXMLTreeCreateFromDataWithError(CFAllocatorRef allocator, CFDataRef xmlData, CFURLRef dataSource, CFOptionFlags parseOptions, CFIndex versionOfNodes, CFDictionaryRef *errorDict) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFXMLTreeRef CFXMLTreeCreateWithDataFromURL(CFAllocatorRef allocator, CFURLRef dataSource, CFOptionFlags parseOptions, CFIndex versionOfNodes) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFDataRef CFXMLTreeCreateXMLData(CFAllocatorRef allocator, CFXMLTreeRef xmlTree) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern
CFStringRef CFXMLCreateStringByEscapingEntities(CFAllocatorRef allocator, CFStringRef string, CFDictionaryRef entitiesDictionary);
extern
CFStringRef CFXMLCreateStringByUnescapingEntities(CFAllocatorRef allocator, CFStringRef string, CFDictionaryRef entitiesDictionary);
extern const CFStringRef kCFXMLTreeErrorDescription;
extern const CFStringRef kCFXMLTreeErrorLineNumber;
extern const CFStringRef kCFXMLTreeErrorLocation;
extern const CFStringRef kCFXMLTreeErrorStatusCode;
}
extern "C" double NSFoundationVersionNumber;
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_Protocol
#define _REWRITER_typedef_Protocol
typedef struct objc_object Protocol;
typedef struct {} _objc_exc_Protocol;
#endif
extern "C" NSString *NSStringFromSelector(SEL aSelector);
extern "C" SEL NSSelectorFromString(NSString *aSelectorName);
extern "C" NSString *NSStringFromClass(Class aClass);
extern "C" Class NSClassFromString(NSString *aClassName);
extern "C" NSString *NSStringFromProtocol(Protocol *proto) __attribute__((availability(macosx,introduced=10.5)));
extern "C" Protocol *NSProtocolFromString(NSString *namestr) __attribute__((availability(macosx,introduced=10.5)));
extern "C" const char *NSGetSizeAndAlignment(const char *typePtr, NSUInteger *sizep, NSUInteger *alignp);
extern "C" void NSLog(NSString *format, ...) __attribute__((format(__NSString__, 1, 2)));
extern "C" void NSLogv(NSString *format, va_list args) __attribute__((format(__NSString__, 1, 0)));
typedef NSInteger NSComparisonResult; enum {NSOrderedAscending = -1L, NSOrderedSame, NSOrderedDescending};
typedef NSComparisonResult (*NSComparator)(id obj1, id obj2);
typedef NSUInteger NSEnumerationOptions; enum {
NSEnumerationConcurrent = (1UL << 0),
NSEnumerationReverse = (1UL << 1),
};
typedef NSUInteger NSSortOptions; enum {
NSSortConcurrent = (1UL << 0),
NSSortStable = (1UL << 4),
};
typedef NSInteger NSQualityOfService; enum {
NSQualityOfServiceUserInteractive = 0x21,
NSQualityOfServiceUserInitiated = 0x19,
NSQualityOfServiceUtility = 0x11,
NSQualityOfServiceBackground = 0x09,
NSQualityOfServiceDefault = -1
} __attribute__((availability(macosx,introduced=10.10)));
enum {NSNotFound = 9223372036854775807L};
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
typedef struct _NSZone NSZone;
extern "C" NSZone *NSDefaultMallocZone(void);
extern "C" NSZone *NSCreateZone(NSUInteger startSize, NSUInteger granularity, BOOL canFree);
extern "C" void NSRecycleZone(NSZone *zone);
extern "C" void NSSetZoneName(NSZone *zone, NSString *name);
extern "C" NSString *NSZoneName(NSZone *zone);
extern "C" NSZone *NSZoneFromPointer(void *ptr);
extern "C" void *NSZoneMalloc(NSZone *zone, NSUInteger size);
extern "C" void *NSZoneCalloc(NSZone *zone, NSUInteger numElems, NSUInteger byteSize);
extern "C" void *NSZoneRealloc(NSZone *zone, void *ptr, NSUInteger size);
extern "C" void NSZoneFree(NSZone *zone, void *ptr);
enum {
NSScannedOption = (1UL << 0),
NSCollectorDisabledOption = (1UL << 1),
};
extern "C" void * NSAllocateCollectable(NSUInteger size, NSUInteger options);
extern "C" void * NSReallocateCollectable(void *ptr, NSUInteger size, NSUInteger options);
static __inline__ __attribute__((always_inline)) __attribute__((ns_returns_retained)) id NSMakeCollectable(CFTypeRef __attribute__((cf_consumed)) cf) ;
static __inline__ __attribute__((always_inline)) __attribute__((ns_returns_retained)) id NSMakeCollectable(CFTypeRef __attribute__((cf_consumed)) cf) {
return (cf ? (id)CFMakeCollectable(cf) : __null);
}
extern "C" NSUInteger NSPageSize(void);
extern "C" NSUInteger NSLogPageSize(void);
extern "C" NSUInteger NSRoundUpToMultipleOfPageSize(NSUInteger bytes);
extern "C" NSUInteger NSRoundDownToMultipleOfPageSize(NSUInteger bytes);
extern "C" void *NSAllocateMemoryPages(NSUInteger bytes);
extern "C" void NSDeallocateMemoryPages(void *ptr, NSUInteger bytes);
extern "C" void NSCopyMemoryPages(const void *source, void *dest, NSUInteger bytes);
extern "C" NSUInteger NSRealMemoryAvailable(void) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
// @class NSInvocation;
#ifndef _REWRITER_typedef_NSInvocation
#define _REWRITER_typedef_NSInvocation
typedef struct objc_object NSInvocation;
typedef struct {} _objc_exc_NSInvocation;
#endif
#ifndef _REWRITER_typedef_NSMethodSignature
#define _REWRITER_typedef_NSMethodSignature
typedef struct objc_object NSMethodSignature;
typedef struct {} _objc_exc_NSMethodSignature;
#endif
#ifndef _REWRITER_typedef_NSCoder
#define _REWRITER_typedef_NSCoder
typedef struct objc_object NSCoder;
typedef struct {} _objc_exc_NSCoder;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSEnumerator
#define _REWRITER_typedef_NSEnumerator
typedef struct objc_object NSEnumerator;
typedef struct {} _objc_exc_NSEnumerator;
#endif
// @class Protocol;
#ifndef _REWRITER_typedef_Protocol
#define _REWRITER_typedef_Protocol
typedef struct objc_object Protocol;
typedef struct {} _objc_exc_Protocol;
#endif
// @protocol NSCopying
// - (id)copyWithZone:(NSZone *)zone;
/* @end */
// @protocol NSMutableCopying
// - (id)mutableCopyWithZone:(NSZone *)zone;
/* @end */
// @protocol NSCoding
// - (void)encodeWithCoder:(NSCoder *)aCoder;
// - (id)initWithCoder:(NSCoder *)aDecoder;
/* @end */
// @protocol NSSecureCoding <NSCoding>
/* @required */
// + (BOOL)supportsSecureCoding;
/* @end */
// @interface NSObject (NSCoderMethods)
// + (NSInteger)version;
// + (void)setVersion:(NSInteger)aVersion;
// @property (readonly) Class classForCoder;
// - (id)replacementObjectForCoder:(NSCoder *)aCoder;
// - (id)awakeAfterUsingCoder:(NSCoder *)aDecoder __attribute__((ns_consumes_self)) __attribute__((ns_returns_retained));
/* @end */
// @interface NSObject (NSDeprecatedMethods)
#if 0
+ (void)poseAsClass:(Class)aClass __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )))
__attribute__((unavailable))
;
#endif
/* @end */
// @protocol NSDiscardableContent
/* @required */
// - (BOOL)beginContentAccess;
// - (void)endContentAccess;
// - (void)discardContentIfPossible;
// - (BOOL)isContentDiscarded;
/* @end */
// @interface NSObject (NSDiscardableContentProxy)
// @property (readonly, retain) id autoContentAccessingProxy __attribute__((availability(macosx,introduced=10.6)));
/* @end */
extern "C" id NSAllocateObject(Class aClass, NSUInteger extraBytes, NSZone *zone) ;
extern "C" void NSDeallocateObject(id object) ;
extern "C" id NSCopyObject(id object, NSUInteger extraBytes, NSZone *zone) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.8,message="" )));
extern "C" BOOL NSShouldRetainWithZone(id anObject, NSZone *requestedZone) ;
extern "C" void NSIncrementExtraRefCount(id object) ;
extern "C" BOOL NSDecrementExtraRefCountWasZero(id object) ;
extern "C" NSUInteger NSExtraRefCount(id object) ;
static __inline__ __attribute__((always_inline)) __attribute__((cf_returns_retained)) CFTypeRef CFBridgingRetain(id X) {
return X ? CFRetain((CFTypeRef)X) : __null;
}
static __inline__ __attribute__((always_inline)) id CFBridgingRelease(CFTypeRef __attribute__((cf_consumed)) X) {
return ((id (*)(id, SEL))(void *)objc_msgSend)((id)CFMakeCollectable(X), sel_registerName("autorelease"));
}
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
typedef struct {
unsigned long state;
id *itemsPtr;
unsigned long *mutationsPtr;
unsigned long extra[5];
} NSFastEnumerationState;
// @protocol NSFastEnumeration
// - (NSUInteger)countByEnumeratingWithState:(NSFastEnumerationState *)state objects:(id [])buffer count:(NSUInteger)len;
/* @end */
#ifndef _REWRITER_typedef_NSEnumerator
#define _REWRITER_typedef_NSEnumerator
typedef struct objc_object NSEnumerator;
typedef struct {} _objc_exc_NSEnumerator;
#endif
struct NSEnumerator_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (id)nextObject;
/* @end */
// @interface NSEnumerator (NSExtendedEnumerator)
// @property (readonly, copy) NSArray *allObjects;
/* @end */
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSValue
#define _REWRITER_typedef_NSValue
typedef struct objc_object NSValue;
typedef struct {} _objc_exc_NSValue;
#endif
struct NSValue_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (void)getValue:(void *)value;
// @property (readonly) const char *objCType __attribute__((objc_returns_inner_pointer));
// - (instancetype)initWithBytes:(const void *)value objCType:(const char *)type __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSValue (NSValueCreation)
// + (NSValue *)valueWithBytes:(const void *)value objCType:(const char *)type;
// + (NSValue *)value:(const void *)value withObjCType:(const char *)type;
/* @end */
// @interface NSValue (NSValueExtensionMethods)
// + (NSValue *)valueWithNonretainedObject:(id)anObject;
// @property (nonatomic, readonly) id nonretainedObjectValue;
// + (NSValue *)valueWithPointer:(const void *)pointer;
// - (void *)pointerValue;
// - (BOOL)isEqualToValue:(NSValue *)value;
/* @end */
#ifndef _REWRITER_typedef_NSNumber
#define _REWRITER_typedef_NSNumber
typedef struct objc_object NSNumber;
typedef struct {} _objc_exc_NSNumber;
#endif
struct NSNumber_IMPL {
struct NSValue_IMPL NSValue_IVARS;
};
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithChar:(char)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithUnsignedChar:(unsigned char)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithShort:(short)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithUnsignedShort:(unsigned short)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithInt:(int)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithUnsignedInt:(unsigned int)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithLong:(long)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithUnsignedLong:(unsigned long)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithLongLong:(long long)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithUnsignedLongLong:(unsigned long long)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithFloat:(float)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithDouble:(double)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithBool:(BOOL)value __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithInteger:(NSInteger)value __attribute__((availability(macosx,introduced=10.5))) __attribute__((objc_designated_initializer));
// - (NSNumber *)initWithUnsignedInteger:(NSUInteger)value __attribute__((availability(macosx,introduced=10.5))) __attribute__((objc_designated_initializer));
// @property (readonly) char charValue;
// @property (readonly) unsigned char unsignedCharValue;
// @property (readonly) short shortValue;
// @property (readonly) unsigned short unsignedShortValue;
// @property (readonly) int intValue;
// @property (readonly) unsigned int unsignedIntValue;
// @property (readonly) long longValue;
// @property (readonly) unsigned long unsignedLongValue;
// @property (readonly) long long longLongValue;
// @property (readonly) unsigned long long unsignedLongLongValue;
// @property (readonly) float floatValue;
// @property (readonly) double doubleValue;
// @property (readonly) BOOL boolValue;
// @property (readonly) NSInteger integerValue __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly) NSUInteger unsignedIntegerValue __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly, copy) NSString *stringValue;
// - (NSComparisonResult)compare:(NSNumber *)otherNumber;
// - (BOOL)isEqualToNumber:(NSNumber *)number;
// - (NSString *)descriptionWithLocale:(id)locale;
/* @end */
// @interface NSNumber (NSNumberCreation)
// + (NSNumber *)numberWithChar:(char)value;
// + (NSNumber *)numberWithUnsignedChar:(unsigned char)value;
// + (NSNumber *)numberWithShort:(short)value;
// + (NSNumber *)numberWithUnsignedShort:(unsigned short)value;
// + (NSNumber *)numberWithInt:(int)value;
// + (NSNumber *)numberWithUnsignedInt:(unsigned int)value;
// + (NSNumber *)numberWithLong:(long)value;
// + (NSNumber *)numberWithUnsignedLong:(unsigned long)value;
// + (NSNumber *)numberWithLongLong:(long long)value;
// + (NSNumber *)numberWithUnsignedLongLong:(unsigned long long)value;
// + (NSNumber *)numberWithFloat:(float)value;
// + (NSNumber *)numberWithDouble:(double)value;
// + (NSNumber *)numberWithBool:(BOOL)value;
// + (NSNumber *)numberWithInteger:(NSInteger)value __attribute__((availability(macosx,introduced=10.5)));
// + (NSNumber *)numberWithUnsignedInteger:(NSUInteger)value __attribute__((availability(macosx,introduced=10.5)));
/* @end */
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
typedef struct _NSRange {
NSUInteger location;
NSUInteger length;
} NSRange;
typedef NSRange *NSRangePointer;
static __inline__ __attribute__((always_inline)) NSRange NSMakeRange(NSUInteger loc, NSUInteger len) {
NSRange r;
r.location = loc;
r.length = len;
return r;
}
static __inline__ __attribute__((always_inline)) NSUInteger NSMaxRange(NSRange range) {
return (range.location + range.length);
}
static __inline__ __attribute__((always_inline)) BOOL NSLocationInRange(NSUInteger loc, NSRange range) {
return (!(loc < range.location) && (loc - range.location) < range.length) ? ((bool)1) : ((bool)0);
}
static __inline__ __attribute__((always_inline)) BOOL NSEqualRanges(NSRange range1, NSRange range2) {
return (range1.location == range2.location && range1.length == range2.length);
}
extern "C" NSRange NSUnionRange(NSRange range1, NSRange range2);
extern "C" NSRange NSIntersectionRange(NSRange range1, NSRange range2);
extern "C" NSString *NSStringFromRange(NSRange range);
extern "C" NSRange NSRangeFromString(NSString *aString);
// @interface NSValue (NSValueRangeExtensions)
// + (NSValue *)valueWithRange:(NSRange)range;
// @property (readonly) NSRange rangeValue;
/* @end */
// @class NSData;
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
#ifndef _REWRITER_typedef_NSIndexSet
#define _REWRITER_typedef_NSIndexSet
typedef struct objc_object NSIndexSet;
typedef struct {} _objc_exc_NSIndexSet;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
struct NSArray_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly) NSUInteger count;
// - (id)objectAtIndex:(NSUInteger)index;
// - (instancetype)init __attribute__((objc_designated_initializer));
// - (instancetype)initWithObjects:(const id [])objects count:(NSUInteger)cnt __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSArray (NSExtendedArray)
// - (NSArray *)arrayByAddingObject:(id)anObject;
// - (NSArray *)arrayByAddingObjectsFromArray:(NSArray *)otherArray;
// - (NSString *)componentsJoinedByString:(NSString *)separator;
// - (BOOL)containsObject:(id)anObject;
// @property (readonly, copy) NSString *description;
// - (NSString *)descriptionWithLocale:(id)locale;
// - (NSString *)descriptionWithLocale:(id)locale indent:(NSUInteger)level;
// - (id)firstObjectCommonWithArray:(NSArray *)otherArray;
// - (void)getObjects:(id [])objects range:(NSRange)range;
// - (NSUInteger)indexOfObject:(id)anObject;
// - (NSUInteger)indexOfObject:(id)anObject inRange:(NSRange)range;
// - (NSUInteger)indexOfObjectIdenticalTo:(id)anObject;
// - (NSUInteger)indexOfObjectIdenticalTo:(id)anObject inRange:(NSRange)range;
// - (BOOL)isEqualToArray:(NSArray *)otherArray;
// @property (nonatomic, readonly) id firstObject __attribute__((availability(macosx,introduced=10.6)));
// @property (nonatomic, readonly) id lastObject;
// - (NSEnumerator *)objectEnumerator;
// - (NSEnumerator *)reverseObjectEnumerator;
// @property (readonly, copy) NSData *sortedArrayHint;
// - (NSArray *)sortedArrayUsingFunction:(NSInteger (*)(id, id, void *))comparator context:(void *)context;
// - (NSArray *)sortedArrayUsingFunction:(NSInteger (*)(id, id, void *))comparator context:(void *)context hint:(NSData *)hint;
// - (NSArray *)sortedArrayUsingSelector:(SEL)comparator;
// - (NSArray *)subarrayWithRange:(NSRange)range;
// - (BOOL)writeToFile:(NSString *)path atomically:(BOOL)useAuxiliaryFile;
// - (BOOL)writeToURL:(NSURL *)url atomically:(BOOL)atomically;
// - (void)makeObjectsPerformSelector:(SEL)aSelector;
// - (void)makeObjectsPerformSelector:(SEL)aSelector withObject:(id)argument;
// - (NSArray *)objectsAtIndexes:(NSIndexSet *)indexes;
// - (id)objectAtIndexedSubscript:(NSUInteger)idx __attribute__((availability(macosx,introduced=10.8)));
// - (void)enumerateObjectsUsingBlock:(void (^)(id obj, NSUInteger idx, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// - (void)enumerateObjectsWithOptions:(NSEnumerationOptions)opts usingBlock:(void (^)(id obj, NSUInteger idx, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// - (void)enumerateObjectsAtIndexes:(NSIndexSet *)s options:(NSEnumerationOptions)opts usingBlock:(void (^)(id obj, NSUInteger idx, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// - (NSUInteger)indexOfObjectPassingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSUInteger)indexOfObjectWithOptions:(NSEnumerationOptions)opts passingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSUInteger)indexOfObjectAtIndexes:(NSIndexSet *)s options:(NSEnumerationOptions)opts passingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSIndexSet *)indexesOfObjectsPassingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSIndexSet *)indexesOfObjectsWithOptions:(NSEnumerationOptions)opts passingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSIndexSet *)indexesOfObjectsAtIndexes:(NSIndexSet *)s options:(NSEnumerationOptions)opts passingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSArray *)sortedArrayUsingComparator:(NSComparator)cmptr __attribute__((availability(macosx,introduced=10.6)));
// - (NSArray *)sortedArrayWithOptions:(NSSortOptions)opts usingComparator:(NSComparator)cmptr __attribute__((availability(macosx,introduced=10.6)));
typedef NSUInteger NSBinarySearchingOptions; enum {
NSBinarySearchingFirstEqual = (1UL << 8),
NSBinarySearchingLastEqual = (1UL << 9),
NSBinarySearchingInsertionIndex = (1UL << 10),
};
// - (NSUInteger)indexOfObject:(id)obj inSortedRange:(NSRange)r options:(NSBinarySearchingOptions)opts usingComparator:(NSComparator)cmp __attribute__((availability(macosx,introduced=10.6)));
/* @end */
// @interface NSArray (NSArrayCreation)
// + (instancetype)array;
// + (instancetype)arrayWithObject:(id)anObject;
// + (instancetype)arrayWithObjects:(const id [])objects count:(NSUInteger)cnt;
// + (instancetype)arrayWithObjects:(id)firstObj, ... __attribute__((sentinel(0,1)));
// + (instancetype)arrayWithArray:(NSArray *)array;
// - (instancetype)initWithObjects:(id)firstObj, ... __attribute__((sentinel(0,1)));
// - (instancetype)initWithArray:(NSArray *)array;
// - (instancetype)initWithArray:(NSArray *)array copyItems:(BOOL)flag;
// + (NSArray *)arrayWithContentsOfFile:(NSString *)path;
// + (NSArray *)arrayWithContentsOfURL:(NSURL *)url;
// - (NSArray *)initWithContentsOfFile:(NSString *)path;
// - (NSArray *)initWithContentsOfURL:(NSURL *)url;
/* @end */
// @interface NSArray (NSDeprecated)
// - (void)getObjects:(id [])objects;
/* @end */
#ifndef _REWRITER_typedef_NSMutableArray
#define _REWRITER_typedef_NSMutableArray
typedef struct objc_object NSMutableArray;
typedef struct {} _objc_exc_NSMutableArray;
#endif
struct NSMutableArray_IMPL {
struct NSArray_IMPL NSArray_IVARS;
};
// - (void)addObject:(id)anObject;
// - (void)insertObject:(id)anObject atIndex:(NSUInteger)index;
// - (void)removeLastObject;
// - (void)removeObjectAtIndex:(NSUInteger)index;
// - (void)replaceObjectAtIndex:(NSUInteger)index withObject:(id)anObject;
// - (instancetype)init __attribute__((objc_designated_initializer));
// - (instancetype)initWithCapacity:(NSUInteger)numItems __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSMutableArray (NSExtendedMutableArray)
// - (void)addObjectsFromArray:(NSArray *)otherArray;
// - (void)exchangeObjectAtIndex:(NSUInteger)idx1 withObjectAtIndex:(NSUInteger)idx2;
// - (void)removeAllObjects;
// - (void)removeObject:(id)anObject inRange:(NSRange)range;
// - (void)removeObject:(id)anObject;
// - (void)removeObjectIdenticalTo:(id)anObject inRange:(NSRange)range;
// - (void)removeObjectIdenticalTo:(id)anObject;
// - (void)removeObjectsFromIndices:(NSUInteger *)indices numIndices:(NSUInteger)cnt __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.6,message="" )));
// - (void)removeObjectsInArray:(NSArray *)otherArray;
// - (void)removeObjectsInRange:(NSRange)range;
// - (void)replaceObjectsInRange:(NSRange)range withObjectsFromArray:(NSArray *)otherArray range:(NSRange)otherRange;
// - (void)replaceObjectsInRange:(NSRange)range withObjectsFromArray:(NSArray *)otherArray;
// - (void)setArray:(NSArray *)otherArray;
// - (void)sortUsingFunction:(NSInteger (*)(id, id, void *))compare context:(void *)context;
// - (void)sortUsingSelector:(SEL)comparator;
// - (void)insertObjects:(NSArray *)objects atIndexes:(NSIndexSet *)indexes;
// - (void)removeObjectsAtIndexes:(NSIndexSet *)indexes;
// - (void)replaceObjectsAtIndexes:(NSIndexSet *)indexes withObjects:(NSArray *)objects;
// - (void)setObject:(id)obj atIndexedSubscript:(NSUInteger)idx __attribute__((availability(macosx,introduced=10.8)));
// - (void)sortUsingComparator:(NSComparator)cmptr __attribute__((availability(macosx,introduced=10.6)));
// - (void)sortWithOptions:(NSSortOptions)opts usingComparator:(NSComparator)cmptr __attribute__((availability(macosx,introduced=10.6)));
/* @end */
// @interface NSMutableArray (NSMutableArrayCreation)
// + (instancetype)arrayWithCapacity:(NSUInteger)numItems;
// + (NSMutableArray *)arrayWithContentsOfFile:(NSString *)path;
// + (NSMutableArray *)arrayWithContentsOfURL:(NSURL *)url;
// - (NSMutableArray *)initWithContentsOfFile:(NSString *)path;
// - (NSMutableArray *)initWithContentsOfURL:(NSURL *)url;
/* @end */
#ifndef _REWRITER_typedef_NSAutoreleasePool
#define _REWRITER_typedef_NSAutoreleasePool
typedef struct objc_object NSAutoreleasePool;
typedef struct {} _objc_exc_NSAutoreleasePool;
#endif
struct NSAutoreleasePool_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *_token;
void *_reserved3;
void *_reserved2;
void *_reserved;
};
// + (void)addObject:(id)anObject;
// - (void)addObject:(id)anObject;
// - (void)drain;
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
#ifndef _REWRITER_typedef_NSBundle
#define _REWRITER_typedef_NSBundle
typedef struct objc_object NSBundle;
typedef struct {} _objc_exc_NSBundle;
#endif
struct NSBundle_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSUInteger _flags;
id _cfBundle;
NSUInteger _reserved2;
Class _principalClass;
id _initialPath;
id _resolvedPath;
id _reserved3;
id _lock;
};
// + (NSBundle *)mainBundle;
// + (instancetype)bundleWithPath:(NSString *)path;
// - (instancetype)initWithPath:(NSString *)path __attribute__((objc_designated_initializer));
// + (instancetype)bundleWithURL:(NSURL *)url __attribute__((availability(macosx,introduced=10.6)));
// - (instancetype)initWithURL:(NSURL *)url __attribute__((availability(macosx,introduced=10.6)));
// + (NSBundle *)bundleForClass:(Class)aClass;
// + (NSBundle *)bundleWithIdentifier:(NSString *)identifier;
// + (NSArray *)allBundles;
// + (NSArray *)allFrameworks;
// - (BOOL)load;
// @property (readonly, getter=isLoaded) BOOL loaded;
// - (BOOL)unload;
// - (BOOL)preflightAndReturnError:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)loadAndReturnError:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly, copy) NSURL *bundleURL __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSURL *resourceURL __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSURL *executableURL __attribute__((availability(macosx,introduced=10.6)));
// - (NSURL *)URLForAuxiliaryExecutable:(NSString *)executableName __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSURL *privateFrameworksURL __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSURL *sharedFrameworksURL __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSURL *sharedSupportURL __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSURL *builtInPlugInsURL __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSURL *appStoreReceiptURL __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSString *bundlePath;
// @property (readonly, copy) NSString *resourcePath;
// @property (readonly, copy) NSString *executablePath;
// - (NSString *)pathForAuxiliaryExecutable:(NSString *)executableName;
// @property (readonly, copy) NSString *privateFrameworksPath;
// @property (readonly, copy) NSString *sharedFrameworksPath;
// @property (readonly, copy) NSString *sharedSupportPath;
// @property (readonly, copy) NSString *builtInPlugInsPath;
// + (NSURL *)URLForResource:(NSString *)name withExtension:(NSString *)ext subdirectory:(NSString *)subpath inBundleWithURL:(NSURL *)bundleURL __attribute__((availability(macosx,introduced=10.6)));
// + (NSArray *)URLsForResourcesWithExtension:(NSString *)ext subdirectory:(NSString *)subpath inBundleWithURL:(NSURL *)bundleURL __attribute__((availability(macosx,introduced=10.6)));
// - (NSURL *)URLForResource:(NSString *)name withExtension:(NSString *)ext __attribute__((availability(macosx,introduced=10.6)));
// - (NSURL *)URLForResource:(NSString *)name withExtension:(NSString *)ext subdirectory:(NSString *)subpath __attribute__((availability(macosx,introduced=10.6)));
// - (NSURL *)URLForResource:(NSString *)name withExtension:(NSString *)ext subdirectory:(NSString *)subpath localization:(NSString *)localizationName __attribute__((availability(macosx,introduced=10.6)));
// - (NSArray *)URLsForResourcesWithExtension:(NSString *)ext subdirectory:(NSString *)subpath __attribute__((availability(macosx,introduced=10.6)));
// - (NSArray *)URLsForResourcesWithExtension:(NSString *)ext subdirectory:(NSString *)subpath localization:(NSString *)localizationName __attribute__((availability(macosx,introduced=10.6)));
// + (NSString *)pathForResource:(NSString *)name ofType:(NSString *)ext inDirectory:(NSString *)bundlePath;
// + (NSArray *)pathsForResourcesOfType:(NSString *)ext inDirectory:(NSString *)bundlePath;
// - (NSString *)pathForResource:(NSString *)name ofType:(NSString *)ext;
// - (NSString *)pathForResource:(NSString *)name ofType:(NSString *)ext inDirectory:(NSString *)subpath;
// - (NSString *)pathForResource:(NSString *)name ofType:(NSString *)ext inDirectory:(NSString *)subpath forLocalization:(NSString *)localizationName;
// - (NSArray *)pathsForResourcesOfType:(NSString *)ext inDirectory:(NSString *)subpath;
// - (NSArray *)pathsForResourcesOfType:(NSString *)ext inDirectory:(NSString *)subpath forLocalization:(NSString *)localizationName;
// - (NSString *)localizedStringForKey:(NSString *)key value:(NSString *)value table:(NSString *)tableName __attribute__ ((format_arg(1)));
// @property (readonly, copy) NSString *bundleIdentifier;
// @property (readonly, copy) NSDictionary *infoDictionary;
// @property (readonly, copy) NSDictionary *localizedInfoDictionary;
// - (id)objectForInfoDictionaryKey:(NSString *)key;
// - (Class)classNamed:(NSString *)className;
// @property (readonly) Class principalClass;
// @property (readonly, copy) NSArray *preferredLocalizations;
// @property (readonly, copy) NSArray *localizations;
// @property (readonly, copy) NSString *developmentLocalization;
// + (NSArray *)preferredLocalizationsFromArray:(NSArray *)localizationsArray;
// + (NSArray *)preferredLocalizationsFromArray:(NSArray *)localizationsArray forPreferences:(NSArray *)preferencesArray;
enum {
NSBundleExecutableArchitectureI386 = 0x00000007,
NSBundleExecutableArchitecturePPC = 0x00000012,
NSBundleExecutableArchitectureX86_64 = 0x01000007,
NSBundleExecutableArchitecturePPC64 = 0x01000012
};
// @property (readonly, copy) NSArray *executableArchitectures __attribute__((availability(macosx,introduced=10.5)));
/* @end */
extern "C" NSString * const NSBundleDidLoadNotification;
extern "C" NSString * const NSLoadedClasses;
enum {
NS_UnknownByteOrder = CFByteOrderUnknown,
NS_LittleEndian = CFByteOrderLittleEndian,
NS_BigEndian = CFByteOrderBigEndian
};
static __inline__ __attribute__((always_inline)) long NSHostByteOrder(void) {
return CFByteOrderGetCurrent();
}
static __inline__ __attribute__((always_inline)) unsigned short NSSwapShort(unsigned short inv) {
return CFSwapInt16(inv);
}
static __inline__ __attribute__((always_inline)) unsigned int NSSwapInt(unsigned int inv) {
return CFSwapInt32(inv);
}
static __inline__ __attribute__((always_inline)) unsigned long NSSwapLong(unsigned long inv) {
return CFSwapInt64(inv);
}
static __inline__ __attribute__((always_inline)) unsigned long long NSSwapLongLong(unsigned long long inv) {
return CFSwapInt64(inv);
}
static __inline__ __attribute__((always_inline)) unsigned short NSSwapBigShortToHost(unsigned short x) {
return CFSwapInt16BigToHost(x);
}
static __inline__ __attribute__((always_inline)) unsigned int NSSwapBigIntToHost(unsigned int x) {
return CFSwapInt32BigToHost(x);
}
static __inline__ __attribute__((always_inline)) unsigned long NSSwapBigLongToHost(unsigned long x) {
return CFSwapInt64BigToHost(x);
}
static __inline__ __attribute__((always_inline)) unsigned long long NSSwapBigLongLongToHost(unsigned long long x) {
return CFSwapInt64BigToHost(x);
}
static __inline__ __attribute__((always_inline)) unsigned short NSSwapHostShortToBig(unsigned short x) {
return CFSwapInt16HostToBig(x);
}
static __inline__ __attribute__((always_inline)) unsigned int NSSwapHostIntToBig(unsigned int x) {
return CFSwapInt32HostToBig(x);
}
static __inline__ __attribute__((always_inline)) unsigned long NSSwapHostLongToBig(unsigned long x) {
return CFSwapInt64HostToBig(x);
}
static __inline__ __attribute__((always_inline)) unsigned long long NSSwapHostLongLongToBig(unsigned long long x) {
return CFSwapInt64HostToBig(x);
}
static __inline__ __attribute__((always_inline)) unsigned short NSSwapLittleShortToHost(unsigned short x) {
return CFSwapInt16LittleToHost(x);
}
static __inline__ __attribute__((always_inline)) unsigned int NSSwapLittleIntToHost(unsigned int x) {
return CFSwapInt32LittleToHost(x);
}
static __inline__ __attribute__((always_inline)) unsigned long NSSwapLittleLongToHost(unsigned long x) {
return CFSwapInt64LittleToHost(x);
}
static __inline__ __attribute__((always_inline)) unsigned long long NSSwapLittleLongLongToHost(unsigned long long x) {
return CFSwapInt64LittleToHost(x);
}
static __inline__ __attribute__((always_inline)) unsigned short NSSwapHostShortToLittle(unsigned short x) {
return CFSwapInt16HostToLittle(x);
}
static __inline__ __attribute__((always_inline)) unsigned int NSSwapHostIntToLittle(unsigned int x) {
return CFSwapInt32HostToLittle(x);
}
static __inline__ __attribute__((always_inline)) unsigned long NSSwapHostLongToLittle(unsigned long x) {
return CFSwapInt64HostToLittle(x);
}
static __inline__ __attribute__((always_inline)) unsigned long long NSSwapHostLongLongToLittle(unsigned long long x) {
return CFSwapInt64HostToLittle(x);
}
typedef struct {unsigned int v;} NSSwappedFloat;
typedef struct {unsigned long long v;} NSSwappedDouble;
static __inline__ __attribute__((always_inline)) NSSwappedFloat NSConvertHostFloatToSwapped(float x) {
union fconv {
float number;
NSSwappedFloat sf;
};
return ((union fconv *)&x)->sf;
}
static __inline__ __attribute__((always_inline)) float NSConvertSwappedFloatToHost(NSSwappedFloat x) {
union fconv {
float number;
NSSwappedFloat sf;
};
return ((union fconv *)&x)->number;
}
static __inline__ __attribute__((always_inline)) NSSwappedDouble NSConvertHostDoubleToSwapped(double x) {
union dconv {
double number;
NSSwappedDouble sd;
};
return ((union dconv *)&x)->sd;
}
static __inline__ __attribute__((always_inline)) double NSConvertSwappedDoubleToHost(NSSwappedDouble x) {
union dconv {
double number;
NSSwappedDouble sd;
};
return ((union dconv *)&x)->number;
}
static __inline__ __attribute__((always_inline)) NSSwappedFloat NSSwapFloat(NSSwappedFloat x) {
x.v = NSSwapInt(x.v);
return x;
}
static __inline__ __attribute__((always_inline)) NSSwappedDouble NSSwapDouble(NSSwappedDouble x) {
x.v = NSSwapLongLong(x.v);
return x;
}
static __inline__ __attribute__((always_inline)) double NSSwapBigDoubleToHost(NSSwappedDouble x) {
return NSConvertSwappedDoubleToHost(NSSwapDouble(x));
}
static __inline__ __attribute__((always_inline)) float NSSwapBigFloatToHost(NSSwappedFloat x) {
return NSConvertSwappedFloatToHost(NSSwapFloat(x));
}
static __inline__ __attribute__((always_inline)) NSSwappedDouble NSSwapHostDoubleToBig(double x) {
return NSSwapDouble(NSConvertHostDoubleToSwapped(x));
}
static __inline__ __attribute__((always_inline)) NSSwappedFloat NSSwapHostFloatToBig(float x) {
return NSSwapFloat(NSConvertHostFloatToSwapped(x));
}
static __inline__ __attribute__((always_inline)) double NSSwapLittleDoubleToHost(NSSwappedDouble x) {
return NSConvertSwappedDoubleToHost(x);
}
static __inline__ __attribute__((always_inline)) float NSSwapLittleFloatToHost(NSSwappedFloat x) {
return NSConvertSwappedFloatToHost(x);
}
static __inline__ __attribute__((always_inline)) NSSwappedDouble NSSwapHostDoubleToLittle(double x) {
return NSConvertHostDoubleToSwapped(x);
}
static __inline__ __attribute__((always_inline)) NSSwappedFloat NSSwapHostFloatToLittle(float x) {
return NSConvertHostFloatToSwapped(x);
}
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
extern "C" NSString * const NSSystemClockDidChangeNotification __attribute__((availability(macosx,introduced=10.6)));
typedef double NSTimeInterval;
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
struct NSDate_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly) NSTimeInterval timeIntervalSinceReferenceDate;
// - (instancetype)init __attribute__((objc_designated_initializer));
// - (instancetype)initWithTimeIntervalSinceReferenceDate:(NSTimeInterval)ti __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSDate (NSExtendedDate)
// - (NSTimeInterval)timeIntervalSinceDate:(NSDate *)anotherDate;
// @property (readonly) NSTimeInterval timeIntervalSinceNow;
// @property (readonly) NSTimeInterval timeIntervalSince1970;
// - (id)addTimeInterval:(NSTimeInterval)seconds __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.6,message="" )));
// - (instancetype)dateByAddingTimeInterval:(NSTimeInterval)ti __attribute__((availability(macosx,introduced=10.6)));
// - (NSDate *)earlierDate:(NSDate *)anotherDate;
// - (NSDate *)laterDate:(NSDate *)anotherDate;
// - (NSComparisonResult)compare:(NSDate *)other;
// - (BOOL)isEqualToDate:(NSDate *)otherDate;
// @property (readonly, copy) NSString *description;
// - (NSString *)descriptionWithLocale:(id)locale;
// + (NSTimeInterval)timeIntervalSinceReferenceDate;
/* @end */
// @interface NSDate (NSDateCreation)
// + (instancetype)date;
// + (instancetype)dateWithTimeIntervalSinceNow:(NSTimeInterval)secs;
// + (instancetype)dateWithTimeIntervalSinceReferenceDate:(NSTimeInterval)ti;
// + (instancetype)dateWithTimeIntervalSince1970:(NSTimeInterval)secs;
// + (instancetype)dateWithTimeInterval:(NSTimeInterval)secsToBeAdded sinceDate:(NSDate *)date;
// + (id )distantFuture;
// + (id )distantPast;
// - (instancetype)initWithTimeIntervalSinceNow:(NSTimeInterval)secs;
// - (instancetype)initWithTimeIntervalSince1970:(NSTimeInterval)secs;
// - (instancetype)initWithTimeInterval:(NSTimeInterval)secsToBeAdded sinceDate:(NSDate *)date;
/* @end */
// @class NSDateComponents;
#ifndef _REWRITER_typedef_NSDateComponents
#define _REWRITER_typedef_NSDateComponents
typedef struct objc_object NSDateComponents;
typedef struct {} _objc_exc_NSDateComponents;
#endif
#ifndef _REWRITER_typedef_NSLocale
#define _REWRITER_typedef_NSLocale
typedef struct objc_object NSLocale;
typedef struct {} _objc_exc_NSLocale;
#endif
#ifndef _REWRITER_typedef_NSTimeZone
#define _REWRITER_typedef_NSTimeZone
typedef struct objc_object NSTimeZone;
typedef struct {} _objc_exc_NSTimeZone;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
extern "C" NSString * const NSCalendarIdentifierGregorian __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierBuddhist __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierChinese __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierCoptic __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierEthiopicAmeteMihret __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierEthiopicAmeteAlem __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierHebrew __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierISO8601 __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierIndian __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierIslamic __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierIslamicCivil __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierJapanese __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierPersian __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierRepublicOfChina __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSCalendarIdentifierIslamicTabular __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSCalendarIdentifierIslamicUmmAlQura __attribute__((availability(macosx,introduced=10.10)));
typedef NSUInteger NSCalendarUnit; enum {
NSCalendarUnitEra = kCFCalendarUnitEra,
NSCalendarUnitYear = kCFCalendarUnitYear,
NSCalendarUnitMonth = kCFCalendarUnitMonth,
NSCalendarUnitDay = kCFCalendarUnitDay,
NSCalendarUnitHour = kCFCalendarUnitHour,
NSCalendarUnitMinute = kCFCalendarUnitMinute,
NSCalendarUnitSecond = kCFCalendarUnitSecond,
NSCalendarUnitWeekday = kCFCalendarUnitWeekday,
NSCalendarUnitWeekdayOrdinal = kCFCalendarUnitWeekdayOrdinal,
NSCalendarUnitQuarter __attribute__((availability(macosx,introduced=10.6))) = kCFCalendarUnitQuarter,
NSCalendarUnitWeekOfMonth __attribute__((availability(macosx,introduced=10.7))) = kCFCalendarUnitWeekOfMonth,
NSCalendarUnitWeekOfYear __attribute__((availability(macosx,introduced=10.7))) = kCFCalendarUnitWeekOfYear,
NSCalendarUnitYearForWeekOfYear __attribute__((availability(macosx,introduced=10.7))) = kCFCalendarUnitYearForWeekOfYear,
NSCalendarUnitNanosecond __attribute__((availability(macosx,introduced=10.7))) = (1 << 15),
NSCalendarUnitCalendar __attribute__((availability(macosx,introduced=10.7))) = (1 << 20),
NSCalendarUnitTimeZone __attribute__((availability(macosx,introduced=10.7))) = (1 << 21),
NSEraCalendarUnit __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarUnitEra instead"))) = NSCalendarUnitEra,
NSYearCalendarUnit __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarUnitYear instead"))) = NSCalendarUnitYear,
NSMonthCalendarUnit __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarUnitMonth instead"))) = NSCalendarUnitMonth,
NSDayCalendarUnit __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarUnitDay instead"))) = NSCalendarUnitDay,
NSHourCalendarUnit __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarUnitHour instead"))) = NSCalendarUnitHour,
NSMinuteCalendarUnit __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarUnitMinute instead"))) = NSCalendarUnitMinute,
NSSecondCalendarUnit __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarUnitSecond instead"))) = NSCalendarUnitSecond,
NSWeekCalendarUnit __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarUnitWeekOfMonth or NSCalendarUnitWeekOfYear, depending on which you mean"))) = kCFCalendarUnitWeek,
NSWeekdayCalendarUnit __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarUnitWeekday instead"))) = NSCalendarUnitWeekday,
NSWeekdayOrdinalCalendarUnit __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarUnitWeekdayOrdinal instead"))) = NSCalendarUnitWeekdayOrdinal,
NSQuarterCalendarUnit __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.10,message="" "Use NSCalendarUnitQuarter instead"))) = NSCalendarUnitQuarter,
NSWeekOfMonthCalendarUnit __attribute__((availability(macosx,introduced=10.7 ,deprecated=10.10,message="" "Use NSCalendarUnitWeekOfMonth instead"))) = NSCalendarUnitWeekOfMonth,
NSWeekOfYearCalendarUnit __attribute__((availability(macosx,introduced=10.7 ,deprecated=10.10,message="" "Use NSCalendarUnitWeekOfYear instead"))) = NSCalendarUnitWeekOfYear,
NSYearForWeekOfYearCalendarUnit __attribute__((availability(macosx,introduced=10.7 ,deprecated=10.10,message="" "Use NSCalendarUnitYearForWeekOfYear instead"))) = NSCalendarUnitYearForWeekOfYear,
NSCalendarCalendarUnit __attribute__((availability(macosx,introduced=10.7 ,deprecated=10.10,message="" "Use NSCalendarUnitCalendar instead"))) = NSCalendarUnitCalendar,
NSTimeZoneCalendarUnit __attribute__((availability(macosx,introduced=10.7 ,deprecated=10.10,message="" "Use NSCalendarUnitTimeZone instead"))) = NSCalendarUnitTimeZone,
};
typedef NSUInteger NSCalendarOptions; enum {
NSCalendarWrapComponents = (1UL << 0),
NSCalendarMatchStrictly __attribute__((availability(macosx,introduced=10.9))) = (1ULL << 1),
NSCalendarSearchBackwards __attribute__((availability(macosx,introduced=10.9))) = (1ULL << 2),
NSCalendarMatchPreviousTimePreservingSmallerUnits __attribute__((availability(macosx,introduced=10.9))) = (1ULL << 8),
NSCalendarMatchNextTimePreservingSmallerUnits __attribute__((availability(macosx,introduced=10.9))) = (1ULL << 9),
NSCalendarMatchNextTime __attribute__((availability(macosx,introduced=10.9))) = (1ULL << 10),
NSCalendarMatchFirst __attribute__((availability(macosx,introduced=10.9))) = (1ULL << 12),
NSCalendarMatchLast __attribute__((availability(macosx,introduced=10.9))) = (1ULL << 13)
};
enum {
NSWrapCalendarComponents __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarWrapComponents instead"))) = NSCalendarWrapComponents,
};
#ifndef _REWRITER_typedef_NSCalendar
#define _REWRITER_typedef_NSCalendar
typedef struct objc_object NSCalendar;
typedef struct {} _objc_exc_NSCalendar;
#endif
struct NSCalendar_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// + (NSCalendar *)currentCalendar;
// + (NSCalendar *)autoupdatingCurrentCalendar __attribute__((availability(macosx,introduced=10.5)));
// + (NSCalendar *)calendarWithIdentifier:(NSString *)calendarIdentifierConstant __attribute__((availability(macosx,introduced=10.9)));
// - (id)initWithCalendarIdentifier:(NSString *)ident __attribute__((objc_designated_initializer));
// @property (readonly, copy) NSString *calendarIdentifier;
// @property (copy) NSLocale *locale;
// @property (copy) NSTimeZone *timeZone;
// @property NSUInteger firstWeekday;
// @property NSUInteger minimumDaysInFirstWeek;
// @property (readonly, copy) NSArray *eraSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *longEraSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *monthSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *shortMonthSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *veryShortMonthSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *standaloneMonthSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *shortStandaloneMonthSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *veryShortStandaloneMonthSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *weekdaySymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *shortWeekdaySymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *veryShortWeekdaySymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *standaloneWeekdaySymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *shortStandaloneWeekdaySymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *veryShortStandaloneWeekdaySymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *quarterSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *shortQuarterSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *standaloneQuarterSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSArray *shortStandaloneQuarterSymbols __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSString *AMSymbol __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSString *PMSymbol __attribute__((availability(macosx,introduced=10.7)));
// - (NSRange)minimumRangeOfUnit:(NSCalendarUnit)unit;
// - (NSRange)maximumRangeOfUnit:(NSCalendarUnit)unit;
// - (NSRange)rangeOfUnit:(NSCalendarUnit)smaller inUnit:(NSCalendarUnit)larger forDate:(NSDate *)date;
// - (NSUInteger)ordinalityOfUnit:(NSCalendarUnit)smaller inUnit:(NSCalendarUnit)larger forDate:(NSDate *)date;
// - (BOOL)rangeOfUnit:(NSCalendarUnit)unit startDate:(NSDate **)datep interval:(NSTimeInterval *)tip forDate:(NSDate *)date __attribute__((availability(macosx,introduced=10.5)));
// - (NSDate *)dateFromComponents:(NSDateComponents *)comps;
// - (NSDateComponents *)components:(NSCalendarUnit)unitFlags fromDate:(NSDate *)date;
// - (NSDate *)dateByAddingComponents:(NSDateComponents *)comps toDate:(NSDate *)date options:(NSCalendarOptions)opts;
// - (NSDateComponents *)components:(NSCalendarUnit)unitFlags fromDate:(NSDate *)startingDate toDate:(NSDate *)resultDate options:(NSCalendarOptions)opts;
// - (void)getEra:(out NSInteger *)eraValuePointer year:(out NSInteger *)yearValuePointer month:(out NSInteger *)monthValuePointer day:(out NSInteger *)dayValuePointer fromDate:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (void)getEra:(out NSInteger *)eraValuePointer yearForWeekOfYear:(out NSInteger *)yearValuePointer weekOfYear:(out NSInteger *)weekValuePointer weekday:(out NSInteger *)weekdayValuePointer fromDate:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (void)getHour:(out NSInteger *)hourValuePointer minute:(out NSInteger *)minuteValuePointer second:(out NSInteger *)secondValuePointer nanosecond:(out NSInteger *)nanosecondValuePointer fromDate:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (NSInteger)component:(NSCalendarUnit)unit fromDate:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (NSDate *)dateWithEra:(NSInteger)eraValue year:(NSInteger)yearValue month:(NSInteger)monthValue day:(NSInteger)dayValue hour:(NSInteger)hourValue minute:(NSInteger)minuteValue second:(NSInteger)secondValue nanosecond:(NSInteger)nanosecondValue __attribute__((availability(macosx,introduced=10.9)));
// - (NSDate *)dateWithEra:(NSInteger)eraValue yearForWeekOfYear:(NSInteger)yearValue weekOfYear:(NSInteger)weekValue weekday:(NSInteger)weekdayValue hour:(NSInteger)hourValue minute:(NSInteger)minuteValue second:(NSInteger)secondValue nanosecond:(NSInteger)nanosecondValue __attribute__((availability(macosx,introduced=10.9)));
// - (NSDate *)startOfDayForDate:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (NSDateComponents *)componentsInTimeZone:(NSTimeZone *)timezone fromDate:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (NSComparisonResult)compareDate:(NSDate *)date1 toDate:(NSDate *)date2 toUnitGranularity:(NSCalendarUnit)unit __attribute__((availability(macosx,introduced=10.9)));
// - (BOOL)isDate:(NSDate *)date1 equalToDate:(NSDate *)date2 toUnitGranularity:(NSCalendarUnit)unit __attribute__((availability(macosx,introduced=10.9)));
// - (BOOL)isDate:(NSDate *)date1 inSameDayAsDate:(NSDate *)date2 __attribute__((availability(macosx,introduced=10.9)));
// - (BOOL)isDateInToday:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (BOOL)isDateInYesterday:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (BOOL)isDateInTomorrow:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (BOOL)isDateInWeekend:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (BOOL)rangeOfWeekendStartDate:(out NSDate **)datep interval:(out NSTimeInterval *)tip containingDate:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (BOOL)nextWeekendStartDate:(out NSDate **)datep interval:(out NSTimeInterval *)tip options:(NSCalendarOptions)options afterDate:(NSDate *)date __attribute__((availability(macosx,introduced=10.9)));
// - (NSDateComponents *)components:(NSCalendarUnit)unitFlags fromDateComponents:(NSDateComponents *)startingDateComp toDateComponents:(NSDateComponents *)resultDateComp options:(NSCalendarOptions)options __attribute__((availability(macosx,introduced=10.9)));
// - (NSDate *)dateByAddingUnit:(NSCalendarUnit)unit value:(NSInteger)value toDate:(NSDate *)date options:(NSCalendarOptions)options __attribute__((availability(macosx,introduced=10.9)));
// - (void)enumerateDatesStartingAfterDate:(NSDate *)start matchingComponents:(NSDateComponents *)comps options:(NSCalendarOptions)opts usingBlock:(void (^)(NSDate *date, BOOL exactMatch, BOOL *stop))block __attribute__((availability(macosx,introduced=10.9)));
// - (NSDate *)nextDateAfterDate:(NSDate *)date matchingComponents:(NSDateComponents *)comps options:(NSCalendarOptions)options __attribute__((availability(macosx,introduced=10.9)));
// - (NSDate *)nextDateAfterDate:(NSDate *)date matchingUnit:(NSCalendarUnit)unit value:(NSInteger)value options:(NSCalendarOptions)options __attribute__((availability(macosx,introduced=10.9)));
// - (NSDate *)nextDateAfterDate:(NSDate *)date matchingHour:(NSInteger)hourValue minute:(NSInteger)minuteValue second:(NSInteger)secondValue options:(NSCalendarOptions)options __attribute__((availability(macosx,introduced=10.9)));
// - (NSDate *)dateBySettingUnit:(NSCalendarUnit)unit value:(NSInteger)v ofDate:(NSDate *)date options:(NSCalendarOptions)opts __attribute__((availability(macosx,introduced=10.9)));
// - (NSDate *)dateBySettingHour:(NSInteger)h minute:(NSInteger)m second:(NSInteger)s ofDate:(NSDate *)date options:(NSCalendarOptions)opts __attribute__((availability(macosx,introduced=10.9)));
// - (BOOL)date:(NSDate *)date matchesComponents:(NSDateComponents *)components __attribute__((availability(macosx,introduced=10.9)));
/* @end */
extern "C" NSString * const NSCalendarDayChangedNotification __attribute__((availability(macosx,introduced=10.9)));
enum {
NSDateComponentUndefined = 9223372036854775807L,
NSUndefinedDateComponent __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSDateComponentUndefined instead"))) = NSDateComponentUndefined
};
#ifndef _REWRITER_typedef_NSDateComponents
#define _REWRITER_typedef_NSDateComponents
typedef struct objc_object NSDateComponents;
typedef struct {} _objc_exc_NSDateComponents;
#endif
struct NSDateComponents_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (copy) NSCalendar *calendar __attribute__((availability(macosx,introduced=10.7)));
// @property (copy) NSTimeZone *timeZone __attribute__((availability(macosx,introduced=10.7)));
// @property NSInteger era;
// @property NSInteger year;
// @property NSInteger month;
// @property NSInteger day;
// @property NSInteger hour;
// @property NSInteger minute;
// @property NSInteger second;
// @property NSInteger nanosecond __attribute__((availability(macosx,introduced=10.7)));
// @property NSInteger weekday;
// @property NSInteger weekdayOrdinal;
// @property NSInteger quarter __attribute__((availability(macosx,introduced=10.6)));
// @property NSInteger weekOfMonth __attribute__((availability(macosx,introduced=10.7)));
// @property NSInteger weekOfYear __attribute__((availability(macosx,introduced=10.7)));
// @property NSInteger yearForWeekOfYear __attribute__((availability(macosx,introduced=10.7)));
// @property (getter=isLeapMonth) BOOL leapMonth __attribute__((availability(macosx,introduced=10.8)));
// @property (readonly, copy) NSDate *date __attribute__((availability(macosx,introduced=10.7)));
// - (NSInteger)week __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.9,message="" "Use weekOfMonth or weekOfYear, depending on which you mean")));
// - (void)setWeek:(NSInteger)v __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.9,message="" "Use setWeekOfMonth: or setWeekOfYear:, depending on which you mean")));
// - (void)setValue:(NSInteger)value forComponent:(NSCalendarUnit)unit __attribute__((availability(macosx,introduced=10.9)));
// - (NSInteger)valueForComponent:(NSCalendarUnit)unit __attribute__((availability(macosx,introduced=10.9)));
// @property (getter=isValidDate, readonly) BOOL validDate __attribute__((availability(macosx,introduced=10.9)));
// - (BOOL)isValidDateInCalendar:(NSCalendar *)calendar __attribute__((availability(macosx,introduced=10.9)));
/* @end */
typedef unsigned short unichar;
// @class NSData;
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSCharacterSet
#define _REWRITER_typedef_NSCharacterSet
typedef struct objc_object NSCharacterSet;
typedef struct {} _objc_exc_NSCharacterSet;
#endif
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
#ifndef _REWRITER_typedef_NSLocale
#define _REWRITER_typedef_NSLocale
typedef struct objc_object NSLocale;
typedef struct {} _objc_exc_NSLocale;
#endif
extern "C" NSString * const NSParseErrorException;
typedef NSUInteger NSStringCompareOptions; enum {
NSCaseInsensitiveSearch = 1,
NSLiteralSearch = 2,
NSBackwardsSearch = 4,
NSAnchoredSearch = 8,
NSNumericSearch = 64,
NSDiacriticInsensitiveSearch __attribute__((availability(macosx,introduced=10.5))) = 128,
NSWidthInsensitiveSearch __attribute__((availability(macosx,introduced=10.5))) = 256,
NSForcedOrderingSearch __attribute__((availability(macosx,introduced=10.5))) = 512,
NSRegularExpressionSearch __attribute__((availability(macosx,introduced=10.7))) = 1024
};
enum {
NSASCIIStringEncoding = 1,
NSNEXTSTEPStringEncoding = 2,
NSJapaneseEUCStringEncoding = 3,
NSUTF8StringEncoding = 4,
NSISOLatin1StringEncoding = 5,
NSSymbolStringEncoding = 6,
NSNonLossyASCIIStringEncoding = 7,
NSShiftJISStringEncoding = 8,
NSISOLatin2StringEncoding = 9,
NSUnicodeStringEncoding = 10,
NSWindowsCP1251StringEncoding = 11,
NSWindowsCP1252StringEncoding = 12,
NSWindowsCP1253StringEncoding = 13,
NSWindowsCP1254StringEncoding = 14,
NSWindowsCP1250StringEncoding = 15,
NSISO2022JPStringEncoding = 21,
NSMacOSRomanStringEncoding = 30,
NSUTF16StringEncoding = NSUnicodeStringEncoding,
NSUTF16BigEndianStringEncoding = 0x90000100,
NSUTF16LittleEndianStringEncoding = 0x94000100,
NSUTF32StringEncoding = 0x8c000100,
NSUTF32BigEndianStringEncoding = 0x98000100,
NSUTF32LittleEndianStringEncoding = 0x9c000100
};
typedef NSUInteger NSStringEncoding;
typedef NSUInteger NSStringEncodingConversionOptions; enum {
NSStringEncodingConversionAllowLossy = 1,
NSStringEncodingConversionExternalRepresentation = 2
};
extern "C" NSString * const NSCharacterConversionException;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
struct NSString_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly) NSUInteger length;
// - (unichar)characterAtIndex:(NSUInteger)index;
// - (instancetype)init __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSString (NSStringExtensionMethods)
// - (void)getCharacters:(unichar *)buffer range:(NSRange)aRange;
// - (NSString *)substringFromIndex:(NSUInteger)from;
// - (NSString *)substringToIndex:(NSUInteger)to;
// - (NSString *)substringWithRange:(NSRange)range;
// - (NSComparisonResult)compare:(NSString *)string;
// - (NSComparisonResult)compare:(NSString *)string options:(NSStringCompareOptions)mask;
// - (NSComparisonResult)compare:(NSString *)string options:(NSStringCompareOptions)mask range:(NSRange)compareRange;
// - (NSComparisonResult)compare:(NSString *)string options:(NSStringCompareOptions)mask range:(NSRange)compareRange locale:(id)locale;
// - (NSComparisonResult)caseInsensitiveCompare:(NSString *)string;
// - (NSComparisonResult)localizedCompare:(NSString *)string;
// - (NSComparisonResult)localizedCaseInsensitiveCompare:(NSString *)string;
// - (NSComparisonResult)localizedStandardCompare:(NSString *)string __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)isEqualToString:(NSString *)aString;
// - (BOOL)hasPrefix:(NSString *)aString;
// - (BOOL)hasSuffix:(NSString *)aString;
// - (BOOL)containsString:(NSString *)aString __attribute__((availability(macosx,introduced=10.10)));
// - (BOOL)localizedCaseInsensitiveContainsString:(NSString *)aString __attribute__((availability(macosx,introduced=10.10)));
// - (NSRange)rangeOfString:(NSString *)aString;
// - (NSRange)rangeOfString:(NSString *)aString options:(NSStringCompareOptions)mask;
// - (NSRange)rangeOfString:(NSString *)aString options:(NSStringCompareOptions)mask range:(NSRange)searchRange;
// - (NSRange)rangeOfString:(NSString *)aString options:(NSStringCompareOptions)mask range:(NSRange)searchRange locale:(NSLocale *)locale __attribute__((availability(macosx,introduced=10.5)));
// - (NSRange)rangeOfCharacterFromSet:(NSCharacterSet *)aSet;
// - (NSRange)rangeOfCharacterFromSet:(NSCharacterSet *)aSet options:(NSStringCompareOptions)mask;
// - (NSRange)rangeOfCharacterFromSet:(NSCharacterSet *)aSet options:(NSStringCompareOptions)mask range:(NSRange)searchRange;
// - (NSRange)rangeOfComposedCharacterSequenceAtIndex:(NSUInteger)index;
// - (NSRange)rangeOfComposedCharacterSequencesForRange:(NSRange)range __attribute__((availability(macosx,introduced=10.5)));
// - (NSString *)stringByAppendingString:(NSString *)aString;
// - (NSString *)stringByAppendingFormat:(NSString *)format, ... __attribute__((format(__NSString__, 1, 2)));
// @property (readonly) double doubleValue;
// @property (readonly) float floatValue;
// @property (readonly) int intValue;
// @property (readonly) NSInteger integerValue __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly) long long longLongValue __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly) BOOL boolValue __attribute__((availability(macosx,introduced=10.5)));
// - (NSArray *)componentsSeparatedByString:(NSString *)separator;
// - (NSArray *)componentsSeparatedByCharactersInSet:(NSCharacterSet *)separator __attribute__((availability(macosx,introduced=10.5)));
// - (NSString *)commonPrefixWithString:(NSString *)aString options:(NSStringCompareOptions)mask;
// @property (readonly, copy) NSString *uppercaseString;
// @property (readonly, copy) NSString *lowercaseString;
// @property (readonly, copy) NSString *capitalizedString;
// - (NSString *)uppercaseStringWithLocale:(NSLocale *)locale __attribute__((availability(macosx,introduced=10.8)));
// - (NSString *)lowercaseStringWithLocale:(NSLocale *)locale __attribute__((availability(macosx,introduced=10.8)));
// - (NSString *)capitalizedStringWithLocale:(NSLocale *)locale __attribute__((availability(macosx,introduced=10.8)));
// - (NSString *)stringByTrimmingCharactersInSet:(NSCharacterSet *)set;
// - (NSString *)stringByPaddingToLength:(NSUInteger)newLength withString:(NSString *)padString startingAtIndex:(NSUInteger)padIndex;
// - (void)getLineStart:(NSUInteger *)startPtr end:(NSUInteger *)lineEndPtr contentsEnd:(NSUInteger *)contentsEndPtr forRange:(NSRange)range;
// - (NSRange)lineRangeForRange:(NSRange)range;
// - (void)getParagraphStart:(NSUInteger *)startPtr end:(NSUInteger *)parEndPtr contentsEnd:(NSUInteger *)contentsEndPtr forRange:(NSRange)range;
// - (NSRange)paragraphRangeForRange:(NSRange)range;
typedef NSUInteger NSStringEnumerationOptions; enum {
NSStringEnumerationByLines = 0,
NSStringEnumerationByParagraphs = 1,
NSStringEnumerationByComposedCharacterSequences = 2,
NSStringEnumerationByWords = 3,
NSStringEnumerationBySentences = 4,
NSStringEnumerationReverse = 1UL << 8,
NSStringEnumerationSubstringNotRequired = 1UL << 9,
NSStringEnumerationLocalized = 1UL << 10
};
// - (void)enumerateSubstringsInRange:(NSRange)range options:(NSStringEnumerationOptions)opts usingBlock:(void (^)(NSString *substring, NSRange substringRange, NSRange enclosingRange, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// - (void)enumerateLinesUsingBlock:(void (^)(NSString *line, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSString *description;
// @property (readonly) NSUInteger hash;
// @property (readonly) NSStringEncoding fastestEncoding;
// @property (readonly) NSStringEncoding smallestEncoding;
// - (NSData *)dataUsingEncoding:(NSStringEncoding)encoding allowLossyConversion:(BOOL)lossy;
// - (NSData *)dataUsingEncoding:(NSStringEncoding)encoding;
// - (BOOL)canBeConvertedToEncoding:(NSStringEncoding)encoding;
// - ( const char *)cStringUsingEncoding:(NSStringEncoding)encoding __attribute__((objc_returns_inner_pointer));
// - (BOOL)getCString:(char *)buffer maxLength:(NSUInteger)maxBufferCount encoding:(NSStringEncoding)encoding;
// - (BOOL)getBytes:(void *)buffer maxLength:(NSUInteger)maxBufferCount usedLength:(NSUInteger *)usedBufferCount encoding:(NSStringEncoding)encoding options:(NSStringEncodingConversionOptions)options range:(NSRange)range remainingRange:(NSRangePointer)leftover;
// - (NSUInteger)maximumLengthOfBytesUsingEncoding:(NSStringEncoding)enc;
// - (NSUInteger)lengthOfBytesUsingEncoding:(NSStringEncoding)enc;
// @property (readonly, copy) NSString *decomposedStringWithCanonicalMapping;
// @property (readonly, copy) NSString *precomposedStringWithCanonicalMapping;
// @property (readonly, copy) NSString *decomposedStringWithCompatibilityMapping;
// @property (readonly, copy) NSString *precomposedStringWithCompatibilityMapping;
// - (NSString *)stringByFoldingWithOptions:(NSStringCompareOptions)options locale:(NSLocale *)locale __attribute__((availability(macosx,introduced=10.5)));
// - (NSString *)stringByReplacingOccurrencesOfString:(NSString *)target withString:(NSString *)replacement options:(NSStringCompareOptions)options range:(NSRange)searchRange __attribute__((availability(macosx,introduced=10.5)));
// - (NSString *)stringByReplacingOccurrencesOfString:(NSString *)target withString:(NSString *)replacement __attribute__((availability(macosx,introduced=10.5)));
// - (NSString *)stringByReplacingCharactersInRange:(NSRange)range withString:(NSString *)replacement __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly) const char *UTF8String __attribute__((objc_returns_inner_pointer));
// + (NSStringEncoding)defaultCStringEncoding;
// + (const NSStringEncoding *)availableStringEncodings;
// + (NSString *)localizedNameOfStringEncoding:(NSStringEncoding)encoding;
// - (instancetype)initWithCharactersNoCopy:(unichar *)characters length:(NSUInteger)length freeWhenDone:(BOOL)freeBuffer;
// - (instancetype)initWithCharacters:(const unichar *)characters length:(NSUInteger)length;
// - (instancetype)initWithUTF8String:(const char *)nullTerminatedCString;
// - (instancetype)initWithString:(NSString *)aString;
// - (instancetype)initWithFormat:(NSString *)format, ... __attribute__((format(__NSString__, 1, 2)));
// - (instancetype)initWithFormat:(NSString *)format arguments:(va_list)argList __attribute__((format(__NSString__, 1, 0)));
// - (instancetype)initWithFormat:(NSString *)format locale:(id)locale, ... __attribute__((format(__NSString__, 1, 3)));
// - (instancetype)initWithFormat:(NSString *)format locale:(id)locale arguments:(va_list)argList __attribute__((format(__NSString__, 1, 0)));
// - (instancetype)initWithData:(NSData *)data encoding:(NSStringEncoding)encoding;
// - (instancetype)initWithBytes:(const void *)bytes length:(NSUInteger)len encoding:(NSStringEncoding)encoding;
// - (instancetype)initWithBytesNoCopy:(void *)bytes length:(NSUInteger)len encoding:(NSStringEncoding)encoding freeWhenDone:(BOOL)freeBuffer;
// + (instancetype)string;
// + (instancetype)stringWithString:(NSString *)string;
// + (instancetype)stringWithCharacters:(const unichar *)characters length:(NSUInteger)length;
// + (instancetype)stringWithUTF8String:(const char *)nullTerminatedCString;
// + (instancetype)stringWithFormat:(NSString *)format, ... __attribute__((format(__NSString__, 1, 2)));
// + (instancetype)localizedStringWithFormat:(NSString *)format, ... __attribute__((format(__NSString__, 1, 2)));
// - (instancetype)initWithCString:(const char *)nullTerminatedCString encoding:(NSStringEncoding)encoding;
// + (instancetype)stringWithCString:(const char *)cString encoding:(NSStringEncoding)enc;
// - (instancetype)initWithContentsOfURL:(NSURL *)url encoding:(NSStringEncoding)enc error:(NSError **)error;
// - (instancetype)initWithContentsOfFile:(NSString *)path encoding:(NSStringEncoding)enc error:(NSError **)error;
// + (instancetype)stringWithContentsOfURL:(NSURL *)url encoding:(NSStringEncoding)enc error:(NSError **)error;
// + (instancetype)stringWithContentsOfFile:(NSString *)path encoding:(NSStringEncoding)enc error:(NSError **)error;
// - (instancetype)initWithContentsOfURL:(NSURL *)url usedEncoding:(NSStringEncoding *)enc error:(NSError **)error;
// - (instancetype)initWithContentsOfFile:(NSString *)path usedEncoding:(NSStringEncoding *)enc error:(NSError **)error;
// + (instancetype)stringWithContentsOfURL:(NSURL *)url usedEncoding:(NSStringEncoding *)enc error:(NSError **)error;
// + (instancetype)stringWithContentsOfFile:(NSString *)path usedEncoding:(NSStringEncoding *)enc error:(NSError **)error;
// - (BOOL)writeToURL:(NSURL *)url atomically:(BOOL)useAuxiliaryFile encoding:(NSStringEncoding)enc error:(NSError **)error;
// - (BOOL)writeToFile:(NSString *)path atomically:(BOOL)useAuxiliaryFile encoding:(NSStringEncoding)enc error:(NSError **)error;
/* @end */
#ifndef _REWRITER_typedef_NSMutableString
#define _REWRITER_typedef_NSMutableString
typedef struct objc_object NSMutableString;
typedef struct {} _objc_exc_NSMutableString;
#endif
struct NSMutableString_IMPL {
struct NSString_IMPL NSString_IVARS;
};
// - (void)replaceCharactersInRange:(NSRange)range withString:(NSString *)aString;
/* @end */
// @interface NSMutableString (NSMutableStringExtensionMethods)
// - (void)insertString:(NSString *)aString atIndex:(NSUInteger)loc;
// - (void)deleteCharactersInRange:(NSRange)range;
// - (void)appendString:(NSString *)aString;
// - (void)appendFormat:(NSString *)format, ... __attribute__((format(__NSString__, 1, 2)));
// - (void)setString:(NSString *)aString;
// - (NSMutableString *)initWithCapacity:(NSUInteger)capacity;
// + (NSMutableString *)stringWithCapacity:(NSUInteger)capacity;
// - (NSUInteger)replaceOccurrencesOfString:(NSString *)target withString:(NSString *)replacement options:(NSStringCompareOptions)options range:(NSRange)searchRange;
/* @end */
// @interface NSString (NSStringEncodingDetection)
#if 0
+ (NSStringEncoding)stringEncodingForData:(NSData *)data
encodingOptions:(NSDictionary *)opts
convertedString:(NSString **)string
usedLossyConversion:(BOOL *)usedLossyConversion __attribute__((availability(macosx,introduced=10.10)));
#endif
/* @end */
extern "C" NSString * const NSStringEncodingDetectionSuggestedEncodingsKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSStringEncodingDetectionDisallowedEncodingsKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSStringEncodingDetectionUseOnlySuggestedEncodingsKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSStringEncodingDetectionAllowLossyKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSStringEncodingDetectionFromWindowsKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSStringEncodingDetectionLossySubstitutionKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSStringEncodingDetectionLikelyLanguageKey __attribute__((availability(macosx,introduced=10.10)));
// @interface NSString (NSExtendedStringPropertyListParsing)
// - (id)propertyList;
// - (NSDictionary *)propertyListFromStringsFileFormat;
/* @end */
// @interface NSString (NSStringDeprecated)
// - (const char *)cString __attribute__((objc_returns_inner_pointer)) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (const char *)lossyCString __attribute__((objc_returns_inner_pointer)) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (NSUInteger)cStringLength __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)getCString:(char *)bytes __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)getCString:(char *)bytes maxLength:(NSUInteger)maxLength __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)getCString:(char *)bytes maxLength:(NSUInteger)maxLength range:(NSRange)aRange remainingRange:(NSRangePointer)leftoverRange __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (BOOL)writeToFile:(NSString *)path atomically:(BOOL)useAuxiliaryFile __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (BOOL)writeToURL:(NSURL *)url atomically:(BOOL)atomically __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (id)initWithContentsOfFile:(NSString *)path __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (id)initWithContentsOfURL:(NSURL *)url __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// + (id)stringWithContentsOfFile:(NSString *)path __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// + (id)stringWithContentsOfURL:(NSURL *)url __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (id)initWithCStringNoCopy:(char *)bytes length:(NSUInteger)length freeWhenDone:(BOOL)freeBuffer __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (id)initWithCString:(const char *)bytes length:(NSUInteger)length __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (id)initWithCString:(const char *)bytes __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// + (id)stringWithCString:(const char *)bytes length:(NSUInteger)length __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// + (id)stringWithCString:(const char *)bytes __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)getCharacters:(unichar *)buffer;
/* @end */
enum {
NSProprietaryStringEncoding = 65536
};
#ifndef _REWRITER_typedef_NSSimpleCString
#define _REWRITER_typedef_NSSimpleCString
typedef struct objc_object NSSimpleCString;
typedef struct {} _objc_exc_NSSimpleCString;
#endif
struct NSSimpleCString_IMPL {
struct NSString_IMPL NSString_IVARS;
char *bytes;
int numBytes;
int _unused;
};
/* @end */
#ifndef _REWRITER_typedef_NSConstantString
#define _REWRITER_typedef_NSConstantString
typedef struct objc_object NSConstantString;
typedef struct {} _objc_exc_NSConstantString;
#endif
struct NSConstantString_IMPL {
struct NSSimpleCString_IMPL NSSimpleCString_IVARS;
};
/* @end */
// @class NSData;
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
enum {
NSOpenStepUnicodeReservedBase = 0xF400
};
#ifndef _REWRITER_typedef_NSCharacterSet
#define _REWRITER_typedef_NSCharacterSet
typedef struct objc_object NSCharacterSet;
typedef struct {} _objc_exc_NSCharacterSet;
#endif
struct NSCharacterSet_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// + (NSCharacterSet *)controlCharacterSet;
// + (NSCharacterSet *)whitespaceCharacterSet;
// + (NSCharacterSet *)whitespaceAndNewlineCharacterSet;
// + (NSCharacterSet *)decimalDigitCharacterSet;
// + (NSCharacterSet *)letterCharacterSet;
// + (NSCharacterSet *)lowercaseLetterCharacterSet;
// + (NSCharacterSet *)uppercaseLetterCharacterSet;
// + (NSCharacterSet *)nonBaseCharacterSet;
// + (NSCharacterSet *)alphanumericCharacterSet;
// + (NSCharacterSet *)decomposableCharacterSet;
// + (NSCharacterSet *)illegalCharacterSet;
// + (NSCharacterSet *)punctuationCharacterSet;
// + (NSCharacterSet *)capitalizedLetterCharacterSet;
// + (NSCharacterSet *)symbolCharacterSet;
// + (NSCharacterSet *)newlineCharacterSet __attribute__((availability(macosx,introduced=10.5)));
// + (NSCharacterSet *)characterSetWithRange:(NSRange)aRange;
// + (NSCharacterSet *)characterSetWithCharactersInString:(NSString *)aString;
// + (NSCharacterSet *)characterSetWithBitmapRepresentation:(NSData *)data;
// + (NSCharacterSet *)characterSetWithContentsOfFile:(NSString *)fName;
// - (instancetype) initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
// - (BOOL)characterIsMember:(unichar)aCharacter;
// @property (readonly, copy) NSData *bitmapRepresentation;
// @property (readonly, copy) NSCharacterSet *invertedSet;
// - (BOOL)longCharacterIsMember:(UTF32Char)theLongChar;
// - (BOOL)isSupersetOfSet:(NSCharacterSet *)theOtherSet;
// - (BOOL)hasMemberInPlane:(uint8_t)thePlane;
/* @end */
#ifndef _REWRITER_typedef_NSMutableCharacterSet
#define _REWRITER_typedef_NSMutableCharacterSet
typedef struct objc_object NSMutableCharacterSet;
typedef struct {} _objc_exc_NSMutableCharacterSet;
#endif
struct NSMutableCharacterSet_IMPL {
struct NSCharacterSet_IMPL NSCharacterSet_IVARS;
};
// - (void)addCharactersInRange:(NSRange)aRange;
// - (void)removeCharactersInRange:(NSRange)aRange;
// - (void)addCharactersInString:(NSString *)aString;
// - (void)removeCharactersInString:(NSString *)aString;
// - (void)formUnionWithCharacterSet:(NSCharacterSet *)otherSet;
// - (void)formIntersectionWithCharacterSet:(NSCharacterSet *)otherSet;
// - (void)invert;
// + (NSMutableCharacterSet *)controlCharacterSet;
// + (NSMutableCharacterSet *)whitespaceCharacterSet;
// + (NSMutableCharacterSet *)whitespaceAndNewlineCharacterSet;
// + (NSMutableCharacterSet *)decimalDigitCharacterSet;
// + (NSMutableCharacterSet *)letterCharacterSet;
// + (NSMutableCharacterSet *)lowercaseLetterCharacterSet;
// + (NSMutableCharacterSet *)uppercaseLetterCharacterSet;
// + (NSMutableCharacterSet *)nonBaseCharacterSet;
// + (NSMutableCharacterSet *)alphanumericCharacterSet;
// + (NSMutableCharacterSet *)decomposableCharacterSet;
// + (NSMutableCharacterSet *)illegalCharacterSet;
// + (NSMutableCharacterSet *)punctuationCharacterSet;
// + (NSMutableCharacterSet *)capitalizedLetterCharacterSet;
// + (NSMutableCharacterSet *)symbolCharacterSet;
// + (NSMutableCharacterSet *)newlineCharacterSet __attribute__((availability(macosx,introduced=10.5)));
// + (NSMutableCharacterSet *)characterSetWithRange:(NSRange)aRange;
// + (NSMutableCharacterSet *)characterSetWithCharactersInString:(NSString *)aString;
// + (NSMutableCharacterSet *)characterSetWithBitmapRepresentation:(NSData *)data;
// + (NSMutableCharacterSet *)characterSetWithContentsOfFile:(NSString *)fName;
/* @end */
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
#ifndef _REWRITER_typedef_NSSet
#define _REWRITER_typedef_NSSet
typedef struct objc_object NSSet;
typedef struct {} _objc_exc_NSSet;
#endif
#ifndef _REWRITER_typedef_NSCoder
#define _REWRITER_typedef_NSCoder
typedef struct objc_object NSCoder;
typedef struct {} _objc_exc_NSCoder;
#endif
struct NSCoder_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (void)encodeValueOfObjCType:(const char *)type at:(const void *)addr;
// - (void)encodeDataObject:(NSData *)data;
// - (void)decodeValueOfObjCType:(const char *)type at:(void *)data;
// - (NSData *)decodeDataObject;
// - (NSInteger)versionForClassName:(NSString *)className;
/* @end */
// @interface NSCoder (NSExtendedCoder)
// - (void)encodeObject:(id)object;
// - (void)encodeRootObject:(id)rootObject;
// - (void)encodeBycopyObject:(id)anObject;
// - (void)encodeByrefObject:(id)anObject;
// - (void)encodeConditionalObject:(id)object;
// - (void)encodeValuesOfObjCTypes:(const char *)types, ...;
// - (void)encodeArrayOfObjCType:(const char *)type count:(NSUInteger)count at:(const void *)array;
// - (void)encodeBytes:(const void *)byteaddr length:(NSUInteger)length;
// - (id)decodeObject;
// - (void)decodeValuesOfObjCTypes:(const char *)types, ...;
// - (void)decodeArrayOfObjCType:(const char *)itemType count:(NSUInteger)count at:(void *)array;
// - (void *)decodeBytesWithReturnedLength:(NSUInteger *)lengthp __attribute__((objc_returns_inner_pointer));
// - (void)encodePropertyList:(id)aPropertyList;
// - (id)decodePropertyList;
// - (void)setObjectZone:(NSZone *)zone ;
// - (NSZone *)objectZone ;
// @property (readonly) unsigned int systemVersion;
// @property (readonly) BOOL allowsKeyedCoding;
// - (void)encodeObject:(id)objv forKey:(NSString *)key;
// - (void)encodeConditionalObject:(id)objv forKey:(NSString *)key;
// - (void)encodeBool:(BOOL)boolv forKey:(NSString *)key;
// - (void)encodeInt:(int)intv forKey:(NSString *)key;
// - (void)encodeInt32:(int32_t)intv forKey:(NSString *)key;
// - (void)encodeInt64:(int64_t)intv forKey:(NSString *)key;
// - (void)encodeFloat:(float)realv forKey:(NSString *)key;
// - (void)encodeDouble:(double)realv forKey:(NSString *)key;
// - (void)encodeBytes:(const uint8_t *)bytesp length:(NSUInteger)lenv forKey:(NSString *)key;
// - (BOOL)containsValueForKey:(NSString *)key;
// - (id)decodeObjectForKey:(NSString *)key;
// - (BOOL)decodeBoolForKey:(NSString *)key;
// - (int)decodeIntForKey:(NSString *)key;
// - (int32_t)decodeInt32ForKey:(NSString *)key;
// - (int64_t)decodeInt64ForKey:(NSString *)key;
// - (float)decodeFloatForKey:(NSString *)key;
// - (double)decodeDoubleForKey:(NSString *)key;
// - (const uint8_t *)decodeBytesForKey:(NSString *)key returnedLength:(NSUInteger *)lengthp __attribute__((objc_returns_inner_pointer));
// - (void)encodeInteger:(NSInteger)intv forKey:(NSString *)key __attribute__((availability(macosx,introduced=10.5)));
// - (NSInteger)decodeIntegerForKey:(NSString *)key __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly) BOOL requiresSecureCoding __attribute__((availability(macosx,introduced=10.8)));
// - (id)decodeObjectOfClass:(Class)aClass forKey:(NSString *)key __attribute__((availability(macosx,introduced=10.8)));
// - (id)decodeObjectOfClasses:(NSSet *)classes forKey:(NSString *)key __attribute__((availability(macosx,introduced=10.8)));
// - (id)decodePropertyListForKey:(NSString *)key __attribute__((availability(macosx,introduced=10.8)));
// @property (readonly, copy) NSSet *allowedClasses __attribute__((availability(macosx,introduced=10.8)));
/* @end */
extern "C" NSObject *NXReadNSObjectFromCoder(NSCoder *decoder) __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// @interface NSCoder (NSTypedstreamCompatibility)
// - (void)encodeNXObject:(id)object __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (id)decodeNXObject __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
/* @end */
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
typedef NSUInteger NSDataReadingOptions; enum {
NSDataReadingMappedIfSafe = 1UL << 0,
NSDataReadingUncached = 1UL << 1,
NSDataReadingMappedAlways __attribute__((availability(macosx,introduced=10.7))) = 1UL << 3,
NSDataReadingMapped = NSDataReadingMappedIfSafe,
NSMappedRead = NSDataReadingMapped,
NSUncachedRead = NSDataReadingUncached
};
typedef NSUInteger NSDataWritingOptions; enum {
NSDataWritingAtomic = 1UL << 0,
NSDataWritingWithoutOverwriting __attribute__((availability(macosx,introduced=10.8))) = 1UL << 1,
NSDataWritingFileProtectionNone __attribute__((availability(macosx,unavailable))) = 0x10000000,
NSDataWritingFileProtectionComplete __attribute__((availability(macosx,unavailable))) = 0x20000000,
NSDataWritingFileProtectionCompleteUnlessOpen __attribute__((availability(macosx,unavailable))) = 0x30000000,
NSDataWritingFileProtectionCompleteUntilFirstUserAuthentication __attribute__((availability(macosx,unavailable))) = 0x40000000,
NSDataWritingFileProtectionMask __attribute__((availability(macosx,unavailable))) = 0xf0000000,
NSAtomicWrite = NSDataWritingAtomic
};
typedef NSUInteger NSDataSearchOptions; enum {
NSDataSearchBackwards = 1UL << 0,
NSDataSearchAnchored = 1UL << 1
} __attribute__((availability(macosx,introduced=10.6)));
typedef NSUInteger NSDataBase64EncodingOptions; enum {
NSDataBase64Encoding64CharacterLineLength = 1UL << 0,
NSDataBase64Encoding76CharacterLineLength = 1UL << 1,
NSDataBase64EncodingEndLineWithCarriageReturn = 1UL << 4,
NSDataBase64EncodingEndLineWithLineFeed = 1UL << 5,
} __attribute__((availability(macosx,introduced=10.9)));
typedef NSUInteger NSDataBase64DecodingOptions; enum {
NSDataBase64DecodingIgnoreUnknownCharacters = 1UL << 0
} __attribute__((availability(macosx,introduced=10.9)));
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
struct NSData_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly) NSUInteger length;
// @property (readonly) const void *bytes __attribute__((objc_returns_inner_pointer));
/* @end */
// @interface NSData (NSExtendedData)
// @property (readonly, copy) NSString *description;
// - (void)getBytes:(void *)buffer length:(NSUInteger)length;
// - (void)getBytes:(void *)buffer range:(NSRange)range;
// - (BOOL)isEqualToData:(NSData *)other;
// - (NSData *)subdataWithRange:(NSRange)range;
// - (BOOL)writeToFile:(NSString *)path atomically:(BOOL)useAuxiliaryFile;
// - (BOOL)writeToURL:(NSURL *)url atomically:(BOOL)atomically;
// - (BOOL)writeToFile:(NSString *)path options:(NSDataWritingOptions)writeOptionsMask error:(NSError **)errorPtr;
// - (BOOL)writeToURL:(NSURL *)url options:(NSDataWritingOptions)writeOptionsMask error:(NSError **)errorPtr;
// - (NSRange)rangeOfData:(NSData *)dataToFind options:(NSDataSearchOptions)mask range:(NSRange)searchRange __attribute__((availability(macosx,introduced=10.6)));
// - (void) enumerateByteRangesUsingBlock:(void (^)(const void *bytes, NSRange byteRange, BOOL *stop))block __attribute__((availability(macosx,introduced=10.9)));
/* @end */
// @interface NSData (NSDataCreation)
// + (instancetype)data;
// + (instancetype)dataWithBytes:(const void *)bytes length:(NSUInteger)length;
// + (instancetype)dataWithBytesNoCopy:(void *)bytes length:(NSUInteger)length;
// + (instancetype)dataWithBytesNoCopy:(void *)bytes length:(NSUInteger)length freeWhenDone:(BOOL)b;
// + (instancetype)dataWithContentsOfFile:(NSString *)path options:(NSDataReadingOptions)readOptionsMask error:(NSError **)errorPtr;
// + (instancetype)dataWithContentsOfURL:(NSURL *)url options:(NSDataReadingOptions)readOptionsMask error:(NSError **)errorPtr;
// + (instancetype)dataWithContentsOfFile:(NSString *)path;
// + (instancetype)dataWithContentsOfURL:(NSURL *)url;
// - (instancetype)initWithBytes:(const void *)bytes length:(NSUInteger)length;
// - (instancetype)initWithBytesNoCopy:(void *)bytes length:(NSUInteger)length;
// - (instancetype)initWithBytesNoCopy:(void *)bytes length:(NSUInteger)length freeWhenDone:(BOOL)b;
// - (instancetype)initWithBytesNoCopy:(void *)bytes length:(NSUInteger)length deallocator:(void (^)(void *bytes, NSUInteger length))deallocator __attribute__((availability(macosx,introduced=10.9)));
// - (instancetype)initWithContentsOfFile:(NSString *)path options:(NSDataReadingOptions)readOptionsMask error:(NSError **)errorPtr;
// - (instancetype)initWithContentsOfURL:(NSURL *)url options:(NSDataReadingOptions)readOptionsMask error:(NSError **)errorPtr;
// - (instancetype)initWithContentsOfFile:(NSString *)path;
// - (instancetype)initWithContentsOfURL:(NSURL *)url;
// - (instancetype)initWithData:(NSData *)data;
// + (instancetype)dataWithData:(NSData *)data;
/* @end */
// @interface NSData (NSDataBase64Encoding)
// - (instancetype)initWithBase64EncodedString:(NSString *)base64String options:(NSDataBase64DecodingOptions)options __attribute__((availability(macosx,introduced=10.9)));
// - (NSString *)base64EncodedStringWithOptions:(NSDataBase64EncodingOptions)options __attribute__((availability(macosx,introduced=10.9)));
// - (instancetype)initWithBase64EncodedData:(NSData *)base64Data options:(NSDataBase64DecodingOptions)options __attribute__((availability(macosx,introduced=10.9)));
// - (NSData *)base64EncodedDataWithOptions:(NSDataBase64EncodingOptions)options __attribute__((availability(macosx,introduced=10.9)));
/* @end */
// @interface NSData (NSDeprecated)
// - (void)getBytes:(void *)buffer __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.10,message="" "This method is unsafe because it could potentially cause buffer overruns. Use -getBytes:length: instead.")));
// + (id)dataWithContentsOfMappedFile:(NSString *)path __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.10,message="" "Use +dataWithContentsOfURL:options:error: and NSDataReadingMappedIfSafe or NSDataReadingMappedAlways instead.")));
// - (id)initWithContentsOfMappedFile:(NSString *)path __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.10,message="" "Use -initWithContentsOfURL:options:error: and NSDataReadingMappedIfSafe or NSDataReadingMappedAlways instead.")));
// - (id)initWithBase64Encoding:(NSString *)base64String __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.9,message="" )));
// - (NSString *)base64Encoding __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.9,message="" )));
/* @end */
#ifndef _REWRITER_typedef_NSMutableData
#define _REWRITER_typedef_NSMutableData
typedef struct objc_object NSMutableData;
typedef struct {} _objc_exc_NSMutableData;
#endif
struct NSMutableData_IMPL {
struct NSData_IMPL NSData_IVARS;
};
// @property (readonly) void *mutableBytes __attribute__((objc_returns_inner_pointer));
// @property NSUInteger length;
/* @end */
// @interface NSMutableData (NSExtendedMutableData)
// - (void)appendBytes:(const void *)bytes length:(NSUInteger)length;
// - (void)appendData:(NSData *)other;
// - (void)increaseLengthBy:(NSUInteger)extraLength;
// - (void)replaceBytesInRange:(NSRange)range withBytes:(const void *)bytes;
// - (void)resetBytesInRange:(NSRange)range;
// - (void)setData:(NSData *)data;
// - (void)replaceBytesInRange:(NSRange)range withBytes:(const void *)replacementBytes length:(NSUInteger)replacementLength;
/* @end */
// @interface NSMutableData (NSMutableDataCreation)
// + (instancetype)dataWithCapacity:(NSUInteger)aNumItems;
// + (instancetype)dataWithLength:(NSUInteger)length;
// - (instancetype)initWithCapacity:(NSUInteger)capacity;
// - (instancetype)initWithLength:(NSUInteger)length;
/* @end */
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.6)))
#ifndef _REWRITER_typedef_NSPurgeableData
#define _REWRITER_typedef_NSPurgeableData
typedef struct objc_object NSPurgeableData;
typedef struct {} _objc_exc_NSPurgeableData;
#endif
struct NSPurgeableData_IMPL {
struct NSMutableData_IMPL NSMutableData_IVARS;
NSUInteger _length;
int32_t _accessCount;
uint8_t _private[32];
void *_reserved;
};
/* @end */
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
// @class NSAttributedString;
#ifndef _REWRITER_typedef_NSAttributedString
#define _REWRITER_typedef_NSAttributedString
typedef struct objc_object NSAttributedString;
typedef struct {} _objc_exc_NSAttributedString;
#endif
// @class NSDictionary;
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
typedef NSInteger NSFormattingContext; enum {
NSFormattingContextUnknown = 0,
NSFormattingContextDynamic = 1,
NSFormattingContextStandalone = 2,
NSFormattingContextListItem = 3,
NSFormattingContextBeginningOfSentence = 4,
NSFormattingContextMiddleOfSentence = 5,
} __attribute__((availability(macosx,introduced=10.10)));
typedef NSInteger NSFormattingUnitStyle; enum {
NSFormattingUnitStyleShort = 1,
NSFormattingUnitStyleMedium,
NSFormattingUnitStyleLong,
} __attribute__((availability(macosx,introduced=10.10)));
#ifndef _REWRITER_typedef_NSFormatter
#define _REWRITER_typedef_NSFormatter
typedef struct objc_object NSFormatter;
typedef struct {} _objc_exc_NSFormatter;
#endif
struct NSFormatter_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (NSString *)stringForObjectValue:(id)obj;
// - (NSAttributedString *)attributedStringForObjectValue:(id)obj withDefaultAttributes:(NSDictionary *)attrs;
// - (NSString *)editingStringForObjectValue:(id)obj;
// - (BOOL)getObjectValue:(out id *)obj forString:(NSString *)string errorDescription:(out NSString **)error;
// - (BOOL)isPartialStringValid:(NSString *)partialString newEditingString:(NSString **)newString errorDescription:(NSString **)error;
// - (BOOL)isPartialStringValid:(NSString **)partialStringPtr proposedSelectedRange:(NSRangePointer)proposedSelRangePtr originalString:(NSString *)origString originalSelectedRange:(NSRange)origSelRange errorDescription:(NSString **)error;
/* @end */
// @class NSLocale;
#ifndef _REWRITER_typedef_NSLocale
#define _REWRITER_typedef_NSLocale
typedef struct objc_object NSLocale;
typedef struct {} _objc_exc_NSLocale;
#endif
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
#ifndef _REWRITER_typedef_NSCalendar
#define _REWRITER_typedef_NSCalendar
typedef struct objc_object NSCalendar;
typedef struct {} _objc_exc_NSCalendar;
#endif
#ifndef _REWRITER_typedef_NSTimeZone
#define _REWRITER_typedef_NSTimeZone
typedef struct objc_object NSTimeZone;
typedef struct {} _objc_exc_NSTimeZone;
#endif
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSMutableDictionary
#define _REWRITER_typedef_NSMutableDictionary
typedef struct objc_object NSMutableDictionary;
typedef struct {} _objc_exc_NSMutableDictionary;
#endif
#ifndef _REWRITER_typedef_NSDateFormatter
#define _REWRITER_typedef_NSDateFormatter
typedef struct objc_object NSDateFormatter;
typedef struct {} _objc_exc_NSDateFormatter;
#endif
struct NSDateFormatter_IMPL {
struct NSFormatter_IMPL NSFormatter_IVARS;
NSMutableDictionary *_attributes;
CFDateFormatterRef _formatter;
NSUInteger _counter;
};
// @property NSFormattingContext formattingContext __attribute__((availability(macosx,introduced=10.10)));
// - (BOOL)getObjectValue:(out id *)obj forString:(NSString *)string range:(inout NSRange *)rangep error:(out NSError **)error;
// - (NSString *)stringFromDate:(NSDate *)date;
// - (NSDate *)dateFromString:(NSString *)string;
typedef NSUInteger NSDateFormatterStyle; enum {
NSDateFormatterNoStyle = kCFDateFormatterNoStyle,
NSDateFormatterShortStyle = kCFDateFormatterShortStyle,
NSDateFormatterMediumStyle = kCFDateFormatterMediumStyle,
NSDateFormatterLongStyle = kCFDateFormatterLongStyle,
NSDateFormatterFullStyle = kCFDateFormatterFullStyle
};
typedef NSUInteger NSDateFormatterBehavior; enum {
NSDateFormatterBehaviorDefault = 0,
NSDateFormatterBehavior10_0 = 1000,
NSDateFormatterBehavior10_4 = 1040,
};
// + (NSString *)localizedStringFromDate:(NSDate *)date dateStyle:(NSDateFormatterStyle)dstyle timeStyle:(NSDateFormatterStyle)tstyle __attribute__((availability(macosx,introduced=10.6)));
// + (NSString *)dateFormatFromTemplate:(NSString *)tmplate options:(NSUInteger)opts locale:(NSLocale *)locale __attribute__((availability(macosx,introduced=10.6)));
// + (NSDateFormatterBehavior)defaultFormatterBehavior;
// + (void)setDefaultFormatterBehavior:(NSDateFormatterBehavior)behavior;
// - (void) setLocalizedDateFormatFromTemplate:(NSString *)dateFormatTemplate __attribute__((availability(macosx,introduced=10.10)));
// @property (copy) NSString *dateFormat;
// @property NSDateFormatterStyle dateStyle;
// @property NSDateFormatterStyle timeStyle;
// @property (copy) NSLocale *locale;
// @property BOOL generatesCalendarDates;
// @property NSDateFormatterBehavior formatterBehavior;
// @property (copy) NSTimeZone *timeZone;
// @property (copy) NSCalendar *calendar;
// @property (getter=isLenient) BOOL lenient;
// @property (copy) NSDate *twoDigitStartDate;
// @property (copy) NSDate *defaultDate;
// @property (copy) NSArray *eraSymbols;
// @property (copy) NSArray *monthSymbols;
// @property (copy) NSArray *shortMonthSymbols;
// @property (copy) NSArray *weekdaySymbols;
// @property (copy) NSArray *shortWeekdaySymbols;
// @property (copy) NSString *AMSymbol;
// @property (copy) NSString *PMSymbol;
// @property (copy) NSArray *longEraSymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *veryShortMonthSymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *standaloneMonthSymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *shortStandaloneMonthSymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *veryShortStandaloneMonthSymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *veryShortWeekdaySymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *standaloneWeekdaySymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *shortStandaloneWeekdaySymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *veryShortStandaloneWeekdaySymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *quarterSymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *shortQuarterSymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *standaloneQuarterSymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSArray *shortStandaloneQuarterSymbols __attribute__((availability(macosx,introduced=10.5)));
// @property (copy) NSDate *gregorianStartDate __attribute__((availability(macosx,introduced=10.5)));
// @property BOOL doesRelativeDateFormatting __attribute__((availability(macosx,introduced=10.6)));
/* @end */
// @interface NSDateFormatter (NSDateFormatterCompatibility)
// - (id)initWithDateFormat:(NSString *)format allowNaturalLanguage:(BOOL)flag __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.9,message="" "Use -setDateFormat: as of OS X 10.9 to set the date format of a 10.0-style date formatter; but expect 10.0-style date formatting to be deprecated in the future as well")));
// - (BOOL)allowsNaturalLanguage __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.9,message="" "There is no replacement")));
/* @end */
// @class NSLocale;
#ifndef _REWRITER_typedef_NSLocale
#define _REWRITER_typedef_NSLocale
typedef struct objc_object NSLocale;
typedef struct {} _objc_exc_NSLocale;
#endif
#ifndef _REWRITER_typedef_NSCalendar
#define _REWRITER_typedef_NSCalendar
typedef struct objc_object NSCalendar;
typedef struct {} _objc_exc_NSCalendar;
#endif
#ifndef _REWRITER_typedef_NSTimeZone
#define _REWRITER_typedef_NSTimeZone
typedef struct objc_object NSTimeZone;
typedef struct {} _objc_exc_NSTimeZone;
#endif
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
typedef NSUInteger NSDateIntervalFormatterStyle; enum {
NSDateIntervalFormatterNoStyle = 0,
NSDateIntervalFormatterShortStyle = 1,
NSDateIntervalFormatterMediumStyle = 2,
NSDateIntervalFormatterLongStyle = 3,
NSDateIntervalFormatterFullStyle = 4
} __attribute__((availability(macosx,introduced=10.10)));
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.10)))
#ifndef _REWRITER_typedef_NSDateIntervalFormatter
#define _REWRITER_typedef_NSDateIntervalFormatter
typedef struct objc_object NSDateIntervalFormatter;
typedef struct {} _objc_exc_NSDateIntervalFormatter;
#endif
struct NSDateIntervalFormatter_IMPL {
struct NSFormatter_IMPL NSFormatter_IVARS;
NSLocale *_locale;
NSCalendar *_calendar;
NSTimeZone *_timeZone;
NSString *_dateTemplate;
NSString *_dateTemplateFromStyles;
void *_formatter;
NSDateIntervalFormatterStyle _dateStyle;
NSDateIntervalFormatterStyle _timeStyle;
BOOL _modified;
BOOL _useTemplate;
dispatch_semaphore_t _lock;
void *_reserved[4];
};
// @property (copy) NSLocale *locale;
// @property (copy) NSCalendar *calendar;
// @property (copy) NSTimeZone *timeZone;
// @property (copy) NSString *dateTemplate;
// @property NSDateIntervalFormatterStyle dateStyle;
// @property NSDateIntervalFormatterStyle timeStyle;
// - (NSString *)stringFromDate:(NSDate *)fromDate toDate:(NSDate *)toDate;
/* @end */
// @class NSNumberFormatter;
#ifndef _REWRITER_typedef_NSNumberFormatter
#define _REWRITER_typedef_NSNumberFormatter
typedef struct objc_object NSNumberFormatter;
typedef struct {} _objc_exc_NSNumberFormatter;
#endif
typedef NSInteger NSMassFormatterUnit; enum {
NSMassFormatterUnitGram = 11,
NSMassFormatterUnitKilogram = 14,
NSMassFormatterUnitOunce = (6 << 8) + 1,
NSMassFormatterUnitPound = (6 << 8) + 2,
NSMassFormatterUnitStone = (6 << 8) + 3,
} __attribute__((availability(macosx,introduced=10.10)));
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.10)))
#ifndef _REWRITER_typedef_NSMassFormatter
#define _REWRITER_typedef_NSMassFormatter
typedef struct objc_object NSMassFormatter;
typedef struct {} _objc_exc_NSMassFormatter;
#endif
struct NSMassFormatter_IMPL {
struct NSFormatter_IMPL NSFormatter_IVARS;
void *_formatter;
BOOL _isForPersonMassUse;
void *_reserved[2];
};
// @property (copy) NSNumberFormatter *numberFormatter;
// @property NSFormattingUnitStyle unitStyle;
// @property (getter = isForPersonMassUse) BOOL forPersonMassUse;
// - (NSString *)stringFromValue:(double)value unit:(NSMassFormatterUnit)unit;
// - (NSString *)stringFromKilograms:(double)numberInKilograms;
// - (NSString *)unitStringFromValue:(double)value unit:(NSMassFormatterUnit)unit;
// - (NSString *)unitStringFromKilograms:(double)numberInKilograms usedUnit:(NSMassFormatterUnit *)unitp;
// - (BOOL)getObjectValue:(out id *)obj forString:(NSString *)string errorDescription:(out NSString **)error;
/* @end */
typedef NSInteger NSLengthFormatterUnit; enum {
NSLengthFormatterUnitMillimeter = 8,
NSLengthFormatterUnitCentimeter = 9,
NSLengthFormatterUnitMeter = 11,
NSLengthFormatterUnitKilometer = 14,
NSLengthFormatterUnitInch = (5 << 8) + 1,
NSLengthFormatterUnitFoot = (5 << 8) + 2,
NSLengthFormatterUnitYard = (5 << 8) + 3,
NSLengthFormatterUnitMile = (5 << 8) + 4,
} __attribute__((availability(macosx,introduced=10.10)));
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.10)))
#ifndef _REWRITER_typedef_NSLengthFormatter
#define _REWRITER_typedef_NSLengthFormatter
typedef struct objc_object NSLengthFormatter;
typedef struct {} _objc_exc_NSLengthFormatter;
#endif
struct NSLengthFormatter_IMPL {
struct NSFormatter_IMPL NSFormatter_IVARS;
void *_formatter;
BOOL _isForPersonHeight;
void *_reserved[2];
};
// @property (copy) NSNumberFormatter *numberFormatter;
// @property NSFormattingUnitStyle unitStyle;
// @property (getter = isForPersonHeightUse) BOOL forPersonHeightUse;
// - (NSString *)stringFromValue:(double)value unit:(NSLengthFormatterUnit)unit;
// - (NSString *)stringFromMeters:(double)numberInMeters;
// - (NSString *)unitStringFromValue:(double)value unit:(NSLengthFormatterUnit)unit;
// - (NSString *)unitStringFromMeters:(double)numberInMeters usedUnit:(NSLengthFormatterUnit *)unitp;
// - (BOOL)getObjectValue:(out id *)obj forString:(NSString *)string errorDescription:(out NSString **)error;
/* @end */
typedef NSInteger NSEnergyFormatterUnit; enum {
NSEnergyFormatterUnitJoule = 11,
NSEnergyFormatterUnitKilojoule = 14,
NSEnergyFormatterUnitCalorie = (7 << 8) + 1,
NSEnergyFormatterUnitKilocalorie = (7 << 8) + 2,
} __attribute__((availability(macosx,introduced=10.10)));
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.10)))
#ifndef _REWRITER_typedef_NSEnergyFormatter
#define _REWRITER_typedef_NSEnergyFormatter
typedef struct objc_object NSEnergyFormatter;
typedef struct {} _objc_exc_NSEnergyFormatter;
#endif
struct NSEnergyFormatter_IMPL {
struct NSFormatter_IMPL NSFormatter_IVARS;
void *_formatter;
BOOL _isForFoodEnergyUse;
void *_reserved[2];
};
// @property (copy) NSNumberFormatter *numberFormatter;
// @property NSFormattingUnitStyle unitStyle;
// @property (getter = isForFoodEnergyUse) BOOL forFoodEnergyUse;
// - (NSString *)stringFromValue:(double)value unit:(NSEnergyFormatterUnit)unit;
// - (NSString *)stringFromJoules:(double)numberInJoules;
// - (NSString *)unitStringFromValue:(double)value unit:(NSEnergyFormatterUnit)unit;
// - (NSString *)unitStringFromJoules:(double)numberInJoules usedUnit:(NSEnergyFormatterUnit *)unitp;
// - (BOOL)getObjectValue:(out id *)obj forString:(NSString *)string errorDescription:(out NSString **)error;
/* @end */
// @class NSDictionary;
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
typedef NSUInteger NSRoundingMode; enum {
NSRoundPlain,
NSRoundDown,
NSRoundUp,
NSRoundBankers
};
typedef NSUInteger NSCalculationError; enum {
NSCalculationNoError = 0,
NSCalculationLossOfPrecision,
NSCalculationUnderflow,
NSCalculationOverflow,
NSCalculationDivideByZero
};
typedef struct {
signed int _exponent:8;
unsigned int _length:4;
unsigned int _isNegative:1;
unsigned int _isCompact:1;
unsigned int _reserved:18;
unsigned short _mantissa[(8)];
} NSDecimal;
static __inline__ __attribute__((always_inline)) BOOL NSDecimalIsNotANumber(const NSDecimal *dcm)
{ return ((dcm->_length == 0) && dcm->_isNegative); }
extern "C" void NSDecimalCopy(NSDecimal *destination, const NSDecimal *source);
extern "C" void NSDecimalCompact(NSDecimal *number);
extern "C" NSComparisonResult NSDecimalCompare(const NSDecimal *leftOperand, const NSDecimal *rightOperand);
extern "C" void NSDecimalRound(NSDecimal *result, const NSDecimal *number, NSInteger scale, NSRoundingMode roundingMode);
extern "C" NSCalculationError NSDecimalNormalize(NSDecimal *number1, NSDecimal *number2, NSRoundingMode roundingMode);
extern "C" NSCalculationError NSDecimalAdd(NSDecimal *result, const NSDecimal *leftOperand, const NSDecimal *rightOperand, NSRoundingMode roundingMode);
extern "C" NSCalculationError NSDecimalSubtract(NSDecimal *result, const NSDecimal *leftOperand, const NSDecimal *rightOperand, NSRoundingMode roundingMode);
extern "C" NSCalculationError NSDecimalMultiply(NSDecimal *result, const NSDecimal *leftOperand, const NSDecimal *rightOperand, NSRoundingMode roundingMode);
extern "C" NSCalculationError NSDecimalDivide(NSDecimal *result, const NSDecimal *leftOperand, const NSDecimal *rightOperand, NSRoundingMode roundingMode);
extern "C" NSCalculationError NSDecimalPower(NSDecimal *result, const NSDecimal *number, NSUInteger power, NSRoundingMode roundingMode);
extern "C" NSCalculationError NSDecimalMultiplyByPowerOf10(NSDecimal *result, const NSDecimal *number, short power, NSRoundingMode roundingMode);
extern "C" NSString *NSDecimalString(const NSDecimal *dcm, id locale);
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSCharacterSet
#define _REWRITER_typedef_NSCharacterSet
typedef struct objc_object NSCharacterSet;
typedef struct {} _objc_exc_NSCharacterSet;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSScanner
#define _REWRITER_typedef_NSScanner
typedef struct objc_object NSScanner;
typedef struct {} _objc_exc_NSScanner;
#endif
struct NSScanner_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly, copy) NSString *string;
// @property NSUInteger scanLocation;
// @property (copy) NSCharacterSet *charactersToBeSkipped;
// @property BOOL caseSensitive;
// @property (retain) id locale;
// - (instancetype)initWithString:(NSString *)string __attribute__((objc_designated_initializer));
/* @end */
// @interface NSScanner (NSExtendedScanner)
// - (BOOL)scanInt:(int *)result;
// - (BOOL)scanInteger:(NSInteger *)result __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)scanLongLong:(long long *)result;
// - (BOOL)scanUnsignedLongLong:(unsigned long long *)result __attribute__((availability(macosx,introduced=10.9)));
// - (BOOL)scanFloat:(float *)result;
// - (BOOL)scanDouble:(double *)result;
// - (BOOL)scanHexInt:(unsigned *)result;
// - (BOOL)scanHexLongLong:(unsigned long long *)result __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)scanHexFloat:(float *)result __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)scanHexDouble:(double *)result __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)scanString:(NSString *)string intoString:(NSString **)result;
// - (BOOL)scanCharactersFromSet:(NSCharacterSet *)set intoString:(NSString **)result;
// - (BOOL)scanUpToString:(NSString *)string intoString:(NSString **)result;
// - (BOOL)scanUpToCharactersFromSet:(NSCharacterSet *)set intoString:(NSString **)result;
// @property (getter=isAtEnd, readonly) BOOL atEnd;
// + (instancetype)scannerWithString:(NSString *)string;
// + (id)localizedScannerWithString:(NSString *)string;
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSSet
#define _REWRITER_typedef_NSSet
typedef struct objc_object NSSet;
typedef struct {} _objc_exc_NSSet;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
struct NSDictionary_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly) NSUInteger count;
// - (id)objectForKey:(id)aKey;
// - (NSEnumerator *)keyEnumerator;
// - (instancetype)init __attribute__((objc_designated_initializer));
// - (instancetype)initWithObjects:(const id [])objects forKeys:(const id <NSCopying> [])keys count:(NSUInteger)cnt __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSDictionary (NSExtendedDictionary)
// @property (readonly, copy) NSArray *allKeys;
// - (NSArray *)allKeysForObject:(id)anObject;
// @property (readonly, copy) NSArray *allValues;
// @property (readonly, copy) NSString *description;
// @property (readonly, copy) NSString *descriptionInStringsFileFormat;
// - (NSString *)descriptionWithLocale:(id)locale;
// - (NSString *)descriptionWithLocale:(id)locale indent:(NSUInteger)level;
// - (BOOL)isEqualToDictionary:(NSDictionary *)otherDictionary;
// - (NSEnumerator *)objectEnumerator;
// - (NSArray *)objectsForKeys:(NSArray *)keys notFoundMarker:(id)marker;
// - (BOOL)writeToFile:(NSString *)path atomically:(BOOL)useAuxiliaryFile;
// - (BOOL)writeToURL:(NSURL *)url atomically:(BOOL)atomically;
// - (NSArray *)keysSortedByValueUsingSelector:(SEL)comparator;
// - (void)getObjects:(id [])objects andKeys:(id [])keys;
// - (id)objectForKeyedSubscript:(id)key __attribute__((availability(macosx,introduced=10.8)));
// - (void)enumerateKeysAndObjectsUsingBlock:(void (^)(id key, id obj, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// - (void)enumerateKeysAndObjectsWithOptions:(NSEnumerationOptions)opts usingBlock:(void (^)(id key, id obj, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// - (NSArray *)keysSortedByValueUsingComparator:(NSComparator)cmptr __attribute__((availability(macosx,introduced=10.6)));
// - (NSArray *)keysSortedByValueWithOptions:(NSSortOptions)opts usingComparator:(NSComparator)cmptr __attribute__((availability(macosx,introduced=10.6)));
// - (NSSet *)keysOfEntriesPassingTest:(BOOL (^)(id key, id obj, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSSet *)keysOfEntriesWithOptions:(NSEnumerationOptions)opts passingTest:(BOOL (^)(id key, id obj, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
/* @end */
// @interface NSDictionary (NSDictionaryCreation)
// + (instancetype)dictionary;
// + (instancetype)dictionaryWithObject:(id)object forKey:(id <NSCopying>)key;
// + (instancetype)dictionaryWithObjects:(const id [])objects forKeys:(const id <NSCopying> [])keys count:(NSUInteger)cnt;
// + (instancetype)dictionaryWithObjectsAndKeys:(id)firstObject, ... __attribute__((sentinel(0,1)));
// + (instancetype)dictionaryWithDictionary:(NSDictionary *)dict;
// + (instancetype)dictionaryWithObjects:(NSArray *)objects forKeys:(NSArray *)keys;
// - (instancetype)initWithObjectsAndKeys:(id)firstObject, ... __attribute__((sentinel(0,1)));
// - (instancetype)initWithDictionary:(NSDictionary *)otherDictionary;
// - (instancetype)initWithDictionary:(NSDictionary *)otherDictionary copyItems:(BOOL)flag;
// - (instancetype)initWithObjects:(NSArray *)objects forKeys:(NSArray *)keys;
// + (NSDictionary *)dictionaryWithContentsOfFile:(NSString *)path;
// + (NSDictionary *)dictionaryWithContentsOfURL:(NSURL *)url;
// - (NSDictionary *)initWithContentsOfFile:(NSString *)path;
// - (NSDictionary *)initWithContentsOfURL:(NSURL *)url;
/* @end */
#ifndef _REWRITER_typedef_NSMutableDictionary
#define _REWRITER_typedef_NSMutableDictionary
typedef struct objc_object NSMutableDictionary;
typedef struct {} _objc_exc_NSMutableDictionary;
#endif
struct NSMutableDictionary_IMPL {
struct NSDictionary_IMPL NSDictionary_IVARS;
};
// - (void)removeObjectForKey:(id)aKey;
// - (void)setObject:(id)anObject forKey:(id <NSCopying>)aKey;
// - (instancetype)init __attribute__((objc_designated_initializer));
// - (instancetype)initWithCapacity:(NSUInteger)numItems __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSMutableDictionary (NSExtendedMutableDictionary)
// - (void)addEntriesFromDictionary:(NSDictionary *)otherDictionary;
// - (void)removeAllObjects;
// - (void)removeObjectsForKeys:(NSArray *)keyArray;
// - (void)setDictionary:(NSDictionary *)otherDictionary;
// - (void)setObject:(id)obj forKeyedSubscript:(id <NSCopying>)key __attribute__((availability(macosx,introduced=10.8)));
/* @end */
// @interface NSMutableDictionary (NSMutableDictionaryCreation)
// + (instancetype)dictionaryWithCapacity:(NSUInteger)numItems;
// + (NSMutableDictionary *)dictionaryWithContentsOfFile:(NSString *)path;
// + (NSMutableDictionary *)dictionaryWithContentsOfURL:(NSURL *)url;
// - (NSMutableDictionary *)initWithContentsOfFile:(NSString *)path;
// - (NSMutableDictionary *)initWithContentsOfURL:(NSURL *)url;
/* @end */
// @interface NSDictionary (NSSharedKeySetDictionary)
// + (id)sharedKeySetForKeys:(NSArray *)keys __attribute__((availability(macosx,introduced=10.8)));
/* @end */
// @interface NSMutableDictionary (NSSharedKeySetDictionary)
// + (NSMutableDictionary *)dictionaryWithSharedKeySet:(id)keyset __attribute__((availability(macosx,introduced=10.8)));
/* @end */
extern "C" NSString * const NSDecimalNumberExactnessException;
extern "C" NSString * const NSDecimalNumberOverflowException;
extern "C" NSString * const NSDecimalNumberUnderflowException;
extern "C" NSString * const NSDecimalNumberDivideByZeroException;
// @class NSDecimalNumber;
#ifndef _REWRITER_typedef_NSDecimalNumber
#define _REWRITER_typedef_NSDecimalNumber
typedef struct objc_object NSDecimalNumber;
typedef struct {} _objc_exc_NSDecimalNumber;
#endif
// @protocol NSDecimalNumberBehaviors
// - (NSRoundingMode)roundingMode;
// - (short)scale;
// - (NSDecimalNumber *)exceptionDuringOperation:(SEL)operation error:(NSCalculationError)error leftOperand:(NSDecimalNumber *)leftOperand rightOperand:(NSDecimalNumber *)rightOperand;
/* @end */
#ifndef _REWRITER_typedef_NSDecimalNumber
#define _REWRITER_typedef_NSDecimalNumber
typedef struct objc_object NSDecimalNumber;
typedef struct {} _objc_exc_NSDecimalNumber;
#endif
struct NSDecimalNumber__T_1 {
int _exponent : 8;
unsigned int _length : 4;
unsigned int _isNegative : 1;
unsigned int _isCompact : 1;
unsigned int _reserved : 1;
unsigned int _hasExternalRefCount : 1;
unsigned int _refs : 16;
} ;
struct NSDecimalNumber_IMPL {
struct NSNumber_IMPL NSNumber_IVARS;
struct NSDecimalNumber__T_1 NSDecimalNumber__GRBF_1;
unsigned short _mantissa[0];
};
// - (instancetype)initWithMantissa:(unsigned long long)mantissa exponent:(short)exponent isNegative:(BOOL)flag;
// - (instancetype)initWithDecimal:(NSDecimal)dcm __attribute__((objc_designated_initializer));
// - (instancetype)initWithString:(NSString *)numberValue;
// - (instancetype)initWithString:(NSString *)numberValue locale:(id)locale;
// - (NSString *)descriptionWithLocale:(id)locale;
// @property (readonly) NSDecimal decimalValue;
// + (NSDecimalNumber *)decimalNumberWithMantissa:(unsigned long long)mantissa exponent:(short)exponent isNegative:(BOOL)flag;
// + (NSDecimalNumber *)decimalNumberWithDecimal:(NSDecimal)dcm;
// + (NSDecimalNumber *)decimalNumberWithString:(NSString *)numberValue;
// + (NSDecimalNumber *)decimalNumberWithString:(NSString *)numberValue locale:(id)locale;
// + (NSDecimalNumber *)zero;
// + (NSDecimalNumber *)one;
// + (NSDecimalNumber *)minimumDecimalNumber;
// + (NSDecimalNumber *)maximumDecimalNumber;
// + (NSDecimalNumber *)notANumber;
// - (NSDecimalNumber *)decimalNumberByAdding:(NSDecimalNumber *)decimalNumber;
// - (NSDecimalNumber *)decimalNumberByAdding:(NSDecimalNumber *)decimalNumber withBehavior:(id <NSDecimalNumberBehaviors>)behavior;
// - (NSDecimalNumber *)decimalNumberBySubtracting:(NSDecimalNumber *)decimalNumber;
// - (NSDecimalNumber *)decimalNumberBySubtracting:(NSDecimalNumber *)decimalNumber withBehavior:(id <NSDecimalNumberBehaviors>)behavior;
// - (NSDecimalNumber *)decimalNumberByMultiplyingBy:(NSDecimalNumber *)decimalNumber;
// - (NSDecimalNumber *)decimalNumberByMultiplyingBy:(NSDecimalNumber *)decimalNumber withBehavior:(id <NSDecimalNumberBehaviors>)behavior;
// - (NSDecimalNumber *)decimalNumberByDividingBy:(NSDecimalNumber *)decimalNumber;
// - (NSDecimalNumber *)decimalNumberByDividingBy:(NSDecimalNumber *)decimalNumber withBehavior:(id <NSDecimalNumberBehaviors>)behavior;
// - (NSDecimalNumber *)decimalNumberByRaisingToPower:(NSUInteger)power;
// - (NSDecimalNumber *)decimalNumberByRaisingToPower:(NSUInteger)power withBehavior:(id <NSDecimalNumberBehaviors>)behavior;
// - (NSDecimalNumber *)decimalNumberByMultiplyingByPowerOf10:(short)power;
// - (NSDecimalNumber *)decimalNumberByMultiplyingByPowerOf10:(short)power withBehavior:(id <NSDecimalNumberBehaviors>)behavior;
// - (NSDecimalNumber *)decimalNumberByRoundingAccordingToBehavior:(id <NSDecimalNumberBehaviors>)behavior;
// - (NSComparisonResult)compare:(NSNumber *)decimalNumber;
// + (void)setDefaultBehavior:(id <NSDecimalNumberBehaviors>)behavior;
// + (id <NSDecimalNumberBehaviors>)defaultBehavior;
// @property (readonly) const char *objCType __attribute__((objc_returns_inner_pointer));
// @property (readonly) double doubleValue;
/* @end */
#ifndef _REWRITER_typedef_NSDecimalNumberHandler
#define _REWRITER_typedef_NSDecimalNumberHandler
typedef struct objc_object NSDecimalNumberHandler;
typedef struct {} _objc_exc_NSDecimalNumberHandler;
#endif
struct NSDecimalNumberHandler__T_1 {
int _scale : 16;
unsigned int _roundingMode : 3;
unsigned int _raiseOnExactness : 1;
unsigned int _raiseOnOverflow : 1;
unsigned int _raiseOnUnderflow : 1;
unsigned int _raiseOnDivideByZero : 1;
unsigned int _unused : 9;
} ;
struct NSDecimalNumberHandler_IMPL {
struct NSObject_IMPL NSObject_IVARS;
struct NSDecimalNumberHandler__T_1 NSDecimalNumberHandler__GRBF_1;
void *_reserved2;
void *_reserved;
};
// + (NSDecimalNumberHandler *)defaultDecimalNumberHandler;
// - (instancetype)initWithRoundingMode:(NSRoundingMode)roundingMode scale:(short)scale raiseOnExactness:(BOOL)exact raiseOnOverflow:(BOOL)overflow raiseOnUnderflow:(BOOL)underflow raiseOnDivideByZero:(BOOL)divideByZero __attribute__((objc_designated_initializer));
// + (instancetype)decimalNumberHandlerWithRoundingMode:(NSRoundingMode)roundingMode scale:(short)scale raiseOnExactness:(BOOL)exact raiseOnOverflow:(BOOL)overflow raiseOnUnderflow:(BOOL)underflow raiseOnDivideByZero:(BOOL)divideByZero;
/* @end */
// @interface NSNumber (NSDecimalNumberExtensions)
// @property (readonly) NSDecimal decimalValue;
/* @end */
// @interface NSScanner (NSDecimalNumberScanning)
// - (BOOL)scanDecimal:(NSDecimal *)dcm;
/* @end */
// @class NSDictionary;
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
extern "C" NSString *const NSCocoaErrorDomain;
extern "C" NSString *const NSPOSIXErrorDomain;
extern "C" NSString *const NSOSStatusErrorDomain;
extern "C" NSString *const NSMachErrorDomain;
extern "C" NSString *const NSUnderlyingErrorKey;
extern "C" NSString *const NSLocalizedDescriptionKey;
extern "C" NSString *const NSLocalizedFailureReasonErrorKey ;
extern "C" NSString *const NSLocalizedRecoverySuggestionErrorKey;
extern "C" NSString *const NSLocalizedRecoveryOptionsErrorKey ;
extern "C" NSString *const NSRecoveryAttempterErrorKey;
extern "C" NSString *const NSHelpAnchorErrorKey ;
extern "C" NSString *const NSStringEncodingErrorKey ;
extern "C" NSString *const NSURLErrorKey ;
extern "C" NSString *const NSFilePathErrorKey ;
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
struct NSError_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *_reserved;
NSInteger _code;
NSString *_domain;
NSDictionary *_userInfo;
};
// - (instancetype)initWithDomain:(NSString *)domain code:(NSInteger)code userInfo:(NSDictionary *)dict __attribute__((objc_designated_initializer));
// + (instancetype)errorWithDomain:(NSString *)domain code:(NSInteger)code userInfo:(NSDictionary *)dict;
// @property (readonly, copy) NSString *domain;
// @property (readonly) NSInteger code;
// @property (readonly, copy) NSDictionary *userInfo;
// @property (readonly, copy) NSString *localizedDescription;
// @property (readonly, copy) NSString *localizedFailureReason;
// @property (readonly, copy) NSString *localizedRecoverySuggestion;
// @property (readonly, copy) NSArray *localizedRecoveryOptions;
// @property (readonly, retain) id recoveryAttempter;
// @property (readonly, copy) NSString *helpAnchor;
/* @end */
// @interface NSObject(NSErrorRecoveryAttempting)
// - (void)attemptRecoveryFromError:(NSError *)error optionIndex:(NSUInteger)recoveryOptionIndex delegate:(id)delegate didRecoverSelector:(SEL)didRecoverSelector contextInfo:(void *)contextInfo;
// - (BOOL)attemptRecoveryFromError:(NSError *)error optionIndex:(NSUInteger)recoveryOptionIndex;
/* @end */
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
extern "C" NSString * const NSGenericException;
extern "C" NSString * const NSRangeException;
extern "C" NSString * const NSInvalidArgumentException;
extern "C" NSString * const NSInternalInconsistencyException;
extern "C" NSString * const NSMallocException;
extern "C" NSString * const NSObjectInaccessibleException;
extern "C" NSString * const NSObjectNotAvailableException;
extern "C" NSString * const NSDestinationInvalidException;
extern "C" NSString * const NSPortTimeoutException;
extern "C" NSString * const NSInvalidSendPortException;
extern "C" NSString * const NSInvalidReceivePortException;
extern "C" NSString * const NSPortSendException;
extern "C" NSString * const NSPortReceiveException;
extern "C" NSString * const NSOldStyleException;
__attribute__((__objc_exception__))
#ifndef _REWRITER_typedef_NSException
#define _REWRITER_typedef_NSException
typedef struct objc_object NSException;
typedef struct {} _objc_exc_NSException;
#endif
struct NSException_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSString *name;
NSString *reason;
NSDictionary *userInfo;
id reserved;
};
// + (NSException *)exceptionWithName:(NSString *)name reason:(NSString *)reason userInfo:(NSDictionary *)userInfo;
// - (instancetype)initWithName:(NSString *)aName reason:(NSString *)aReason userInfo:(NSDictionary *)aUserInfo __attribute__((objc_designated_initializer));
// @property (readonly, copy) NSString *name;
// @property (readonly, copy) NSString *reason;
// @property (readonly, copy) NSDictionary *userInfo;
// @property (readonly, copy) NSArray *callStackReturnAddresses __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly, copy) NSArray *callStackSymbols __attribute__((availability(macosx,introduced=10.6)));
// - (void)raise;
/* @end */
// @interface NSException (NSExceptionRaisingConveniences)
// + (void)raise:(NSString *)name format:(NSString *)format, ... __attribute__((format(__NSString__, 2, 3)));
// + (void)raise:(NSString *)name format:(NSString *)format arguments:(va_list)argList __attribute__((format(__NSString__, 2, 0)));
/* @end */
typedef void NSUncaughtExceptionHandler(NSException *exception);
extern "C" NSUncaughtExceptionHandler *NSGetUncaughtExceptionHandler(void);
extern "C" void NSSetUncaughtExceptionHandler(NSUncaughtExceptionHandler *);
// @class NSAssertionHandler;
#ifndef _REWRITER_typedef_NSAssertionHandler
#define _REWRITER_typedef_NSAssertionHandler
typedef struct objc_object NSAssertionHandler;
typedef struct {} _objc_exc_NSAssertionHandler;
#endif
extern "C" NSString * const NSAssertionHandlerKey __attribute__((availability(macosx,introduced=10.6)));
#ifndef _REWRITER_typedef_NSAssertionHandler
#define _REWRITER_typedef_NSAssertionHandler
typedef struct objc_object NSAssertionHandler;
typedef struct {} _objc_exc_NSAssertionHandler;
#endif
struct NSAssertionHandler_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *_reserved;
};
// + (NSAssertionHandler *)currentHandler;
// - (void)handleFailureInMethod:(SEL)selector object:(id)object file:(NSString *)fileName lineNumber:(NSInteger)line description:(NSString *)format,... __attribute__((format(__NSString__, 5, 6)));
// - (void)handleFailureInFunction:(NSString *)functionName file:(NSString *)fileName lineNumber:(NSInteger)line description:(NSString *)format,... __attribute__((format(__NSString__, 4, 5)));
/* @end */
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
#ifndef _REWRITER_typedef_NSFileHandle
#define _REWRITER_typedef_NSFileHandle
typedef struct objc_object NSFileHandle;
typedef struct {} _objc_exc_NSFileHandle;
#endif
struct NSFileHandle_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly, copy) NSData *availableData;
// - (NSData *)readDataToEndOfFile;
// - (NSData *)readDataOfLength:(NSUInteger)length;
// - (void)writeData:(NSData *)data;
// @property (readonly) unsigned long long offsetInFile;
// - (unsigned long long)seekToEndOfFile;
// - (void)seekToFileOffset:(unsigned long long)offset;
// - (void)truncateFileAtOffset:(unsigned long long)offset;
// - (void)synchronizeFile;
// - (void)closeFile;
// - (instancetype)initWithFileDescriptor:(int)fd closeOnDealloc:(BOOL)closeopt __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)coder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSFileHandle (NSFileHandleCreation)
// + (NSFileHandle *)fileHandleWithStandardInput;
// + (NSFileHandle *)fileHandleWithStandardOutput;
// + (NSFileHandle *)fileHandleWithStandardError;
// + (NSFileHandle *)fileHandleWithNullDevice;
// + (instancetype)fileHandleForReadingAtPath:(NSString *)path;
// + (instancetype)fileHandleForWritingAtPath:(NSString *)path;
// + (instancetype)fileHandleForUpdatingAtPath:(NSString *)path;
// + (instancetype)fileHandleForReadingFromURL:(NSURL *)url error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// + (instancetype)fileHandleForWritingToURL:(NSURL *)url error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// + (instancetype)fileHandleForUpdatingURL:(NSURL *)url error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
/* @end */
extern "C" NSString * const NSFileHandleOperationException;
extern "C" NSString * const NSFileHandleReadCompletionNotification;
extern "C" NSString * const NSFileHandleReadToEndOfFileCompletionNotification;
extern "C" NSString * const NSFileHandleConnectionAcceptedNotification;
extern "C" NSString * const NSFileHandleDataAvailableNotification;
extern "C" NSString * const NSFileHandleNotificationDataItem;
extern "C" NSString * const NSFileHandleNotificationFileHandleItem;
extern "C" NSString * const NSFileHandleNotificationMonitorModes __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.7,message="" )));
// @interface NSFileHandle (NSFileHandleAsynchronousAccess)
// - (void)readInBackgroundAndNotifyForModes:(NSArray *)modes;
// - (void)readInBackgroundAndNotify;
// - (void)readToEndOfFileInBackgroundAndNotifyForModes:(NSArray *)modes;
// - (void)readToEndOfFileInBackgroundAndNotify;
// - (void)acceptConnectionInBackgroundAndNotifyForModes:(NSArray *)modes;
// - (void)acceptConnectionInBackgroundAndNotify;
// - (void)waitForDataInBackgroundAndNotifyForModes:(NSArray *)modes;
// - (void)waitForDataInBackgroundAndNotify;
// @property (copy) void (^readabilityHandler)(NSFileHandle *) __attribute__((availability(macosx,introduced=10.7)));
// @property (copy) void (^writeabilityHandler)(NSFileHandle *) __attribute__((availability(macosx,introduced=10.7)));
/* @end */
// @interface NSFileHandle (NSFileHandlePlatformSpecific)
// - (instancetype)initWithFileDescriptor:(int)fd;
// @property (readonly) int fileDescriptor;
/* @end */
#ifndef _REWRITER_typedef_NSPipe
#define _REWRITER_typedef_NSPipe
typedef struct objc_object NSPipe;
typedef struct {} _objc_exc_NSPipe;
#endif
struct NSPipe_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly, retain) NSFileHandle *fileHandleForReading;
// @property (readonly, retain) NSFileHandle *fileHandleForWriting;
// + (NSPipe *)pipe;
/* @end */
// @interface NSString (NSStringPathExtensions)
// + (NSString *)pathWithComponents:(NSArray *)components;
// @property (readonly, copy) NSArray *pathComponents;
// @property (getter=isAbsolutePath, readonly) BOOL absolutePath;
// @property (readonly, copy) NSString *lastPathComponent;
// @property (readonly, copy) NSString *stringByDeletingLastPathComponent;
// - (NSString *)stringByAppendingPathComponent:(NSString *)str;
// @property (readonly, copy) NSString *pathExtension;
// @property (readonly, copy) NSString *stringByDeletingPathExtension;
// - (NSString *)stringByAppendingPathExtension:(NSString *)str;
// @property (readonly, copy) NSString *stringByAbbreviatingWithTildeInPath;
// @property (readonly, copy) NSString *stringByExpandingTildeInPath;
// @property (readonly, copy) NSString *stringByStandardizingPath;
// @property (readonly, copy) NSString *stringByResolvingSymlinksInPath;
// - (NSArray *)stringsByAppendingPaths:(NSArray *)paths;
// - (NSUInteger)completePathIntoString:(NSString **)outputName caseSensitive:(BOOL)flag matchesIntoArray:(NSArray **)outputArray filterTypes:(NSArray *)filterTypes;
// @property (readonly) const char *fileSystemRepresentation __attribute__((objc_returns_inner_pointer));
// - (BOOL)getFileSystemRepresentation:(char *)cname maxLength:(NSUInteger)max;
/* @end */
// @interface NSArray (NSArrayPathExtensions)
// - (NSArray *)pathsMatchingExtensions:(NSArray *)filterTypes;
/* @end */
extern "C" NSString *NSUserName(void);
extern "C" NSString *NSFullUserName(void);
extern "C" NSString *NSHomeDirectory(void);
extern "C" NSString *NSHomeDirectoryForUser(NSString *userName);
extern "C" NSString *NSTemporaryDirectory(void);
extern "C" NSString *NSOpenStepRootDirectory(void);
typedef NSUInteger NSSearchPathDirectory; enum {
NSApplicationDirectory = 1,
NSDemoApplicationDirectory,
NSDeveloperApplicationDirectory,
NSAdminApplicationDirectory,
NSLibraryDirectory,
NSDeveloperDirectory,
NSUserDirectory,
NSDocumentationDirectory,
NSDocumentDirectory,
NSCoreServiceDirectory,
NSAutosavedInformationDirectory __attribute__((availability(macosx,introduced=10.6))) = 11,
NSDesktopDirectory = 12,
NSCachesDirectory = 13,
NSApplicationSupportDirectory = 14,
NSDownloadsDirectory __attribute__((availability(macosx,introduced=10.5))) = 15,
NSInputMethodsDirectory __attribute__((availability(macosx,introduced=10.6))) = 16,
NSMoviesDirectory __attribute__((availability(macosx,introduced=10.6))) = 17,
NSMusicDirectory __attribute__((availability(macosx,introduced=10.6))) = 18,
NSPicturesDirectory __attribute__((availability(macosx,introduced=10.6))) = 19,
NSPrinterDescriptionDirectory __attribute__((availability(macosx,introduced=10.6))) = 20,
NSSharedPublicDirectory __attribute__((availability(macosx,introduced=10.6))) = 21,
NSPreferencePanesDirectory __attribute__((availability(macosx,introduced=10.6))) = 22,
NSApplicationScriptsDirectory __attribute__((availability(macosx,introduced=10.8))) = 23,
NSItemReplacementDirectory __attribute__((availability(macosx,introduced=10.6))) = 99,
NSAllApplicationsDirectory = 100,
NSAllLibrariesDirectory = 101,
NSTrashDirectory __attribute__((availability(macosx,introduced=10.8))) = 102
};
typedef NSUInteger NSSearchPathDomainMask; enum {
NSUserDomainMask = 1,
NSLocalDomainMask = 2,
NSNetworkDomainMask = 4,
NSSystemDomainMask = 8,
NSAllDomainsMask = 0x0ffff
};
extern "C" NSArray *NSSearchPathForDirectoriesInDomains(NSSearchPathDirectory directory, NSSearchPathDomainMask domainMask, BOOL expandTilde);
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
#ifndef _REWRITER_typedef_NSDirectoryEnumerator
#define _REWRITER_typedef_NSDirectoryEnumerator
typedef struct objc_object NSDirectoryEnumerator;
typedef struct {} _objc_exc_NSDirectoryEnumerator;
#endif
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
#ifndef _REWRITER_typedef_NSNumber
#define _REWRITER_typedef_NSNumber
typedef struct objc_object NSNumber;
typedef struct {} _objc_exc_NSNumber;
#endif
// @protocol NSFileManagerDelegate;
typedef NSUInteger NSVolumeEnumerationOptions; enum {
NSVolumeEnumerationSkipHiddenVolumes = 1UL << 1,
NSVolumeEnumerationProduceFileReferenceURLs = 1UL << 2
} __attribute__((availability(macosx,introduced=10.6)));
typedef NSUInteger NSDirectoryEnumerationOptions; enum {
NSDirectoryEnumerationSkipsSubdirectoryDescendants = 1UL << 0,
NSDirectoryEnumerationSkipsPackageDescendants = 1UL << 1,
NSDirectoryEnumerationSkipsHiddenFiles = 1UL << 2
} __attribute__((availability(macosx,introduced=10.6)));
typedef NSUInteger NSFileManagerItemReplacementOptions; enum {
NSFileManagerItemReplacementUsingNewMetadataOnly = 1UL << 0,
NSFileManagerItemReplacementWithoutDeletingBackupItem = 1UL << 1
} __attribute__((availability(macosx,introduced=10.6)));
typedef NSInteger NSURLRelationship; enum {
NSURLRelationshipContains,
NSURLRelationshipSame,
NSURLRelationshipOther
} __attribute__((availability(macosx,introduced=10.10)));
extern NSString * const NSUbiquityIdentityDidChangeNotification __attribute__((availability(macosx,introduced=10.8)));
#ifndef _REWRITER_typedef_NSFileManager
#define _REWRITER_typedef_NSFileManager
typedef struct objc_object NSFileManager;
typedef struct {} _objc_exc_NSFileManager;
#endif
struct NSFileManager_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// + (NSFileManager *)defaultManager;
// - (NSArray *)mountedVolumeURLsIncludingResourceValuesForKeys:(NSArray *)propertyKeys options:(NSVolumeEnumerationOptions)options __attribute__((availability(macosx,introduced=10.6)));
// - (NSArray *)contentsOfDirectoryAtURL:(NSURL *)url includingPropertiesForKeys:(NSArray *)keys options:(NSDirectoryEnumerationOptions)mask error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (NSArray *)URLsForDirectory:(NSSearchPathDirectory)directory inDomains:(NSSearchPathDomainMask)domainMask __attribute__((availability(macosx,introduced=10.6)));
// - (NSURL *)URLForDirectory:(NSSearchPathDirectory)directory inDomain:(NSSearchPathDomainMask)domain appropriateForURL:(NSURL *)url create:(BOOL)shouldCreate error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)getRelationship:(NSURLRelationship *)outRelationship ofDirectoryAtURL:(NSURL *)directoryURL toItemAtURL:(NSURL *)otherURL error:(NSError **)error __attribute__((availability(macosx,introduced=10.10)));
// - (BOOL)getRelationship:(NSURLRelationship *)outRelationship ofDirectory:(NSSearchPathDirectory)directory inDomain:(NSSearchPathDomainMask)domainMask toItemAtURL:(NSURL *)url error:(NSError **)error __attribute__((availability(macosx,introduced=10.10)));
// - (BOOL)createDirectoryAtURL:(NSURL *)url withIntermediateDirectories:(BOOL)createIntermediates attributes:(NSDictionary *)attributes error:(NSError **)error __attribute__((availability(macosx,introduced=10.7)));
// - (BOOL)createSymbolicLinkAtURL:(NSURL *)url withDestinationURL:(NSURL *)destURL error:(NSError **)error __attribute__((availability(macosx,introduced=10.7)));
// @property (assign) id <NSFileManagerDelegate> delegate __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)setAttributes:(NSDictionary *)attributes ofItemAtPath:(NSString *)path error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)createDirectoryAtPath:(NSString *)path withIntermediateDirectories:(BOOL)createIntermediates attributes:(NSDictionary *)attributes error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (NSArray *)contentsOfDirectoryAtPath:(NSString *)path error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (NSArray *)subpathsOfDirectoryAtPath:(NSString *)path error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (NSDictionary *)attributesOfItemAtPath:(NSString *)path error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (NSDictionary *)attributesOfFileSystemForPath:(NSString *)path error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)createSymbolicLinkAtPath:(NSString *)path withDestinationPath:(NSString *)destPath error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (NSString *)destinationOfSymbolicLinkAtPath:(NSString *)path error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)copyItemAtPath:(NSString *)srcPath toPath:(NSString *)dstPath error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)moveItemAtPath:(NSString *)srcPath toPath:(NSString *)dstPath error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)linkItemAtPath:(NSString *)srcPath toPath:(NSString *)dstPath error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)removeItemAtPath:(NSString *)path error:(NSError **)error __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)copyItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)moveItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)linkItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)removeItemAtURL:(NSURL *)URL error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)trashItemAtURL:(NSURL *)url resultingItemURL:(NSURL **)outResultingURL error:(NSError **)error __attribute__((availability(macosx,introduced=10.8)));
// - (NSDictionary *)fileAttributesAtPath:(NSString *)path traverseLink:(BOOL)yorn __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (BOOL)changeFileAttributes:(NSDictionary *)attributes atPath:(NSString *)path __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (NSArray *)directoryContentsAtPath:(NSString *)path __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (NSDictionary *)fileSystemAttributesAtPath:(NSString *)path __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (NSString *)pathContentOfSymbolicLinkAtPath:(NSString *)path __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (BOOL)createSymbolicLinkAtPath:(NSString *)path pathContent:(NSString *)otherpath __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (BOOL)createDirectoryAtPath:(NSString *)path attributes:(NSDictionary *)attributes __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (BOOL)linkPath:(NSString *)src toPath:(NSString *)dest handler:(id)handler __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (BOOL)copyPath:(NSString *)src toPath:(NSString *)dest handler:(id)handler __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (BOOL)movePath:(NSString *)src toPath:(NSString *)dest handler:(id)handler __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (BOOL)removeFileAtPath:(NSString *)path handler:(id)handler __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// @property (readonly, copy) NSString *currentDirectoryPath;
// - (BOOL)changeCurrentDirectoryPath:(NSString *)path;
// - (BOOL)fileExistsAtPath:(NSString *)path;
// - (BOOL)fileExistsAtPath:(NSString *)path isDirectory:(BOOL *)isDirectory;
// - (BOOL)isReadableFileAtPath:(NSString *)path;
// - (BOOL)isWritableFileAtPath:(NSString *)path;
// - (BOOL)isExecutableFileAtPath:(NSString *)path;
// - (BOOL)isDeletableFileAtPath:(NSString *)path;
// - (BOOL)contentsEqualAtPath:(NSString *)path1 andPath:(NSString *)path2;
// - (NSString *)displayNameAtPath:(NSString *)path;
// - (NSArray *)componentsToDisplayForPath:(NSString *)path;
// - (NSDirectoryEnumerator *)enumeratorAtPath:(NSString *)path;
// - (NSDirectoryEnumerator *)enumeratorAtURL:(NSURL *)url includingPropertiesForKeys:(NSArray *)keys options:(NSDirectoryEnumerationOptions)mask errorHandler:(BOOL (^)(NSURL *url, NSError *error))handler __attribute__((availability(macosx,introduced=10.6)));
// - (NSArray *)subpathsAtPath:(NSString *)path;
// - (NSData *)contentsAtPath:(NSString *)path;
// - (BOOL)createFileAtPath:(NSString *)path contents:(NSData *)data attributes:(NSDictionary *)attr;
// - ( const char *)fileSystemRepresentationWithPath:(NSString *)path __attribute__((objc_returns_inner_pointer));
// - (NSString *)stringWithFileSystemRepresentation:(const char *)str length:(NSUInteger)len;
// - (BOOL)replaceItemAtURL:(NSURL *)originalItemURL withItemAtURL:(NSURL *)newItemURL backupItemName:(NSString *)backupItemName options:(NSFileManagerItemReplacementOptions)options resultingItemURL:(NSURL **)resultingURL error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)setUbiquitous:(BOOL)flag itemAtURL:(NSURL *)url destinationURL:(NSURL *)destinationURL error:(NSError **)error __attribute__((availability(macosx,introduced=10.7)));
// - (BOOL)isUbiquitousItemAtURL:(NSURL *)url __attribute__((availability(macosx,introduced=10.7)));
// - (BOOL)startDownloadingUbiquitousItemAtURL:(NSURL *)url error:(NSError **)error __attribute__((availability(macosx,introduced=10.7)));
// - (BOOL)evictUbiquitousItemAtURL:(NSURL *)url error:(NSError **)error __attribute__((availability(macosx,introduced=10.7)));
// - (NSURL *)URLForUbiquityContainerIdentifier:(NSString *)containerIdentifier __attribute__((availability(macosx,introduced=10.7)));
// - (NSURL *)URLForPublishingUbiquitousItemAtURL:(NSURL *)url expirationDate:(NSDate **)outDate error:(NSError **)error __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) id<NSObject,NSCopying,NSCoding> ubiquityIdentityToken __attribute__((availability(macosx,introduced=10.8)));
// - (NSURL *)containerURLForSecurityApplicationGroupIdentifier:(NSString *)groupIdentifier __attribute__((availability(macosx,introduced=10.8)));
/* @end */
// @interface NSObject (NSCopyLinkMoveHandler)
// - (BOOL)fileManager:(NSFileManager *)fm shouldProceedAfterError:(NSDictionary *)errorInfo __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// - (void)fileManager:(NSFileManager *)fm willProcessPath:(NSString *)path __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
/* @end */
// @protocol NSFileManagerDelegate <NSObject>
/* @optional */
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldCopyItemAtPath:(NSString *)srcPath toPath:(NSString *)dstPath;
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldCopyItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldProceedAfterError:(NSError *)error copyingItemAtPath:(NSString *)srcPath toPath:(NSString *)dstPath;
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldProceedAfterError:(NSError *)error copyingItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldMoveItemAtPath:(NSString *)srcPath toPath:(NSString *)dstPath;
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldMoveItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldProceedAfterError:(NSError *)error movingItemAtPath:(NSString *)srcPath toPath:(NSString *)dstPath;
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldProceedAfterError:(NSError *)error movingItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldLinkItemAtPath:(NSString *)srcPath toPath:(NSString *)dstPath;
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldLinkItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldProceedAfterError:(NSError *)error linkingItemAtPath:(NSString *)srcPath toPath:(NSString *)dstPath;
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldProceedAfterError:(NSError *)error linkingItemAtURL:(NSURL *)srcURL toURL:(NSURL *)dstURL __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldRemoveItemAtPath:(NSString *)path;
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldRemoveItemAtURL:(NSURL *)URL __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldProceedAfterError:(NSError *)error removingItemAtPath:(NSString *)path;
// - (BOOL)fileManager:(NSFileManager *)fileManager shouldProceedAfterError:(NSError *)error removingItemAtURL:(NSURL *)URL __attribute__((availability(macosx,introduced=10.6)));
/* @end */
#ifndef _REWRITER_typedef_NSDirectoryEnumerator
#define _REWRITER_typedef_NSDirectoryEnumerator
typedef struct objc_object NSDirectoryEnumerator;
typedef struct {} _objc_exc_NSDirectoryEnumerator;
#endif
struct NSDirectoryEnumerator_IMPL {
struct NSEnumerator_IMPL NSEnumerator_IVARS;
};
// @property (readonly, copy) NSDictionary *fileAttributes;
// @property (readonly, copy) NSDictionary *directoryAttributes;
// - (void)skipDescendents;
// @property (readonly) NSUInteger level __attribute__((availability(macosx,introduced=10.6)));
// - (void)skipDescendants __attribute__((availability(macosx,introduced=10.6)));
/* @end */
extern "C" NSString * const NSFileType;
extern "C" NSString * const NSFileTypeDirectory;
extern "C" NSString * const NSFileTypeRegular;
extern "C" NSString * const NSFileTypeSymbolicLink;
extern "C" NSString * const NSFileTypeSocket;
extern "C" NSString * const NSFileTypeCharacterSpecial;
extern "C" NSString * const NSFileTypeBlockSpecial;
extern "C" NSString * const NSFileTypeUnknown;
extern "C" NSString * const NSFileSize;
extern "C" NSString * const NSFileModificationDate;
extern "C" NSString * const NSFileReferenceCount;
extern "C" NSString * const NSFileDeviceIdentifier;
extern "C" NSString * const NSFileOwnerAccountName;
extern "C" NSString * const NSFileGroupOwnerAccountName;
extern "C" NSString * const NSFilePosixPermissions;
extern "C" NSString * const NSFileSystemNumber;
extern "C" NSString * const NSFileSystemFileNumber;
extern "C" NSString * const NSFileExtensionHidden;
extern "C" NSString * const NSFileHFSCreatorCode;
extern "C" NSString * const NSFileHFSTypeCode;
extern "C" NSString * const NSFileImmutable;
extern "C" NSString * const NSFileAppendOnly;
extern "C" NSString * const NSFileCreationDate;
extern "C" NSString * const NSFileOwnerAccountID;
extern "C" NSString * const NSFileGroupOwnerAccountID;
extern "C" NSString * const NSFileBusy;
extern "C" NSString * const NSFileProtectionKey __attribute__((availability(macosx,unavailable)));
extern "C" NSString * const NSFileProtectionNone __attribute__((availability(macosx,unavailable)));
extern "C" NSString * const NSFileProtectionComplete __attribute__((availability(macosx,unavailable)));
extern "C" NSString * const NSFileProtectionCompleteUnlessOpen __attribute__((availability(macosx,unavailable)));
extern "C" NSString * const NSFileProtectionCompleteUntilFirstUserAuthentication __attribute__((availability(macosx,unavailable)));
extern "C" NSString * const NSFileSystemSize;
extern "C" NSString * const NSFileSystemFreeSize;
extern "C" NSString * const NSFileSystemNodes;
extern "C" NSString * const NSFileSystemFreeNodes;
// @interface NSDictionary (NSFileAttributes)
// - (unsigned long long)fileSize;
// - (NSDate *)fileModificationDate;
// - (NSString *)fileType;
// - (NSUInteger)filePosixPermissions;
// - (NSString *)fileOwnerAccountName;
// - (NSString *)fileGroupOwnerAccountName;
// - (NSInteger)fileSystemNumber;
// - (NSUInteger)fileSystemFileNumber;
// - (BOOL)fileExtensionHidden;
// - (OSType)fileHFSCreatorCode;
// - (OSType)fileHFSTypeCode;
// - (BOOL)fileIsImmutable;
// - (BOOL)fileIsAppendOnly;
// - (NSDate *)fileCreationDate;
// - (NSNumber *)fileOwnerAccountID;
// - (NSNumber *)fileGroupOwnerAccountID;
/* @end */
enum {
NSPointerFunctionsStrongMemory __attribute__((availability(macosx,introduced=10.5))) = (0UL << 0),
NSPointerFunctionsZeroingWeakMemory __attribute__((availability(macosx,introduced=10.5 ,deprecated=10.8,message="" ))) = (1UL << 0),
NSPointerFunctionsOpaqueMemory __attribute__((availability(macosx,introduced=10.5))) = (2UL << 0),
NSPointerFunctionsMallocMemory __attribute__((availability(macosx,introduced=10.5))) = (3UL << 0),
NSPointerFunctionsMachVirtualMemory __attribute__((availability(macosx,introduced=10.5))) = (4UL << 0),
NSPointerFunctionsWeakMemory __attribute__((availability(macosx,introduced=10.8))) = (5UL << 0),
NSPointerFunctionsObjectPersonality __attribute__((availability(macosx,introduced=10.5))) = (0UL << 8),
NSPointerFunctionsOpaquePersonality __attribute__((availability(macosx,introduced=10.5))) = (1UL << 8),
NSPointerFunctionsObjectPointerPersonality __attribute__((availability(macosx,introduced=10.5))) = (2UL << 8),
NSPointerFunctionsCStringPersonality __attribute__((availability(macosx,introduced=10.5))) = (3UL << 8),
NSPointerFunctionsStructPersonality __attribute__((availability(macosx,introduced=10.5))) = (4UL << 8),
NSPointerFunctionsIntegerPersonality __attribute__((availability(macosx,introduced=10.5))) = (5UL << 8),
NSPointerFunctionsCopyIn __attribute__((availability(macosx,introduced=10.5))) = (1UL << 16),
};
typedef NSUInteger NSPointerFunctionsOptions;
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.5)))
#ifndef _REWRITER_typedef_NSPointerFunctions
#define _REWRITER_typedef_NSPointerFunctions
typedef struct objc_object NSPointerFunctions;
typedef struct {} _objc_exc_NSPointerFunctions;
#endif
struct NSPointerFunctions_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (instancetype)initWithOptions:(NSPointerFunctionsOptions)options __attribute__((objc_designated_initializer));
// + (NSPointerFunctions *)pointerFunctionsWithOptions:(NSPointerFunctionsOptions)options;
// @property NSUInteger (*hashFunction)(const void *item, NSUInteger (*size)(const void *item));
// @property BOOL (*isEqualFunction)(const void *item1, const void*item2, NSUInteger (*size)(const void *item));
// @property NSUInteger (*sizeFunction)(const void *item);
// @property NSString *(*descriptionFunction)(const void *item);
// @property void (*relinquishFunction)(const void *item, NSUInteger (*size)(const void *item));
// @property void *(*acquireFunction)(const void *src, NSUInteger (*size)(const void *item), BOOL shouldCopy);
// @property BOOL usesStrongWriteBarrier;
// @property BOOL usesWeakReadAndWriteBarriers;
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSSet
#define _REWRITER_typedef_NSSet
typedef struct objc_object NSSet;
typedef struct {} _objc_exc_NSSet;
#endif
#ifndef _REWRITER_typedef_NSHashTable
#define _REWRITER_typedef_NSHashTable
typedef struct objc_object NSHashTable;
typedef struct {} _objc_exc_NSHashTable;
#endif
enum {
NSHashTableStrongMemory __attribute__((availability(macosx,introduced=10.5))) = 0,
NSHashTableZeroingWeakMemory __attribute__((availability(macosx,introduced=10.5 ,deprecated=10.8,message="" ))) = NSPointerFunctionsZeroingWeakMemory,
NSHashTableCopyIn __attribute__((availability(macosx,introduced=10.5))) = NSPointerFunctionsCopyIn,
NSHashTableObjectPointerPersonality __attribute__((availability(macosx,introduced=10.5))) = NSPointerFunctionsObjectPointerPersonality,
NSHashTableWeakMemory __attribute__((availability(macosx,introduced=10.8))) = NSPointerFunctionsWeakMemory
};
typedef NSUInteger NSHashTableOptions;
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.5)))
#ifndef _REWRITER_typedef_NSHashTable
#define _REWRITER_typedef_NSHashTable
typedef struct objc_object NSHashTable;
typedef struct {} _objc_exc_NSHashTable;
#endif
struct NSHashTable_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (instancetype)initWithOptions:(NSPointerFunctionsOptions)options capacity:(NSUInteger)initialCapacity __attribute__((objc_designated_initializer));
// - (instancetype)initWithPointerFunctions:(NSPointerFunctions *)functions capacity:(NSUInteger)initialCapacity __attribute__((objc_designated_initializer));
// + (NSHashTable *)hashTableWithOptions:(NSPointerFunctionsOptions)options;
// + (id)hashTableWithWeakObjects __attribute__((availability(macosx,introduced=10.5 ,deprecated=10.8,message="" )));
// + (NSHashTable *)weakObjectsHashTable __attribute__((availability(macosx,introduced=10.8)));
// @property (readonly, copy) NSPointerFunctions *pointerFunctions;
// @property (readonly) NSUInteger count;
// - (id)member:(id)object;
// - (NSEnumerator *)objectEnumerator;
// - (void)addObject:(id)object;
// - (void)removeObject:(id)object;
// - (void)removeAllObjects;
// @property (readonly, copy) NSArray *allObjects;
// @property (nonatomic, readonly) id anyObject;
// - (BOOL)containsObject:(id)anObject;
// - (BOOL)intersectsHashTable:(NSHashTable *)other;
// - (BOOL)isEqualToHashTable:(NSHashTable *)other;
// - (BOOL)isSubsetOfHashTable:(NSHashTable *)other;
// - (void)intersectHashTable:(NSHashTable *)other;
// - (void)unionHashTable:(NSHashTable *)other;
// - (void)minusHashTable:(NSHashTable *)other;
// @property (readonly, copy) NSSet *setRepresentation;
/* @end */
typedef struct {NSUInteger _pi; NSUInteger _si; void *_bs;} NSHashEnumerator;
extern "C" void NSFreeHashTable(NSHashTable *table);
extern "C" void NSResetHashTable(NSHashTable *table);
extern "C" BOOL NSCompareHashTables(NSHashTable *table1, NSHashTable *table2);
extern "C" NSHashTable *NSCopyHashTableWithZone(NSHashTable *table, NSZone *zone);
extern "C" void *NSHashGet(NSHashTable *table, const void *pointer);
extern "C" void NSHashInsert(NSHashTable *table, const void *pointer);
extern "C" void NSHashInsertKnownAbsent(NSHashTable *table, const void *pointer);
extern "C" void *NSHashInsertIfAbsent(NSHashTable *table, const void *pointer);
extern "C" void NSHashRemove(NSHashTable *table, const void *pointer);
extern "C" NSHashEnumerator NSEnumerateHashTable(NSHashTable *table);
extern "C" void *NSNextHashEnumeratorItem(NSHashEnumerator *enumerator);
extern "C" void NSEndHashTableEnumeration(NSHashEnumerator *enumerator);
extern "C" NSUInteger NSCountHashTable(NSHashTable *table);
extern "C" NSString *NSStringFromHashTable(NSHashTable *table);
extern "C" NSArray *NSAllHashTableObjects(NSHashTable *table);
typedef struct {
NSUInteger (*hash)(NSHashTable *table, const void *);
BOOL (*isEqual)(NSHashTable *table, const void *, const void *);
void (*retain)(NSHashTable *table, const void *);
void (*release)(NSHashTable *table, void *);
NSString *(*describe)(NSHashTable *table, const void *);
} NSHashTableCallBacks;
extern "C" NSHashTable *NSCreateHashTableWithZone(NSHashTableCallBacks callBacks, NSUInteger capacity, NSZone *zone);
extern "C" NSHashTable *NSCreateHashTable(NSHashTableCallBacks callBacks, NSUInteger capacity);
extern "C" const NSHashTableCallBacks NSIntegerHashCallBacks __attribute__((availability(macosx,introduced=10.5)));
extern "C" const NSHashTableCallBacks NSNonOwnedPointerHashCallBacks;
extern "C" const NSHashTableCallBacks NSNonRetainedObjectHashCallBacks;
extern "C" const NSHashTableCallBacks NSObjectHashCallBacks;
extern "C" const NSHashTableCallBacks NSOwnedObjectIdentityHashCallBacks;
extern "C" const NSHashTableCallBacks NSOwnedPointerHashCallBacks;
extern "C" const NSHashTableCallBacks NSPointerToStructHashCallBacks;
extern "C" const NSHashTableCallBacks NSIntHashCallBacks __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
// @class NSDate;
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
// @class NSDictionary;
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
// @class NSURL;
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
extern "C" NSString * const NSHTTPCookieName;
extern "C" NSString * const NSHTTPCookieValue;
extern "C" NSString * const NSHTTPCookieOriginURL;
extern "C" NSString * const NSHTTPCookieVersion;
extern "C" NSString * const NSHTTPCookieDomain;
extern "C" NSString * const NSHTTPCookiePath;
extern "C" NSString * const NSHTTPCookieSecure;
extern "C" NSString * const NSHTTPCookieExpires;
extern "C" NSString * const NSHTTPCookieComment;
extern "C" NSString * const NSHTTPCookieCommentURL;
extern "C" NSString * const NSHTTPCookieDiscard;
extern "C" NSString * const NSHTTPCookieMaximumAge;
extern "C" NSString * const NSHTTPCookiePort;
// @class NSHTTPCookieInternal;
#ifndef _REWRITER_typedef_NSHTTPCookieInternal
#define _REWRITER_typedef_NSHTTPCookieInternal
typedef struct objc_object NSHTTPCookieInternal;
typedef struct {} _objc_exc_NSHTTPCookieInternal;
#endif
#ifndef _REWRITER_typedef_NSHTTPCookie
#define _REWRITER_typedef_NSHTTPCookie
typedef struct objc_object NSHTTPCookie;
typedef struct {} _objc_exc_NSHTTPCookie;
#endif
struct NSHTTPCookie_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSHTTPCookieInternal *_cookiePrivate;
};
// - (instancetype)initWithProperties:(NSDictionary *)properties;
// + (NSHTTPCookie *)cookieWithProperties:(NSDictionary *)properties;
// + (NSDictionary *)requestHeaderFieldsWithCookies:(NSArray *)cookies;
// + (NSArray *)cookiesWithResponseHeaderFields:(NSDictionary *)headerFields forURL:(NSURL *)URL;
// @property (readonly, copy) NSDictionary *properties;
// @property (readonly) NSUInteger version;
// @property (readonly, copy) NSString *name;
// @property (readonly, copy) NSString *value;
// @property (readonly, copy) NSDate *expiresDate;
// @property (readonly, getter=isSessionOnly) BOOL sessionOnly;
// @property (readonly, copy) NSString *domain;
// @property (readonly, copy) NSString *path;
// @property (readonly, getter=isSecure) BOOL secure;
// @property (readonly, getter=isHTTPOnly) BOOL HTTPOnly;
// @property (readonly, copy) NSString *comment;
// @property (readonly, copy) NSURL *commentURL;
// @property (readonly, copy) NSArray *portList;
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
// @class NSHTTPCookie;
#ifndef _REWRITER_typedef_NSHTTPCookie
#define _REWRITER_typedef_NSHTTPCookie
typedef struct objc_object NSHTTPCookie;
typedef struct {} _objc_exc_NSHTTPCookie;
#endif
// @class NSURL;
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
// @class NSDate;
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
// @class NSURLSessionTask;
#ifndef _REWRITER_typedef_NSURLSessionTask
#define _REWRITER_typedef_NSURLSessionTask
typedef struct objc_object NSURLSessionTask;
typedef struct {} _objc_exc_NSURLSessionTask;
#endif
typedef NSUInteger NSHTTPCookieAcceptPolicy; enum {
NSHTTPCookieAcceptPolicyAlways,
NSHTTPCookieAcceptPolicyNever,
NSHTTPCookieAcceptPolicyOnlyFromMainDocumentDomain
};
// @class NSHTTPCookieStorageInternal;
#ifndef _REWRITER_typedef_NSHTTPCookieStorageInternal
#define _REWRITER_typedef_NSHTTPCookieStorageInternal
typedef struct objc_object NSHTTPCookieStorageInternal;
typedef struct {} _objc_exc_NSHTTPCookieStorageInternal;
#endif
#ifndef _REWRITER_typedef_NSHTTPCookieStorage
#define _REWRITER_typedef_NSHTTPCookieStorage
typedef struct objc_object NSHTTPCookieStorage;
typedef struct {} _objc_exc_NSHTTPCookieStorage;
#endif
struct NSHTTPCookieStorage_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSHTTPCookieStorageInternal *_internal;
};
// + (NSHTTPCookieStorage *)sharedHTTPCookieStorage;
// @property (readonly, copy) NSArray *cookies;
// - (void)setCookie:(NSHTTPCookie *)cookie;
// - (void)deleteCookie:(NSHTTPCookie *)cookie;
// - (void)removeCookiesSinceDate:(NSDate *)date __attribute__((availability(macosx,introduced=10.10)));
// - (NSArray *)cookiesForURL:(NSURL *)URL;
// - (void)setCookies:(NSArray *)cookies forURL:(NSURL *)URL mainDocumentURL:(NSURL *)mainDocumentURL;
// @property NSHTTPCookieAcceptPolicy cookieAcceptPolicy;
// - (NSArray*)sortedCookiesUsingDescriptors:(NSArray*) sortOrder __attribute__((availability(macosx,introduced=10.7)));
/* @end */
// @interface NSHTTPCookieStorage (NSURLSessionTaskAdditions)
// - (void)storeCookies:(NSArray *)cookies forTask:(NSURLSessionTask *)task __attribute__((availability(macosx,introduced=10.10)));
// - (void)getCookiesForTask:(NSURLSessionTask *)task completionHandler:(void (^) (NSArray *cookies))completionHandler __attribute__((availability(macosx,introduced=10.10)));
/* @end */
extern "C" NSString * const NSHTTPCookieManagerAcceptPolicyChangedNotification;
extern "C" NSString * const NSHTTPCookieManagerCookiesChangedNotification;
#ifndef _REWRITER_typedef_NSIndexPath
#define _REWRITER_typedef_NSIndexPath
typedef struct objc_object NSIndexPath;
typedef struct {} _objc_exc_NSIndexPath;
#endif
struct NSIndexPath_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSUInteger *_indexes;
NSUInteger _length;
void *_reserved;
};
// + (instancetype)indexPathWithIndex:(NSUInteger)index;
// + (instancetype)indexPathWithIndexes:(const NSUInteger [])indexes length:(NSUInteger)length;
// - (instancetype)initWithIndexes:(const NSUInteger [])indexes length:(NSUInteger)length __attribute__((objc_designated_initializer));
// - (instancetype)initWithIndex:(NSUInteger)index;
// - (NSIndexPath *)indexPathByAddingIndex:(NSUInteger)index;
// - (NSIndexPath *)indexPathByRemovingLastIndex;
// - (NSUInteger)indexAtPosition:(NSUInteger)position;
// @property (readonly) NSUInteger length;
// - (void)getIndexes:(NSUInteger *)indexes;
// - (NSComparisonResult)compare:(NSIndexPath *)otherObject;
/* @end */
#ifndef _REWRITER_typedef_NSIndexSet
#define _REWRITER_typedef_NSIndexSet
typedef struct objc_object NSIndexSet;
typedef struct {} _objc_exc_NSIndexSet;
#endif
struct NSIndexSet_IMPL {
struct NSObject_IMPL NSObject_IVARS;
struct {
NSUInteger _isEmpty : 1;
NSUInteger _hasSingleRange : 1;
NSUInteger _cacheValid : 1;
NSUInteger _reservedArrayBinderController : 29;
} _indexSetFlags;
union {
struct {
NSRange _range;
} _singleRange;
struct {
void *_data;
void *_reserved;
} _multipleRanges;
} _internal;
};
// + (instancetype)indexSet;
// + (instancetype)indexSetWithIndex:(NSUInteger)value;
// + (instancetype)indexSetWithIndexesInRange:(NSRange)range;
// - (instancetype)initWithIndexesInRange:(NSRange)range __attribute__((objc_designated_initializer));
// - (instancetype)initWithIndexSet:(NSIndexSet *)indexSet __attribute__((objc_designated_initializer));
// - (instancetype)initWithIndex:(NSUInteger)value;
// - (BOOL)isEqualToIndexSet:(NSIndexSet *)indexSet;
// @property (readonly) NSUInteger count;
// @property (readonly) NSUInteger firstIndex;
// @property (readonly) NSUInteger lastIndex;
// - (NSUInteger)indexGreaterThanIndex:(NSUInteger)value;
// - (NSUInteger)indexLessThanIndex:(NSUInteger)value;
// - (NSUInteger)indexGreaterThanOrEqualToIndex:(NSUInteger)value;
// - (NSUInteger)indexLessThanOrEqualToIndex:(NSUInteger)value;
// - (NSUInteger)getIndexes:(NSUInteger *)indexBuffer maxCount:(NSUInteger)bufferSize inIndexRange:(NSRangePointer)range;
// - (NSUInteger)countOfIndexesInRange:(NSRange)range __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL)containsIndex:(NSUInteger)value;
// - (BOOL)containsIndexesInRange:(NSRange)range;
// - (BOOL)containsIndexes:(NSIndexSet *)indexSet;
// - (BOOL)intersectsIndexesInRange:(NSRange)range;
// - (void)enumerateIndexesUsingBlock:(void (^)(NSUInteger idx, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// - (void)enumerateIndexesWithOptions:(NSEnumerationOptions)opts usingBlock:(void (^)(NSUInteger idx, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// - (void)enumerateIndexesInRange:(NSRange)range options:(NSEnumerationOptions)opts usingBlock:(void (^)(NSUInteger idx, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// - (NSUInteger)indexPassingTest:(BOOL (^)(NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSUInteger)indexWithOptions:(NSEnumerationOptions)opts passingTest:(BOOL (^)(NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSUInteger)indexInRange:(NSRange)range options:(NSEnumerationOptions)opts passingTest:(BOOL (^)(NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSIndexSet *)indexesPassingTest:(BOOL (^)(NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSIndexSet *)indexesWithOptions:(NSEnumerationOptions)opts passingTest:(BOOL (^)(NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSIndexSet *)indexesInRange:(NSRange)range options:(NSEnumerationOptions)opts passingTest:(BOOL (^)(NSUInteger idx, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (void)enumerateRangesUsingBlock:(void (^)(NSRange range, BOOL *stop))block __attribute__((availability(macosx,introduced=10.7)));
// - (void)enumerateRangesWithOptions:(NSEnumerationOptions)opts usingBlock:(void (^)(NSRange range, BOOL *stop))block __attribute__((availability(macosx,introduced=10.7)));
// - (void)enumerateRangesInRange:(NSRange)range options:(NSEnumerationOptions)opts usingBlock:(void (^)(NSRange range, BOOL *stop))block __attribute__((availability(macosx,introduced=10.7)));
/* @end */
#ifndef _REWRITER_typedef_NSMutableIndexSet
#define _REWRITER_typedef_NSMutableIndexSet
typedef struct objc_object NSMutableIndexSet;
typedef struct {} _objc_exc_NSMutableIndexSet;
#endif
struct NSMutableIndexSet_IMPL {
struct NSIndexSet_IMPL NSIndexSet_IVARS;
void *_reserved;
};
// - (void)addIndexes:(NSIndexSet *)indexSet;
// - (void)removeIndexes:(NSIndexSet *)indexSet;
// - (void)removeAllIndexes;
// - (void)addIndex:(NSUInteger)value;
// - (void)removeIndex:(NSUInteger)value;
// - (void)addIndexesInRange:(NSRange)range;
// - (void)removeIndexesInRange:(NSRange)range;
// - (void)shiftIndexesStartingAtIndex:(NSUInteger)index by:(NSInteger)delta;
/* @end */
// @class NSMethodSignature;
#ifndef _REWRITER_typedef_NSMethodSignature
#define _REWRITER_typedef_NSMethodSignature
typedef struct objc_object NSMethodSignature;
typedef struct {} _objc_exc_NSMethodSignature;
#endif
#ifndef _REWRITER_typedef_NSInvocation
#define _REWRITER_typedef_NSInvocation
typedef struct objc_object NSInvocation;
typedef struct {} _objc_exc_NSInvocation;
#endif
struct NSInvocation_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *_frame;
void *_retdata;
id _signature;
id _container;
uint8_t _retainedArgs;
uint8_t _reserved[15];
};
// + (NSInvocation *)invocationWithMethodSignature:(NSMethodSignature *)sig;
// @property (readonly, retain) NSMethodSignature *methodSignature;
// - (void)retainArguments;
// @property (readonly) BOOL argumentsRetained;
// @property (assign) id target;
// @property SEL selector;
// - (void)getReturnValue:(void *)retLoc;
// - (void)setReturnValue:(void *)retLoc;
// - (void)getArgument:(void *)argumentLocation atIndex:(NSInteger)idx;
// - (void)setArgument:(void *)argumentLocation atIndex:(NSInteger)idx;
// - (void)invoke;
// - (void)invokeWithTarget:(id)target;
/* @end */
// @class NSError;
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
#ifndef _REWRITER_typedef_NSOutputStream
#define _REWRITER_typedef_NSOutputStream
typedef struct objc_object NSOutputStream;
typedef struct {} _objc_exc_NSOutputStream;
#endif
#ifndef _REWRITER_typedef_NSInputStream
#define _REWRITER_typedef_NSInputStream
typedef struct objc_object NSInputStream;
typedef struct {} _objc_exc_NSInputStream;
#endif
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
typedef NSUInteger NSJSONReadingOptions; enum {
NSJSONReadingMutableContainers = (1UL << 0),
NSJSONReadingMutableLeaves = (1UL << 1),
NSJSONReadingAllowFragments = (1UL << 2)
} __attribute__((availability(macosx,introduced=10.7)));
typedef NSUInteger NSJSONWritingOptions; enum {
NSJSONWritingPrettyPrinted = (1UL << 0)
} __attribute__((availability(macosx,introduced=10.7)));
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.7)))
#ifndef _REWRITER_typedef_NSJSONSerialization
#define _REWRITER_typedef_NSJSONSerialization
typedef struct objc_object NSJSONSerialization;
typedef struct {} _objc_exc_NSJSONSerialization;
#endif
struct NSJSONSerialization_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *reserved[6];
};
// + (BOOL)isValidJSONObject:(id)obj;
// + (NSData *)dataWithJSONObject:(id)obj options:(NSJSONWritingOptions)opt error:(NSError **)error;
// + (id)JSONObjectWithData:(NSData *)data options:(NSJSONReadingOptions)opt error:(NSError **)error;
// + (NSInteger)writeJSONObject:(id)obj toStream:(NSOutputStream *)stream options:(NSJSONWritingOptions)opt error:(NSError **)error;
// + (id)JSONObjectWithStream:(NSInputStream *)stream options:(NSJSONReadingOptions)opt error:(NSError **)error;
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSIndexSet
#define _REWRITER_typedef_NSIndexSet
typedef struct objc_object NSIndexSet;
typedef struct {} _objc_exc_NSIndexSet;
#endif
#ifndef _REWRITER_typedef_NSSet
#define _REWRITER_typedef_NSSet
typedef struct objc_object NSSet;
typedef struct {} _objc_exc_NSSet;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.7)))
#ifndef _REWRITER_typedef_NSOrderedSet
#define _REWRITER_typedef_NSOrderedSet
typedef struct objc_object NSOrderedSet;
typedef struct {} _objc_exc_NSOrderedSet;
#endif
struct NSOrderedSet_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly) NSUInteger count;
// - (id)objectAtIndex:(NSUInteger)idx;
// - (NSUInteger)indexOfObject:(id)object;
// - (instancetype)init __attribute__((objc_designated_initializer));
// - (instancetype)initWithObjects:(const id [])objects count:(NSUInteger)cnt __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSOrderedSet (NSExtendedOrderedSet)
// - (void)getObjects:(id [])objects range:(NSRange)range;
// - (NSArray *)objectsAtIndexes:(NSIndexSet *)indexes;
// @property (nonatomic, readonly) id firstObject;
// @property (nonatomic, readonly) id lastObject;
// - (BOOL)isEqualToOrderedSet:(NSOrderedSet *)other;
// - (BOOL)containsObject:(id)object;
// - (BOOL)intersectsOrderedSet:(NSOrderedSet *)other;
// - (BOOL)intersectsSet:(NSSet *)set;
// - (BOOL)isSubsetOfOrderedSet:(NSOrderedSet *)other;
// - (BOOL)isSubsetOfSet:(NSSet *)set;
// - (id)objectAtIndexedSubscript:(NSUInteger)idx __attribute__((availability(macosx,introduced=10.8)));
// - (NSEnumerator *)objectEnumerator;
// - (NSEnumerator *)reverseObjectEnumerator;
// @property (readonly, copy) NSOrderedSet *reversedOrderedSet;
// @property (readonly, copy) NSArray *array;
// @property (readonly, copy) NSSet *set;
// - (void)enumerateObjectsUsingBlock:(void (^)(id obj, NSUInteger idx, BOOL *stop))block;
// - (void)enumerateObjectsWithOptions:(NSEnumerationOptions)opts usingBlock:(void (^)(id obj, NSUInteger idx, BOOL *stop))block;
// - (void)enumerateObjectsAtIndexes:(NSIndexSet *)s options:(NSEnumerationOptions)opts usingBlock:(void (^)(id obj, NSUInteger idx, BOOL *stop))block;
// - (NSUInteger)indexOfObjectPassingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate;
// - (NSUInteger)indexOfObjectWithOptions:(NSEnumerationOptions)opts passingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate;
// - (NSUInteger)indexOfObjectAtIndexes:(NSIndexSet *)s options:(NSEnumerationOptions)opts passingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate;
// - (NSIndexSet *)indexesOfObjectsPassingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate;
// - (NSIndexSet *)indexesOfObjectsWithOptions:(NSEnumerationOptions)opts passingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate;
// - (NSIndexSet *)indexesOfObjectsAtIndexes:(NSIndexSet *)s options:(NSEnumerationOptions)opts passingTest:(BOOL (^)(id obj, NSUInteger idx, BOOL *stop))predicate;
// - (NSUInteger)indexOfObject:(id)object inSortedRange:(NSRange)range options:(NSBinarySearchingOptions)opts usingComparator:(NSComparator)cmp;
// - (NSArray *)sortedArrayUsingComparator:(NSComparator)cmptr;
// - (NSArray *)sortedArrayWithOptions:(NSSortOptions)opts usingComparator:(NSComparator)cmptr;
// @property (readonly, copy) NSString *description;
// - (NSString *)descriptionWithLocale:(id)locale;
// - (NSString *)descriptionWithLocale:(id)locale indent:(NSUInteger)level;
/* @end */
// @interface NSOrderedSet (NSOrderedSetCreation)
// + (instancetype)orderedSet;
// + (instancetype)orderedSetWithObject:(id)object;
// + (instancetype)orderedSetWithObjects:(const id [])objects count:(NSUInteger)cnt;
// + (instancetype)orderedSetWithObjects:(id)firstObj, ... __attribute__((sentinel(0,1)));
// + (instancetype)orderedSetWithOrderedSet:(NSOrderedSet *)set;
// + (instancetype)orderedSetWithOrderedSet:(NSOrderedSet *)set range:(NSRange)range copyItems:(BOOL)flag;
// + (instancetype)orderedSetWithArray:(NSArray *)array;
// + (instancetype)orderedSetWithArray:(NSArray *)array range:(NSRange)range copyItems:(BOOL)flag;
// + (instancetype)orderedSetWithSet:(NSSet *)set;
// + (instancetype)orderedSetWithSet:(NSSet *)set copyItems:(BOOL)flag;
// - (instancetype)initWithObject:(id)object;
// - (instancetype)initWithObjects:(id)firstObj, ... __attribute__((sentinel(0,1)));
// - (instancetype)initWithOrderedSet:(NSOrderedSet *)set;
// - (instancetype)initWithOrderedSet:(NSOrderedSet *)set copyItems:(BOOL)flag;
// - (instancetype)initWithOrderedSet:(NSOrderedSet *)set range:(NSRange)range copyItems:(BOOL)flag;
// - (instancetype)initWithArray:(NSArray *)array;
// - (instancetype)initWithArray:(NSArray *)set copyItems:(BOOL)flag;
// - (instancetype)initWithArray:(NSArray *)set range:(NSRange)range copyItems:(BOOL)flag;
// - (instancetype)initWithSet:(NSSet *)set;
// - (instancetype)initWithSet:(NSSet *)set copyItems:(BOOL)flag;
/* @end */
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.7)))
#ifndef _REWRITER_typedef_NSMutableOrderedSet
#define _REWRITER_typedef_NSMutableOrderedSet
typedef struct objc_object NSMutableOrderedSet;
typedef struct {} _objc_exc_NSMutableOrderedSet;
#endif
struct NSMutableOrderedSet_IMPL {
struct NSOrderedSet_IMPL NSOrderedSet_IVARS;
};
// - (void)insertObject:(id)object atIndex:(NSUInteger)idx;
// - (void)removeObjectAtIndex:(NSUInteger)idx;
// - (void)replaceObjectAtIndex:(NSUInteger)idx withObject:(id)object;
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
// - (instancetype)init __attribute__((objc_designated_initializer));
// - (instancetype)initWithCapacity:(NSUInteger)numItems __attribute__((objc_designated_initializer));
/* @end */
// @interface NSMutableOrderedSet (NSExtendedMutableOrderedSet)
// - (void)addObject:(id)object;
// - (void)addObjects:(const id [])objects count:(NSUInteger)count;
// - (void)addObjectsFromArray:(NSArray *)array;
// - (void)exchangeObjectAtIndex:(NSUInteger)idx1 withObjectAtIndex:(NSUInteger)idx2;
// - (void)moveObjectsAtIndexes:(NSIndexSet *)indexes toIndex:(NSUInteger)idx;
// - (void)insertObjects:(NSArray *)objects atIndexes:(NSIndexSet *)indexes;
// - (void)setObject:(id)obj atIndex:(NSUInteger)idx;
// - (void)setObject:(id)obj atIndexedSubscript:(NSUInteger)idx __attribute__((availability(macosx,introduced=10.8)));
// - (void)replaceObjectsInRange:(NSRange)range withObjects:(const id [])objects count:(NSUInteger)count;
// - (void)replaceObjectsAtIndexes:(NSIndexSet *)indexes withObjects:(NSArray *)objects;
// - (void)removeObjectsInRange:(NSRange)range;
// - (void)removeObjectsAtIndexes:(NSIndexSet *)indexes;
// - (void)removeAllObjects;
// - (void)removeObject:(id)object;
// - (void)removeObjectsInArray:(NSArray *)array;
// - (void)intersectOrderedSet:(NSOrderedSet *)other;
// - (void)minusOrderedSet:(NSOrderedSet *)other;
// - (void)unionOrderedSet:(NSOrderedSet *)other;
// - (void)intersectSet:(NSSet *)other;
// - (void)minusSet:(NSSet *)other;
// - (void)unionSet:(NSSet *)other;
// - (void)sortUsingComparator:(NSComparator)cmptr;
// - (void)sortWithOptions:(NSSortOptions)opts usingComparator:(NSComparator)cmptr;
// - (void)sortRange:(NSRange)range options:(NSSortOptions)opts usingComparator:(NSComparator)cmptr;
/* @end */
// @interface NSMutableOrderedSet (NSMutableOrderedSetCreation)
// + (instancetype)orderedSetWithCapacity:(NSUInteger)numItems;
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSSet
#define _REWRITER_typedef_NSSet
typedef struct objc_object NSSet;
typedef struct {} _objc_exc_NSSet;
#endif
struct NSSet_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly) NSUInteger count;
// - (id)member:(id)object;
// - (NSEnumerator *)objectEnumerator;
// - (instancetype)init __attribute__((objc_designated_initializer));
// - (instancetype)initWithObjects:(const id [])objects count:(NSUInteger)cnt __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSSet (NSExtendedSet)
// @property (readonly, copy) NSArray *allObjects;
// - (id)anyObject;
// - (BOOL)containsObject:(id)anObject;
// @property (readonly, copy) NSString *description;
// - (NSString *)descriptionWithLocale:(id)locale;
// - (BOOL)intersectsSet:(NSSet *)otherSet;
// - (BOOL)isEqualToSet:(NSSet *)otherSet;
// - (BOOL)isSubsetOfSet:(NSSet *)otherSet;
// - (void)makeObjectsPerformSelector:(SEL)aSelector;
// - (void)makeObjectsPerformSelector:(SEL)aSelector withObject:(id)argument;
// - (NSSet *)setByAddingObject:(id)anObject __attribute__((availability(macosx,introduced=10.5)));
// - (NSSet *)setByAddingObjectsFromSet:(NSSet *)other __attribute__((availability(macosx,introduced=10.5)));
// - (NSSet *)setByAddingObjectsFromArray:(NSArray *)other __attribute__((availability(macosx,introduced=10.5)));
// - (void)enumerateObjectsUsingBlock:(void (^)(id obj, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// - (void)enumerateObjectsWithOptions:(NSEnumerationOptions)opts usingBlock:(void (^)(id obj, BOOL *stop))block __attribute__((availability(macosx,introduced=10.6)));
// - (NSSet *)objectsPassingTest:(BOOL (^)(id obj, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
// - (NSSet *)objectsWithOptions:(NSEnumerationOptions)opts passingTest:(BOOL (^)(id obj, BOOL *stop))predicate __attribute__((availability(macosx,introduced=10.6)));
/* @end */
// @interface NSSet (NSSetCreation)
// + (instancetype)set;
// + (instancetype)setWithObject:(id)object;
// + (instancetype)setWithObjects:(const id [])objects count:(NSUInteger)cnt;
// + (instancetype)setWithObjects:(id)firstObj, ... __attribute__((sentinel(0,1)));
// + (instancetype)setWithSet:(NSSet *)set;
// + (instancetype)setWithArray:(NSArray *)array;
// - (instancetype)initWithObjects:(id)firstObj, ... __attribute__((sentinel(0,1)));
// - (instancetype)initWithSet:(NSSet *)set;
// - (instancetype)initWithSet:(NSSet *)set copyItems:(BOOL)flag;
// - (instancetype)initWithArray:(NSArray *)array;
/* @end */
#ifndef _REWRITER_typedef_NSMutableSet
#define _REWRITER_typedef_NSMutableSet
typedef struct objc_object NSMutableSet;
typedef struct {} _objc_exc_NSMutableSet;
#endif
struct NSMutableSet_IMPL {
struct NSSet_IMPL NSSet_IVARS;
};
// - (void)addObject:(id)object;
// - (void)removeObject:(id)object;
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
// - (instancetype)init __attribute__((objc_designated_initializer));
// - (instancetype)initWithCapacity:(NSUInteger)numItems __attribute__((objc_designated_initializer));
/* @end */
// @interface NSMutableSet (NSExtendedMutableSet)
// - (void)addObjectsFromArray:(NSArray *)array;
// - (void)intersectSet:(NSSet *)otherSet;
// - (void)minusSet:(NSSet *)otherSet;
// - (void)removeAllObjects;
// - (void)unionSet:(NSSet *)otherSet;
// - (void)setSet:(NSSet *)otherSet;
/* @end */
// @interface NSMutableSet (NSMutableSetCreation)
// + (instancetype)setWithCapacity:(NSUInteger)numItems;
/* @end */
#ifndef _REWRITER_typedef_NSCountedSet
#define _REWRITER_typedef_NSCountedSet
typedef struct objc_object NSCountedSet;
typedef struct {} _objc_exc_NSCountedSet;
#endif
struct NSCountedSet_IMPL {
struct NSMutableSet_IMPL NSMutableSet_IVARS;
id _table;
void *_reserved;
};
// - (instancetype)initWithCapacity:(NSUInteger)numItems;
// - (instancetype)initWithArray:(NSArray *)array;
// - (instancetype)initWithSet:(NSSet *)set;
// - (NSUInteger)countForObject:(id)object;
// - (NSEnumerator *)objectEnumerator;
// - (void)addObject:(id)object;
// - (void)removeObject:(id)object;
/* @end */
// @class NSError;
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
extern "C" NSString *const NSUndefinedKeyException;
extern "C" NSString *const NSAverageKeyValueOperator;
extern "C" NSString *const NSCountKeyValueOperator;
extern "C" NSString *const NSDistinctUnionOfArraysKeyValueOperator;
extern "C" NSString *const NSDistinctUnionOfObjectsKeyValueOperator;
extern "C" NSString *const NSDistinctUnionOfSetsKeyValueOperator;
extern "C" NSString *const NSMaximumKeyValueOperator;
extern "C" NSString *const NSMinimumKeyValueOperator;
extern "C" NSString *const NSSumKeyValueOperator;
extern "C" NSString *const NSUnionOfArraysKeyValueOperator;
extern "C" NSString *const NSUnionOfObjectsKeyValueOperator;
extern "C" NSString *const NSUnionOfSetsKeyValueOperator;
// @interface NSObject(NSKeyValueCoding)
// + (BOOL)accessInstanceVariablesDirectly;
// - (id)valueForKey:(NSString *)key;
// - (void)setValue:(id)value forKey:(NSString *)key;
// - (BOOL)validateValue:(inout id *)ioValue forKey:(NSString *)inKey error:(out NSError **)outError;
// - (NSMutableArray *)mutableArrayValueForKey:(NSString *)key;
// - (NSMutableOrderedSet *)mutableOrderedSetValueForKey:(NSString *)key __attribute__((availability(macosx,introduced=10.7)));
// - (NSMutableSet *)mutableSetValueForKey:(NSString *)key;
// - (id)valueForKeyPath:(NSString *)keyPath;
// - (void)setValue:(id)value forKeyPath:(NSString *)keyPath;
// - (BOOL)validateValue:(inout id *)ioValue forKeyPath:(NSString *)inKeyPath error:(out NSError **)outError;
// - (NSMutableArray *)mutableArrayValueForKeyPath:(NSString *)keyPath;
// - (NSMutableOrderedSet *)mutableOrderedSetValueForKeyPath:(NSString *)keyPath __attribute__((availability(macosx,introduced=10.7)));
// - (NSMutableSet *)mutableSetValueForKeyPath:(NSString *)keyPath;
// - (id)valueForUndefinedKey:(NSString *)key;
// - (void)setValue:(id)value forUndefinedKey:(NSString *)key;
// - (void)setNilValueForKey:(NSString *)key;
// - (NSDictionary *)dictionaryWithValuesForKeys:(NSArray *)keys;
// - (void)setValuesForKeysWithDictionary:(NSDictionary *)keyedValues;
/* @end */
// @interface NSArray(NSKeyValueCoding)
// - (id)valueForKey:(NSString *)key;
// - (void)setValue:(id)value forKey:(NSString *)key;
/* @end */
// @interface NSDictionary(NSKeyValueCoding)
// - (id)valueForKey:(NSString *)key;
/* @end */
// @interface NSMutableDictionary(NSKeyValueCoding)
// - (void)setValue:(id)value forKey:(NSString *)key;
/* @end */
// @interface NSOrderedSet(NSKeyValueCoding)
// - (id)valueForKey:(NSString *)key __attribute__((availability(macosx,introduced=10.7)));
// - (void)setValue:(id)value forKey:(NSString *)key __attribute__((availability(macosx,introduced=10.7)));
/* @end */
// @interface NSSet(NSKeyValueCoding)
// - (id)valueForKey:(NSString *)key;
// - (void)setValue:(id)value forKey:(NSString *)key;
/* @end */
// @interface NSObject(NSDeprecatedKeyValueCoding)
// + (BOOL)useStoredAccessor __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (id)storedValueForKey:(NSString *)key __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)takeStoredValue:(id)value forKey:(NSString *)key __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)takeValue:(id)value forKey:(NSString *)key __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.3,message="" )));
// - (void)takeValue:(id)value forKeyPath:(NSString *)keyPath __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.3,message="" )));
// - (id)handleQueryWithUnboundKey:(NSString *)key __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.3,message="" )));
// - (void)handleTakeValue:(id)value forUnboundKey:(NSString *)key __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.3,message="" )));
// - (void)unableToSetNilForKey:(NSString *)key __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.3,message="" )));
// - (NSDictionary *)valuesForKeys:(NSArray *)keys __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.3,message="" )));
// - (void)takeValuesFromDictionary:(NSDictionary *)properties __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.3,message="" )));
/* @end */
// @class NSIndexSet;
#ifndef _REWRITER_typedef_NSIndexSet
#define _REWRITER_typedef_NSIndexSet
typedef struct objc_object NSIndexSet;
typedef struct {} _objc_exc_NSIndexSet;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
typedef NSUInteger NSKeyValueObservingOptions; enum {
NSKeyValueObservingOptionNew = 0x01,
NSKeyValueObservingOptionOld = 0x02,
NSKeyValueObservingOptionInitial __attribute__((availability(macosx,introduced=10.5))) = 0x04,
NSKeyValueObservingOptionPrior __attribute__((availability(macosx,introduced=10.5))) = 0x08
};
typedef NSUInteger NSKeyValueChange; enum {
NSKeyValueChangeSetting = 1,
NSKeyValueChangeInsertion = 2,
NSKeyValueChangeRemoval = 3,
NSKeyValueChangeReplacement = 4
};
typedef NSUInteger NSKeyValueSetMutationKind; enum {
NSKeyValueUnionSetMutation = 1,
NSKeyValueMinusSetMutation = 2,
NSKeyValueIntersectSetMutation = 3,
NSKeyValueSetSetMutation = 4
};
extern "C" NSString *const NSKeyValueChangeKindKey;
extern "C" NSString *const NSKeyValueChangeNewKey;
extern "C" NSString *const NSKeyValueChangeOldKey;
extern "C" NSString *const NSKeyValueChangeIndexesKey;
extern "C" NSString *const NSKeyValueChangeNotificationIsPriorKey __attribute__((availability(macosx,introduced=10.5)));
// @interface NSObject(NSKeyValueObserving)
// - (void)observeValueForKeyPath:(NSString *)keyPath ofObject:(id)object change:(NSDictionary *)change context:(void *)context;
/* @end */
// @interface NSObject(NSKeyValueObserverRegistration)
// - (void)addObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath options:(NSKeyValueObservingOptions)options context:(void *)context;
// - (void)removeObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath context:(void *)context __attribute__((availability(macosx,introduced=10.7)));
// - (void)removeObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath;
/* @end */
// @interface NSArray(NSKeyValueObserverRegistration)
// - (void)addObserver:(NSObject *)observer toObjectsAtIndexes:(NSIndexSet *)indexes forKeyPath:(NSString *)keyPath options:(NSKeyValueObservingOptions)options context:(void *)context;
// - (void)removeObserver:(NSObject *)observer fromObjectsAtIndexes:(NSIndexSet *)indexes forKeyPath:(NSString *)keyPath context:(void *)context __attribute__((availability(macosx,introduced=10.7)));
// - (void)removeObserver:(NSObject *)observer fromObjectsAtIndexes:(NSIndexSet *)indexes forKeyPath:(NSString *)keyPath;
// - (void)addObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath options:(NSKeyValueObservingOptions)options context:(void *)context;
// - (void)removeObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath context:(void *)context __attribute__((availability(macosx,introduced=10.7)));
// - (void)removeObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath;
/* @end */
// @interface NSOrderedSet(NSKeyValueObserverRegistration)
// - (void)addObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath options:(NSKeyValueObservingOptions)options context:(void *)context;
// - (void)removeObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath context:(void *)context __attribute__((availability(macosx,introduced=10.7)));
// - (void)removeObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath;
/* @end */
// @interface NSSet(NSKeyValueObserverRegistration)
// - (void)addObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath options:(NSKeyValueObservingOptions)options context:(void *)context;
// - (void)removeObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath context:(void *)context __attribute__((availability(macosx,introduced=10.7)));
// - (void)removeObserver:(NSObject *)observer forKeyPath:(NSString *)keyPath;
/* @end */
// @interface NSObject(NSKeyValueObserverNotification)
// - (void)willChangeValueForKey:(NSString *)key;
// - (void)didChangeValueForKey:(NSString *)key;
// - (void)willChange:(NSKeyValueChange)changeKind valuesAtIndexes:(NSIndexSet *)indexes forKey:(NSString *)key;
// - (void)didChange:(NSKeyValueChange)changeKind valuesAtIndexes:(NSIndexSet *)indexes forKey:(NSString *)key;
// - (void)willChangeValueForKey:(NSString *)key withSetMutation:(NSKeyValueSetMutationKind)mutationKind usingObjects:(NSSet *)objects;
// - (void)didChangeValueForKey:(NSString *)key withSetMutation:(NSKeyValueSetMutationKind)mutationKind usingObjects:(NSSet *)objects;
/* @end */
// @interface NSObject(NSKeyValueObservingCustomization)
// + (NSSet *)keyPathsForValuesAffectingValueForKey:(NSString *)key __attribute__((availability(macosx,introduced=10.5)));
// + (BOOL)automaticallyNotifiesObserversForKey:(NSString *)key;
// @property void *observationInfo __attribute__((objc_returns_inner_pointer));
/* @end */
// @interface NSObject(NSDeprecatedKeyValueObservingCustomization)
// + (void)setKeys:(NSArray *)keys triggerChangeNotificationsForDependentKey:(NSString *)dependentKey __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
/* @end */
// @class NSData;
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
#ifndef _REWRITER_typedef_NSInputStream
#define _REWRITER_typedef_NSInputStream
typedef struct objc_object NSInputStream;
typedef struct {} _objc_exc_NSInputStream;
#endif
#ifndef _REWRITER_typedef_NSOutputStream
#define _REWRITER_typedef_NSOutputStream
typedef struct objc_object NSOutputStream;
typedef struct {} _objc_exc_NSOutputStream;
#endif
typedef NSUInteger NSPropertyListMutabilityOptions; enum {
NSPropertyListImmutable = kCFPropertyListImmutable,
NSPropertyListMutableContainers = kCFPropertyListMutableContainers,
NSPropertyListMutableContainersAndLeaves = kCFPropertyListMutableContainersAndLeaves
};
typedef NSUInteger NSPropertyListFormat; enum {
NSPropertyListOpenStepFormat = kCFPropertyListOpenStepFormat,
NSPropertyListXMLFormat_v1_0 = kCFPropertyListXMLFormat_v1_0,
NSPropertyListBinaryFormat_v1_0 = kCFPropertyListBinaryFormat_v1_0
};
typedef NSUInteger NSPropertyListReadOptions;
typedef NSUInteger NSPropertyListWriteOptions;
#ifndef _REWRITER_typedef_NSPropertyListSerialization
#define _REWRITER_typedef_NSPropertyListSerialization
typedef struct objc_object NSPropertyListSerialization;
typedef struct {} _objc_exc_NSPropertyListSerialization;
#endif
struct NSPropertyListSerialization_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *reserved[6];
};
// + (BOOL)propertyList:(id)plist isValidForFormat:(NSPropertyListFormat)format;
// + (NSData *)dataWithPropertyList:(id)plist format:(NSPropertyListFormat)format options:(NSPropertyListWriteOptions)opt error:(out NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// + (NSInteger)writePropertyList:(id)plist toStream:(NSOutputStream *)stream format:(NSPropertyListFormat)format options:(NSPropertyListWriteOptions)opt error:(out NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// + (id)propertyListWithData:(NSData *)data options:(NSPropertyListReadOptions)opt format:(NSPropertyListFormat *)format error:(out NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// + (id)propertyListWithStream:(NSInputStream *)stream options:(NSPropertyListReadOptions)opt format:(NSPropertyListFormat *)format error:(out NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// + (NSData *)dataFromPropertyList:(id)plist format:(NSPropertyListFormat)format errorDescription:(out NSString **)errorString __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.10,message="" "Use dataWithPropertyList:format:options:error: instead.")));
// + (id)propertyListFromData:(NSData *)data mutabilityOption:(NSPropertyListMutabilityOptions)opt format:(NSPropertyListFormat *)format errorDescription:(out NSString **)errorString __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.10,message="" "Use propertyListWithData:options:format:error: instead.")));
/* @end */
typedef double CGFloat;
struct CGPoint {
CGFloat x;
CGFloat y;
};
typedef struct CGPoint CGPoint;
struct CGSize {
CGFloat width;
CGFloat height;
};
typedef struct CGSize CGSize;
struct CGVector {
CGFloat dx;
CGFloat dy;
};
typedef struct CGVector CGVector;
struct CGRect {
CGPoint origin;
CGSize size;
};
typedef struct CGRect CGRect;
typedef uint32_t CGRectEdge; enum {
CGRectMinXEdge, CGRectMinYEdge, CGRectMaxXEdge, CGRectMaxYEdge
};
extern "C" const CGPoint CGPointZero
__attribute__((availability(macosx,introduced=10.0)));
extern "C" const CGSize CGSizeZero
__attribute__((availability(macosx,introduced=10.0)));
extern "C" const CGRect CGRectZero
__attribute__((availability(macosx,introduced=10.0)));
extern "C" const CGRect CGRectNull
__attribute__((availability(macosx,introduced=10.0)));
extern "C" const CGRect CGRectInfinite
__attribute__((availability(macosx,introduced=10.4)));
static inline CGPoint CGPointMake(CGFloat x, CGFloat y);
static inline CGSize CGSizeMake(CGFloat width, CGFloat height);
static inline CGVector CGVectorMake(CGFloat dx, CGFloat dy);
static inline CGRect CGRectMake(CGFloat x, CGFloat y, CGFloat width,
CGFloat height);
extern "C" CGFloat CGRectGetMinX(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGFloat CGRectGetMidX(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGFloat CGRectGetMaxX(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGFloat CGRectGetMinY(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGFloat CGRectGetMidY(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGFloat CGRectGetMaxY(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGFloat CGRectGetWidth(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGFloat CGRectGetHeight(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" bool CGPointEqualToPoint(CGPoint point1, CGPoint point2)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" bool CGSizeEqualToSize(CGSize size1, CGSize size2)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" bool CGRectEqualToRect(CGRect rect1, CGRect rect2)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGRect CGRectStandardize(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" bool CGRectIsEmpty(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" bool CGRectIsNull(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" bool CGRectIsInfinite(CGRect rect)
__attribute__((availability(macosx,introduced=10.4)));
extern "C" CGRect CGRectInset(CGRect rect, CGFloat dx, CGFloat dy)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGRect CGRectIntegral(CGRect rect)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGRect CGRectUnion(CGRect r1, CGRect r2)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGRect CGRectIntersection(CGRect r1, CGRect r2)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CGRect CGRectOffset(CGRect rect, CGFloat dx, CGFloat dy)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" void CGRectDivide(CGRect rect, CGRect *slice, CGRect *remainder,
CGFloat amount, CGRectEdge edge)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" bool CGRectContainsPoint(CGRect rect, CGPoint point)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" bool CGRectContainsRect(CGRect rect1, CGRect rect2)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" bool CGRectIntersectsRect(CGRect rect1, CGRect rect2)
__attribute__((availability(macosx,introduced=10.0)));
extern "C" CFDictionaryRef CGPointCreateDictionaryRepresentation(CGPoint point)
__attribute__((availability(macosx,introduced=10.5)));
extern "C" bool CGPointMakeWithDictionaryRepresentation(CFDictionaryRef dict,
CGPoint *point) __attribute__((availability(macosx,introduced=10.5)));
extern "C" CFDictionaryRef CGSizeCreateDictionaryRepresentation(CGSize size)
__attribute__((availability(macosx,introduced=10.5)));
extern "C" bool CGSizeMakeWithDictionaryRepresentation(CFDictionaryRef dict,
CGSize *size) __attribute__((availability(macosx,introduced=10.5)));
extern "C" CFDictionaryRef CGRectCreateDictionaryRepresentation(CGRect)
__attribute__((availability(macosx,introduced=10.5)));
extern "C" bool CGRectMakeWithDictionaryRepresentation(CFDictionaryRef dict,
CGRect *rect) __attribute__((availability(macosx,introduced=10.5)));
static inline CGPoint
CGPointMake(CGFloat x, CGFloat y)
{
CGPoint p; p.x = x; p.y = y; return p;
}
static inline CGSize
CGSizeMake(CGFloat width, CGFloat height)
{
CGSize size; size.width = width; size.height = height; return size;
}
static inline CGVector
CGVectorMake(CGFloat dx, CGFloat dy)
{
CGVector vector; vector.dx = dx; vector.dy = dy; return vector;
}
static inline CGRect
CGRectMake(CGFloat x, CGFloat y, CGFloat width, CGFloat height)
{
CGRect rect;
rect.origin.x = x; rect.origin.y = y;
rect.size.width = width; rect.size.height = height;
return rect;
}
static inline bool
__CGPointEqualToPoint(CGPoint point1, CGPoint point2)
{
return point1.x == point2.x && point1.y == point2.y;
}
static inline bool
__CGSizeEqualToSize(CGSize size1, CGSize size2)
{
return size1.width == size2.width && size1.height == size2.height;
}
typedef CGPoint NSPoint;
typedef NSPoint *NSPointPointer;
typedef NSPoint *NSPointArray;
typedef CGSize NSSize;
typedef NSSize *NSSizePointer;
typedef NSSize *NSSizeArray;
typedef CGRect NSRect;
typedef NSRect *NSRectPointer;
typedef NSRect *NSRectArray;
typedef NSUInteger NSRectEdge;
typedef struct NSEdgeInsets {
CGFloat top;
CGFloat left;
CGFloat bottom;
CGFloat right;
} NSEdgeInsets;
typedef unsigned long long NSAlignmentOptions; enum {
NSAlignMinXInward = 1ULL << 0,
NSAlignMinYInward = 1ULL << 1,
NSAlignMaxXInward = 1ULL << 2,
NSAlignMaxYInward = 1ULL << 3,
NSAlignWidthInward = 1ULL << 4,
NSAlignHeightInward = 1ULL << 5,
NSAlignMinXOutward = 1ULL << 8,
NSAlignMinYOutward = 1ULL << 9,
NSAlignMaxXOutward = 1ULL << 10,
NSAlignMaxYOutward = 1ULL << 11,
NSAlignWidthOutward = 1ULL << 12,
NSAlignHeightOutward = 1ULL << 13,
NSAlignMinXNearest = 1ULL << 16,
NSAlignMinYNearest = 1ULL << 17,
NSAlignMaxXNearest = 1ULL << 18,
NSAlignMaxYNearest = 1ULL << 19,
NSAlignWidthNearest = 1ULL << 20,
NSAlignHeightNearest = 1ULL << 21,
NSAlignRectFlipped = 1ULL << 63,
NSAlignAllEdgesInward = NSAlignMinXInward|NSAlignMaxXInward|NSAlignMinYInward|NSAlignMaxYInward,
NSAlignAllEdgesOutward = NSAlignMinXOutward|NSAlignMaxXOutward|NSAlignMinYOutward|NSAlignMaxYOutward,
NSAlignAllEdgesNearest = NSAlignMinXNearest|NSAlignMaxXNearest|NSAlignMinYNearest|NSAlignMaxYNearest,
};
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
extern "C" const NSPoint NSZeroPoint;
extern "C" const NSSize NSZeroSize;
extern "C" const NSRect NSZeroRect;
extern "C" const NSEdgeInsets NSEdgeInsetsZero __attribute__((availability(macosx,introduced=10.10)));
static __inline__ __attribute__((always_inline)) NSPoint NSMakePoint(CGFloat x, CGFloat y) {
NSPoint p;
p.x = x;
p.y = y;
return p;
}
static __inline__ __attribute__((always_inline)) NSSize NSMakeSize(CGFloat w, CGFloat h) {
NSSize s;
s.width = w;
s.height = h;
return s;
}
static __inline__ __attribute__((always_inline)) NSRect NSMakeRect(CGFloat x, CGFloat y, CGFloat w, CGFloat h) {
NSRect r;
r.origin.x = x;
r.origin.y = y;
r.size.width = w;
r.size.height = h;
return r;
}
static __inline__ __attribute__((always_inline)) CGFloat NSMaxX(NSRect aRect) {
return (aRect.origin.x + aRect.size.width);
}
static __inline__ __attribute__((always_inline)) CGFloat NSMaxY(NSRect aRect) {
return (aRect.origin.y + aRect.size.height);
}
static __inline__ __attribute__((always_inline)) CGFloat NSMidX(NSRect aRect) {
return (aRect.origin.x + aRect.size.width * (CGFloat)0.5);
}
static __inline__ __attribute__((always_inline)) CGFloat NSMidY(NSRect aRect) {
return (aRect.origin.y + aRect.size.height * (CGFloat)0.5);
}
static __inline__ __attribute__((always_inline)) CGFloat NSMinX(NSRect aRect) {
return (aRect.origin.x);
}
static __inline__ __attribute__((always_inline)) CGFloat NSMinY(NSRect aRect) {
return (aRect.origin.y);
}
static __inline__ __attribute__((always_inline)) CGFloat NSWidth(NSRect aRect) {
return (aRect.size.width);
}
static __inline__ __attribute__((always_inline)) CGFloat NSHeight(NSRect aRect) {
return (aRect.size.height);
}
static __inline__ __attribute__((always_inline)) NSRect NSRectFromCGRect(CGRect cgrect) {
union _ {NSRect ns; CGRect cg;};
return ((union _ *)&cgrect)->ns;
}
static __inline__ __attribute__((always_inline)) CGRect NSRectToCGRect(NSRect nsrect) {
union _ {NSRect ns; CGRect cg;};
return ((union _ *)&nsrect)->cg;
}
static __inline__ __attribute__((always_inline)) NSPoint NSPointFromCGPoint(CGPoint cgpoint) {
union _ {NSPoint ns; CGPoint cg;};
return ((union _ *)&cgpoint)->ns;
}
static __inline__ __attribute__((always_inline)) CGPoint NSPointToCGPoint(NSPoint nspoint) {
union _ {NSPoint ns; CGPoint cg;};
return ((union _ *)&nspoint)->cg;
}
static __inline__ __attribute__((always_inline)) NSSize NSSizeFromCGSize(CGSize cgsize) {
union _ {NSSize ns; CGSize cg;};
return ((union _ *)&cgsize)->ns;
}
static __inline__ __attribute__((always_inline)) CGSize NSSizeToCGSize(NSSize nssize) {
union _ {NSSize ns; CGSize cg;};
return ((union _ *)&nssize)->cg;
}
static __inline__ __attribute__((always_inline)) NSEdgeInsets NSEdgeInsetsMake(CGFloat top, CGFloat left, CGFloat bottom, CGFloat right) {
NSEdgeInsets e;
e.top = top;
e.left = left;
e.bottom = bottom;
e.right = right;
return e;
}
extern "C" BOOL NSEqualPoints(NSPoint aPoint, NSPoint bPoint);
extern "C" BOOL NSEqualSizes(NSSize aSize, NSSize bSize);
extern "C" BOOL NSEqualRects(NSRect aRect, NSRect bRect);
extern "C" BOOL NSIsEmptyRect(NSRect aRect);
extern "C" BOOL NSEdgeInsetsEqual(NSEdgeInsets aInsets, NSEdgeInsets bInsets) __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSRect NSInsetRect(NSRect aRect, CGFloat dX, CGFloat dY);
extern "C" NSRect NSIntegralRect(NSRect aRect);
extern "C" NSRect NSIntegralRectWithOptions(NSRect aRect, NSAlignmentOptions opts) __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSRect NSUnionRect(NSRect aRect, NSRect bRect);
extern "C" NSRect NSIntersectionRect(NSRect aRect, NSRect bRect);
extern "C" NSRect NSOffsetRect(NSRect aRect, CGFloat dX, CGFloat dY);
extern "C" void NSDivideRect(NSRect inRect, NSRect *slice, NSRect *rem, CGFloat amount, NSRectEdge edge);
extern "C" BOOL NSPointInRect(NSPoint aPoint, NSRect aRect);
extern "C" BOOL NSMouseInRect(NSPoint aPoint, NSRect aRect, BOOL flipped);
extern "C" BOOL NSContainsRect(NSRect aRect, NSRect bRect);
extern "C" BOOL NSIntersectsRect(NSRect aRect, NSRect bRect);
extern "C" NSString *NSStringFromPoint(NSPoint aPoint);
extern "C" NSString *NSStringFromSize(NSSize aSize);
extern "C" NSString *NSStringFromRect(NSRect aRect);
extern "C" NSPoint NSPointFromString(NSString *aString);
extern "C" NSSize NSSizeFromString(NSString *aString);
extern "C" NSRect NSRectFromString(NSString *aString);
// @interface NSValue (NSValueGeometryExtensions)
// + (NSValue *)valueWithPoint:(NSPoint)point;
// + (NSValue *)valueWithSize:(NSSize)size;
// + (NSValue *)valueWithRect:(NSRect)rect;
// + (NSValue *)valueWithEdgeInsets:(NSEdgeInsets)insets __attribute__((availability(macosx,introduced=10.10)));
// @property (readonly) NSPoint pointValue;
// @property (readonly) NSSize sizeValue;
// @property (readonly) NSRect rectValue;
// @property (readonly) NSEdgeInsets edgeInsetsValue __attribute__((availability(macosx,introduced=10.10)));
/* @end */
// @interface NSCoder (NSGeometryCoding)
// - (void)encodePoint:(NSPoint)point;
// - (NSPoint)decodePoint;
// - (void)encodeSize:(NSSize)size;
// - (NSSize)decodeSize;
// - (void)encodeRect:(NSRect)rect;
// - (NSRect)decodeRect;
/* @end */
// @interface NSCoder (NSGeometryKeyedCoding)
// - (void)encodePoint:(NSPoint)point forKey:(NSString *)key;
// - (void)encodeSize:(NSSize)size forKey:(NSString *)key;
// - (void)encodeRect:(NSRect)rect forKey:(NSString *)key;
// - (NSPoint)decodePointForKey:(NSString *)key;
// - (NSSize)decodeSizeForKey:(NSString *)key;
// - (NSRect)decodeRectForKey:(NSString *)key;
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSMutableData
#define _REWRITER_typedef_NSMutableData
typedef struct objc_object NSMutableData;
typedef struct {} _objc_exc_NSMutableData;
#endif
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
// @protocol NSKeyedArchiverDelegate, NSKeyedUnarchiverDelegate;
extern "C" NSString * const NSInvalidArchiveOperationException;
extern "C" NSString * const NSInvalidUnarchiveOperationException;
extern "C" NSString * const NSKeyedArchiveRootObjectKey __attribute__((availability(macosx,introduced=10.9)));
#ifndef _REWRITER_typedef_NSKeyedArchiver
#define _REWRITER_typedef_NSKeyedArchiver
typedef struct objc_object NSKeyedArchiver;
typedef struct {} _objc_exc_NSKeyedArchiver;
#endif
struct NSKeyedArchiver_IMPL {
struct NSCoder_IMPL NSCoder_IVARS;
void *_stream;
NSUInteger _flags;
id _delegate;
id _containers;
id _objects;
id _objRefMap;
id _replacementMap;
id _classNameMap;
id _conditionals;
id _classes;
NSUInteger _genericKey;
void *_cache;
NSUInteger _cacheSize;
NSUInteger _estimatedCount;
void *_reserved2;
id _visited;
void *_reserved0;
};
// + (NSData *)archivedDataWithRootObject:(id)rootObject;
// + (BOOL)archiveRootObject:(id)rootObject toFile:(NSString *)path;
// - (instancetype)initForWritingWithMutableData:(NSMutableData *)data;
// @property (assign) id <NSKeyedArchiverDelegate> delegate;
// @property NSPropertyListFormat outputFormat;
// - (void)finishEncoding;
// + (void)setClassName:(NSString *)codedName forClass:(Class)cls;
// - (void)setClassName:(NSString *)codedName forClass:(Class)cls;
// + (NSString *)classNameForClass:(Class)cls;
// - (NSString *)classNameForClass:(Class)cls;
// - (void)encodeObject:(id)objv forKey:(NSString *)key;
// - (void)encodeConditionalObject:(id)objv forKey:(NSString *)key;
// - (void)encodeBool:(BOOL)boolv forKey:(NSString *)key;
// - (void)encodeInt:(int)intv forKey:(NSString *)key;
// - (void)encodeInt32:(int32_t)intv forKey:(NSString *)key;
// - (void)encodeInt64:(int64_t)intv forKey:(NSString *)key;
// - (void)encodeFloat:(float)realv forKey:(NSString *)key;
// - (void)encodeDouble:(double)realv forKey:(NSString *)key;
// - (void)encodeBytes:(const uint8_t *)bytesp length:(NSUInteger)lenv forKey:(NSString *)key;
// - (void)setRequiresSecureCoding:(BOOL)b __attribute__((availability(macosx,introduced=10.8)));
/* @end */
#ifndef _REWRITER_typedef_NSKeyedUnarchiver
#define _REWRITER_typedef_NSKeyedUnarchiver
typedef struct objc_object NSKeyedUnarchiver;
typedef struct {} _objc_exc_NSKeyedUnarchiver;
#endif
struct NSKeyedUnarchiver_IMPL {
struct NSCoder_IMPL NSCoder_IVARS;
id _delegate;
uint32_t _flags;
id _objRefMap;
id _replacementMap;
id _nameClassMap;
id _tmpRefObjMap;
id _refObjMap;
int32_t _genericKey;
id _data;
void *_offsetData;
id _containers;
id _objects;
const uint8_t *_bytes;
uint64_t _len;
id _helper;
void *_reserved0;
};
// + (id)unarchiveObjectWithData:(NSData *)data;
// + (id)unarchiveObjectWithFile:(NSString *)path;
// - (instancetype)initForReadingWithData:(NSData *)data;
// @property (assign) id <NSKeyedUnarchiverDelegate> delegate;
// - (void)finishDecoding;
// + (void)setClass:(Class)cls forClassName:(NSString *)codedName;
// - (void)setClass:(Class)cls forClassName:(NSString *)codedName;
// + (Class)classForClassName:(NSString *)codedName;
// - (Class)classForClassName:(NSString *)codedName;
// - (BOOL)containsValueForKey:(NSString *)key;
// - (id)decodeObjectForKey:(NSString *)key;
// - (BOOL)decodeBoolForKey:(NSString *)key;
// - (int)decodeIntForKey:(NSString *)key;
// - (int32_t)decodeInt32ForKey:(NSString *)key;
// - (int64_t)decodeInt64ForKey:(NSString *)key;
// - (float)decodeFloatForKey:(NSString *)key;
// - (double)decodeDoubleForKey:(NSString *)key;
// - (const uint8_t *)decodeBytesForKey:(NSString *)key returnedLength:(NSUInteger *)lengthp __attribute__((objc_returns_inner_pointer));
// - (void)setRequiresSecureCoding:(BOOL)b __attribute__((availability(macosx,introduced=10.8)));
/* @end */
// @protocol NSKeyedArchiverDelegate <NSObject>
/* @optional */
// - (id)archiver:(NSKeyedArchiver *)archiver willEncodeObject:(id)object;
// - (void)archiver:(NSKeyedArchiver *)archiver didEncodeObject:(id)object;
// - (void)archiver:(NSKeyedArchiver *)archiver willReplaceObject:(id)object withObject:(id)newObject;
// - (void)archiverWillFinish:(NSKeyedArchiver *)archiver;
// - (void)archiverDidFinish:(NSKeyedArchiver *)archiver;
/* @end */
// @protocol NSKeyedUnarchiverDelegate <NSObject>
/* @optional */
// - (Class)unarchiver:(NSKeyedUnarchiver *)unarchiver cannotDecodeObjectOfClassName:(NSString *)name originalClasses:(NSArray *)classNames;
// - (id)unarchiver:(NSKeyedUnarchiver *)unarchiver didDecodeObject:(id) __attribute__((ns_consumed)) object __attribute__((ns_returns_retained));
// - (void)unarchiver:(NSKeyedUnarchiver *)unarchiver willReplaceObject:(id)object withObject:(id)newObject;
// - (void)unarchiverWillFinish:(NSKeyedUnarchiver *)unarchiver;
// - (void)unarchiverDidFinish:(NSKeyedUnarchiver *)unarchiver;
/* @end */
// @interface NSObject (NSKeyedArchiverObjectSubstitution)
// @property (readonly) Class classForKeyedArchiver;
// - (id)replacementObjectForKeyedArchiver:(NSKeyedArchiver *)archiver;
// + (NSArray *)classFallbacksForKeyedArchiver;
/* @end */
// @interface NSObject (NSKeyedUnarchiverObjectSubstitution)
// + (Class)classForKeyedUnarchiver;
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSLocale
#define _REWRITER_typedef_NSLocale
typedef struct objc_object NSLocale;
typedef struct {} _objc_exc_NSLocale;
#endif
struct NSLocale_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (id)objectForKey:(id)key;
// - (NSString *)displayNameForKey:(id)key value:(id)value;
// - (instancetype)initWithLocaleIdentifier:(NSString *)string __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSLocale (NSExtendedLocale)
// @property (readonly, copy) NSString *localeIdentifier;
/* @end */
// @interface NSLocale (NSLocaleCreation)
// + (NSLocale *)autoupdatingCurrentLocale __attribute__((availability(macosx,introduced=10.5)));
// + (NSLocale *)currentLocale;
// + (NSLocale *)systemLocale;
// + (instancetype)localeWithLocaleIdentifier:(NSString *)ident __attribute__((availability(macosx,introduced=10.6)));
// - (instancetype)init __attribute__((unavailable));
/* @end */
// @interface NSLocale (NSLocaleGeneralInfo)
// + (NSArray *)availableLocaleIdentifiers;
// + (NSArray *)ISOLanguageCodes;
// + (NSArray *)ISOCountryCodes;
// + (NSArray *)ISOCurrencyCodes;
// + (NSArray *)commonISOCurrencyCodes __attribute__((availability(macosx,introduced=10.5)));
// + (NSArray *)preferredLanguages __attribute__((availability(macosx,introduced=10.5)));
// + (NSDictionary *)componentsFromLocaleIdentifier:(NSString *)string;
// + (NSString *)localeIdentifierFromComponents:(NSDictionary *)dict;
// + (NSString *)canonicalLocaleIdentifierFromString:(NSString *)string;
// + (NSString *)canonicalLanguageIdentifierFromString:(NSString *)string;
// + (NSString *)localeIdentifierFromWindowsLocaleCode:(uint32_t)lcid __attribute__((availability(macosx,introduced=10.6)));
// + (uint32_t)windowsLocaleCodeFromLocaleIdentifier:(NSString *)localeIdentifier __attribute__((availability(macosx,introduced=10.6)));
typedef NSUInteger NSLocaleLanguageDirection; enum {
NSLocaleLanguageDirectionUnknown = kCFLocaleLanguageDirectionUnknown,
NSLocaleLanguageDirectionLeftToRight = kCFLocaleLanguageDirectionLeftToRight,
NSLocaleLanguageDirectionRightToLeft = kCFLocaleLanguageDirectionRightToLeft,
NSLocaleLanguageDirectionTopToBottom = kCFLocaleLanguageDirectionTopToBottom,
NSLocaleLanguageDirectionBottomToTop = kCFLocaleLanguageDirectionBottomToTop
};
// + (NSLocaleLanguageDirection)characterDirectionForLanguage:(NSString *)isoLangCode __attribute__((availability(macosx,introduced=10.6)));
// + (NSLocaleLanguageDirection)lineDirectionForLanguage:(NSString *)isoLangCode __attribute__((availability(macosx,introduced=10.6)));
/* @end */
extern "C" NSString * const NSCurrentLocaleDidChangeNotification __attribute__((availability(macosx,introduced=10.5)));
extern "C" NSString * const NSLocaleIdentifier;
extern "C" NSString * const NSLocaleLanguageCode;
extern "C" NSString * const NSLocaleCountryCode;
extern "C" NSString * const NSLocaleScriptCode;
extern "C" NSString * const NSLocaleVariantCode;
extern "C" NSString * const NSLocaleExemplarCharacterSet;
extern "C" NSString * const NSLocaleCalendar;
extern "C" NSString * const NSLocaleCollationIdentifier;
extern "C" NSString * const NSLocaleUsesMetricSystem;
extern "C" NSString * const NSLocaleMeasurementSystem;
extern "C" NSString * const NSLocaleDecimalSeparator;
extern "C" NSString * const NSLocaleGroupingSeparator;
extern "C" NSString * const NSLocaleCurrencySymbol;
extern "C" NSString * const NSLocaleCurrencyCode;
extern "C" NSString * const NSLocaleCollatorIdentifier __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSLocaleQuotationBeginDelimiterKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSLocaleQuotationEndDelimiterKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSLocaleAlternateQuotationBeginDelimiterKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSLocaleAlternateQuotationEndDelimiterKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSGregorianCalendar __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarIdentifierGregorian instead")));
extern "C" NSString * const NSBuddhistCalendar __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarIdentifierBuddhist instead")));
extern "C" NSString * const NSChineseCalendar __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarIdentifierChinese instead")));
extern "C" NSString * const NSHebrewCalendar __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarIdentifierHebrew instead")));
extern "C" NSString * const NSIslamicCalendar __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarIdentifierIslamic instead")));
extern "C" NSString * const NSIslamicCivilCalendar __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarIdentifierIslamicCivil instead")));
extern "C" NSString * const NSJapaneseCalendar __attribute__((availability(macosx,introduced=10.4 ,deprecated=10.10,message="" "Use NSCalendarIdentifierJapanese instead")));
extern "C" NSString * const NSRepublicOfChinaCalendar __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.10,message="" "Use NSCalendarIdentifierRepublicOfChina instead")));
extern "C" NSString * const NSPersianCalendar __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.10,message="" "Use NSCalendarIdentifierPersian instead")));
extern "C" NSString * const NSIndianCalendar __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.10,message="" "Use NSCalendarIdentifierIndian instead")));
extern "C" NSString * const NSISO8601Calendar __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.10,message="" "Use NSCalendarIdentifierISO8601 instead")));
// @class NSDate;
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
// @protocol NSLocking
// - (void)lock;
// - (void)unlock;
/* @end */
#ifndef _REWRITER_typedef_NSLock
#define _REWRITER_typedef_NSLock
typedef struct objc_object NSLock;
typedef struct {} _objc_exc_NSLock;
#endif
struct NSLock_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *_priv;
};
// - (BOOL)tryLock;
// - (BOOL)lockBeforeDate:(NSDate *)limit;
// @property (copy) NSString *name __attribute__((availability(macosx,introduced=10.5)));
/* @end */
#ifndef _REWRITER_typedef_NSConditionLock
#define _REWRITER_typedef_NSConditionLock
typedef struct objc_object NSConditionLock;
typedef struct {} _objc_exc_NSConditionLock;
#endif
struct NSConditionLock_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *_priv;
};
// - (instancetype)initWithCondition:(NSInteger)condition __attribute__((objc_designated_initializer));
// @property (readonly) NSInteger condition;
// - (void)lockWhenCondition:(NSInteger)condition;
// - (BOOL)tryLock;
// - (BOOL)tryLockWhenCondition:(NSInteger)condition;
// - (void)unlockWithCondition:(NSInteger)condition;
// - (BOOL)lockBeforeDate:(NSDate *)limit;
// - (BOOL)lockWhenCondition:(NSInteger)condition beforeDate:(NSDate *)limit;
// @property (copy) NSString *name __attribute__((availability(macosx,introduced=10.5)));
/* @end */
#ifndef _REWRITER_typedef_NSRecursiveLock
#define _REWRITER_typedef_NSRecursiveLock
typedef struct objc_object NSRecursiveLock;
typedef struct {} _objc_exc_NSRecursiveLock;
#endif
struct NSRecursiveLock_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *_priv;
};
// - (BOOL)tryLock;
// - (BOOL)lockBeforeDate:(NSDate *)limit;
// @property (copy) NSString *name __attribute__((availability(macosx,introduced=10.5)));
/* @end */
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.5)))
#ifndef _REWRITER_typedef_NSCondition
#define _REWRITER_typedef_NSCondition
typedef struct objc_object NSCondition;
typedef struct {} _objc_exc_NSCondition;
#endif
struct NSCondition_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *_priv;
};
// - (void)wait;
// - (BOOL)waitUntilDate:(NSDate *)limit;
// - (void)signal;
// - (void)broadcast;
// @property (copy) NSString *name __attribute__((availability(macosx,introduced=10.5)));
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSMapTable
#define _REWRITER_typedef_NSMapTable
typedef struct objc_object NSMapTable;
typedef struct {} _objc_exc_NSMapTable;
#endif
enum {
NSMapTableStrongMemory __attribute__((availability(macosx,introduced=10.5))) = 0,
NSMapTableZeroingWeakMemory __attribute__((availability(macosx,introduced=10.5 ,deprecated=10.8,message="" ))) = NSPointerFunctionsZeroingWeakMemory,
NSMapTableCopyIn __attribute__((availability(macosx,introduced=10.5))) = NSPointerFunctionsCopyIn,
NSMapTableObjectPointerPersonality __attribute__((availability(macosx,introduced=10.5))) = NSPointerFunctionsObjectPointerPersonality,
NSMapTableWeakMemory __attribute__((availability(macosx,introduced=10.8))) = NSPointerFunctionsWeakMemory
};
typedef NSUInteger NSMapTableOptions;
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.5)))
#ifndef _REWRITER_typedef_NSMapTable
#define _REWRITER_typedef_NSMapTable
typedef struct objc_object NSMapTable;
typedef struct {} _objc_exc_NSMapTable;
#endif
struct NSMapTable_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (instancetype)initWithKeyOptions:(NSPointerFunctionsOptions)keyOptions valueOptions:(NSPointerFunctionsOptions)valueOptions capacity:(NSUInteger)initialCapacity __attribute__((objc_designated_initializer));
// - (instancetype)initWithKeyPointerFunctions:(NSPointerFunctions *)keyFunctions valuePointerFunctions:(NSPointerFunctions *)valueFunctions capacity:(NSUInteger)initialCapacity __attribute__((objc_designated_initializer));
// + (NSMapTable *)mapTableWithKeyOptions:(NSPointerFunctionsOptions)keyOptions valueOptions:(NSPointerFunctionsOptions)valueOptions;
// + (id)mapTableWithStrongToStrongObjects __attribute__((availability(macosx,introduced=10.5 ,deprecated=10.8,message="" )));
// + (id)mapTableWithWeakToStrongObjects __attribute__((availability(macosx,introduced=10.5 ,deprecated=10.8,message="" )));
// + (id)mapTableWithStrongToWeakObjects __attribute__((availability(macosx,introduced=10.5 ,deprecated=10.8,message="" )));
// + (id)mapTableWithWeakToWeakObjects __attribute__((availability(macosx,introduced=10.5 ,deprecated=10.8,message="" )));
// + (NSMapTable *)strongToStrongObjectsMapTable __attribute__((availability(macosx,introduced=10.8)));
// + (NSMapTable *)weakToStrongObjectsMapTable __attribute__((availability(macosx,introduced=10.8)));
// + (NSMapTable *)strongToWeakObjectsMapTable __attribute__((availability(macosx,introduced=10.8)));
// + (NSMapTable *)weakToWeakObjectsMapTable __attribute__((availability(macosx,introduced=10.8)));
// @property (readonly, copy) NSPointerFunctions *keyPointerFunctions;
// @property (readonly, copy) NSPointerFunctions *valuePointerFunctions;
// - (id)objectForKey:(id)aKey;
// - (void)removeObjectForKey:(id)aKey;
// - (void)setObject:(id)anObject forKey:(id)aKey;
// @property (readonly) NSUInteger count;
// - (NSEnumerator *)keyEnumerator;
// - (NSEnumerator *)objectEnumerator;
// - (void)removeAllObjects;
// - (NSDictionary *)dictionaryRepresentation;
/* @end */
typedef struct {NSUInteger _pi; NSUInteger _si; void *_bs;} NSMapEnumerator;
extern "C" void NSFreeMapTable(NSMapTable *table);
extern "C" void NSResetMapTable(NSMapTable *table);
extern "C" BOOL NSCompareMapTables(NSMapTable *table1, NSMapTable *table2);
extern "C" NSMapTable *NSCopyMapTableWithZone(NSMapTable *table, NSZone *zone);
extern "C" BOOL NSMapMember(NSMapTable *table, const void *key, void **originalKey, void **value);
extern "C" void *NSMapGet(NSMapTable *table, const void *key);
extern "C" void NSMapInsert(NSMapTable *table, const void *key, const void *value);
extern "C" void NSMapInsertKnownAbsent(NSMapTable *table, const void *key, const void *value);
extern "C" void *NSMapInsertIfAbsent(NSMapTable *table, const void *key, const void *value);
extern "C" void NSMapRemove(NSMapTable *table, const void *key);
extern "C" NSMapEnumerator NSEnumerateMapTable(NSMapTable *table);
extern "C" BOOL NSNextMapEnumeratorPair(NSMapEnumerator *enumerator, void **key, void **value);
extern "C" void NSEndMapTableEnumeration(NSMapEnumerator *enumerator);
extern "C" NSUInteger NSCountMapTable(NSMapTable *table);
extern "C" NSString *NSStringFromMapTable(NSMapTable *table);
extern "C" NSArray *NSAllMapTableKeys(NSMapTable *table);
extern "C" NSArray *NSAllMapTableValues(NSMapTable *table);
typedef struct {
NSUInteger (*hash)(NSMapTable *table, const void *);
BOOL (*isEqual)(NSMapTable *table, const void *, const void *);
void (*retain)(NSMapTable *table, const void *);
void (*release)(NSMapTable *table, void *);
NSString *(*describe)(NSMapTable *table, const void *);
const void *notAKeyMarker;
} NSMapTableKeyCallBacks;
typedef struct {
void (*retain)(NSMapTable *table, const void *);
void (*release)(NSMapTable *table, void *);
NSString *(*describe)(NSMapTable *table, const void *);
} NSMapTableValueCallBacks;
extern "C" NSMapTable *NSCreateMapTableWithZone(NSMapTableKeyCallBacks keyCallBacks, NSMapTableValueCallBacks valueCallBacks, NSUInteger capacity, NSZone *zone);
extern "C" NSMapTable *NSCreateMapTable(NSMapTableKeyCallBacks keyCallBacks, NSMapTableValueCallBacks valueCallBacks, NSUInteger capacity);
extern "C" const NSMapTableKeyCallBacks NSIntegerMapKeyCallBacks __attribute__((availability(macosx,introduced=10.5)));
extern "C" const NSMapTableKeyCallBacks NSNonOwnedPointerMapKeyCallBacks;
extern "C" const NSMapTableKeyCallBacks NSNonOwnedPointerOrNullMapKeyCallBacks;
extern "C" const NSMapTableKeyCallBacks NSNonRetainedObjectMapKeyCallBacks;
extern "C" const NSMapTableKeyCallBacks NSObjectMapKeyCallBacks;
extern "C" const NSMapTableKeyCallBacks NSOwnedPointerMapKeyCallBacks;
extern "C" const NSMapTableKeyCallBacks NSIntMapKeyCallBacks __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
extern "C" const NSMapTableValueCallBacks NSIntegerMapValueCallBacks __attribute__((availability(macosx,introduced=10.5)));
extern "C" const NSMapTableValueCallBacks NSNonOwnedPointerMapValueCallBacks;
extern "C" const NSMapTableValueCallBacks NSObjectMapValueCallBacks;
extern "C" const NSMapTableValueCallBacks NSNonRetainedObjectMapValueCallBacks;
extern "C" const NSMapTableValueCallBacks NSOwnedPointerMapValueCallBacks;
extern "C" const NSMapTableValueCallBacks NSIntMapValueCallBacks __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
#ifndef _REWRITER_typedef_NSMethodSignature
#define _REWRITER_typedef_NSMethodSignature
typedef struct objc_object NSMethodSignature;
typedef struct {} _objc_exc_NSMethodSignature;
#endif
struct NSMethodSignature_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *_private;
void *_reserved[6];
};
// + (NSMethodSignature *)signatureWithObjCTypes:(const char *)types;
// @property (readonly) NSUInteger numberOfArguments;
// - (const char *)getArgumentTypeAtIndex:(NSUInteger)idx __attribute__((objc_returns_inner_pointer));
// @property (readonly) NSUInteger frameLength;
// - (BOOL)isOneway;
// @property (readonly) const char *methodReturnType __attribute__((objc_returns_inner_pointer));
// @property (readonly) NSUInteger methodReturnLength;
/* @end */
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSOperationQueue
#define _REWRITER_typedef_NSOperationQueue
typedef struct objc_object NSOperationQueue;
typedef struct {} _objc_exc_NSOperationQueue;
#endif
#ifndef _REWRITER_typedef_NSNotification
#define _REWRITER_typedef_NSNotification
typedef struct objc_object NSNotification;
typedef struct {} _objc_exc_NSNotification;
#endif
struct NSNotification_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly, copy) NSString *name;
// @property (readonly, retain) id object;
// @property (readonly, copy) NSDictionary *userInfo;
// - (instancetype)initWithName:(NSString *)name object:(id)object userInfo:(NSDictionary *)userInfo __attribute__((availability(macosx,introduced=10.6))) __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSNotification (NSNotificationCreation)
// + (instancetype)notificationWithName:(NSString *)aName object:(id)anObject;
// + (instancetype)notificationWithName:(NSString *)aName object:(id)anObject userInfo:(NSDictionary *)aUserInfo;
// - (instancetype)init ;
/* @end */
#ifndef _REWRITER_typedef_NSNotificationCenter
#define _REWRITER_typedef_NSNotificationCenter
typedef struct objc_object NSNotificationCenter;
typedef struct {} _objc_exc_NSNotificationCenter;
#endif
struct NSNotificationCenter_IMPL {
struct NSObject_IMPL NSObject_IVARS;
void *_impl;
void *_callback;
void *_pad[11];
};
// + (NSNotificationCenter *)defaultCenter;
// - (void)addObserver:(id)observer selector:(SEL)aSelector name:(NSString *)aName object:(id)anObject;
// - (void)postNotification:(NSNotification *)notification;
// - (void)postNotificationName:(NSString *)aName object:(id)anObject;
// - (void)postNotificationName:(NSString *)aName object:(id)anObject userInfo:(NSDictionary *)aUserInfo;
// - (void)removeObserver:(id)observer;
// - (void)removeObserver:(id)observer name:(NSString *)aName object:(id)anObject;
// - (id <NSObject>)addObserverForName:(NSString *)name object:(id)obj queue:(NSOperationQueue *)queue usingBlock:(void (^)(NSNotification *note))block __attribute__((availability(macosx,introduced=10.6)));
/* @end */
// @class NSNotification;
#ifndef _REWRITER_typedef_NSNotification
#define _REWRITER_typedef_NSNotification
typedef struct objc_object NSNotification;
typedef struct {} _objc_exc_NSNotification;
#endif
#ifndef _REWRITER_typedef_NSNotificationCenter
#define _REWRITER_typedef_NSNotificationCenter
typedef struct objc_object NSNotificationCenter;
typedef struct {} _objc_exc_NSNotificationCenter;
#endif
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
typedef NSUInteger NSPostingStyle; enum {
NSPostWhenIdle = 1,
NSPostASAP = 2,
NSPostNow = 3
};
typedef NSUInteger NSNotificationCoalescing; enum {
NSNotificationNoCoalescing = 0,
NSNotificationCoalescingOnName = 1,
NSNotificationCoalescingOnSender = 2
};
#ifndef _REWRITER_typedef_NSNotificationQueue
#define _REWRITER_typedef_NSNotificationQueue
typedef struct objc_object NSNotificationQueue;
typedef struct {} _objc_exc_NSNotificationQueue;
#endif
struct NSNotificationQueue_IMPL {
struct NSObject_IMPL NSObject_IVARS;
id _notificationCenter;
id _asapQueue;
id _asapObs;
id _idleQueue;
id _idleObs;
};
// + (NSNotificationQueue *)defaultQueue;
// - (instancetype)initWithNotificationCenter:(NSNotificationCenter *)notificationCenter __attribute__((objc_designated_initializer));
// - (void)enqueueNotification:(NSNotification *)notification postingStyle:(NSPostingStyle)postingStyle;
// - (void)enqueueNotification:(NSNotification *)notification postingStyle:(NSPostingStyle)postingStyle coalesceMask:(NSUInteger)coalesceMask forModes:(NSArray *)modes;
// - (void)dequeueNotificationsMatching:(NSNotification *)notification coalesceMask:(NSUInteger)coalesceMask;
/* @end */
#ifndef _REWRITER_typedef_NSNull
#define _REWRITER_typedef_NSNull
typedef struct objc_object NSNull;
typedef struct {} _objc_exc_NSNull;
#endif
struct NSNull_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// + (NSNull *)null;
/* @end */
// @class NSLocale;
#ifndef _REWRITER_typedef_NSLocale
#define _REWRITER_typedef_NSLocale
typedef struct objc_object NSLocale;
typedef struct {} _objc_exc_NSLocale;
#endif
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
#ifndef _REWRITER_typedef_NSMutableDictionary
#define _REWRITER_typedef_NSMutableDictionary
typedef struct objc_object NSMutableDictionary;
typedef struct {} _objc_exc_NSMutableDictionary;
#endif
#ifndef _REWRITER_typedef_NSRecursiveLock
#define _REWRITER_typedef_NSRecursiveLock
typedef struct objc_object NSRecursiveLock;
typedef struct {} _objc_exc_NSRecursiveLock;
#endif
typedef NSUInteger NSNumberFormatterBehavior; enum {
NSNumberFormatterBehaviorDefault = 0,
NSNumberFormatterBehavior10_0 = 1000,
NSNumberFormatterBehavior10_4 = 1040,
};
#ifndef _REWRITER_typedef_NSNumberFormatter
#define _REWRITER_typedef_NSNumberFormatter
typedef struct objc_object NSNumberFormatter;
typedef struct {} _objc_exc_NSNumberFormatter;
#endif
struct NSNumberFormatter_IMPL {
struct NSFormatter_IMPL NSFormatter_IVARS;
NSMutableDictionary *_attributes;
CFNumberFormatterRef _formatter;
NSUInteger _counter;
NSNumberFormatterBehavior _behavior;
NSRecursiveLock *_lock;
unsigned long _stateBitMask;
void *_reserved[9];
};
// @property NSFormattingContext formattingContext __attribute__((availability(macosx,introduced=10.10)));
// - (BOOL)getObjectValue:(out id *)obj forString:(NSString *)string range:(inout NSRange *)rangep error:(out NSError **)error;
// - (NSString *)stringFromNumber:(NSNumber *)number;
// - (NSNumber *)numberFromString:(NSString *)string;
typedef NSUInteger NSNumberFormatterStyle; enum {
NSNumberFormatterNoStyle = kCFNumberFormatterNoStyle,
NSNumberFormatterDecimalStyle = kCFNumberFormatterDecimalStyle,
NSNumberFormatterCurrencyStyle = kCFNumberFormatterCurrencyStyle,
NSNumberFormatterPercentStyle = kCFNumberFormatterPercentStyle,
NSNumberFormatterScientificStyle = kCFNumberFormatterScientificStyle,
NSNumberFormatterSpellOutStyle = kCFNumberFormatterSpellOutStyle,
};
// + (NSString *)localizedStringFromNumber:(NSNumber *)num numberStyle:(NSNumberFormatterStyle)nstyle __attribute__((availability(macosx,introduced=10.6)));
// + (NSNumberFormatterBehavior)defaultFormatterBehavior;
// + (void)setDefaultFormatterBehavior:(NSNumberFormatterBehavior)behavior;
// @property NSNumberFormatterStyle numberStyle;
// @property (copy) NSLocale *locale;
// @property BOOL generatesDecimalNumbers;
// @property NSNumberFormatterBehavior formatterBehavior;
// @property (copy) NSString *negativeFormat;
// @property (copy) NSDictionary *textAttributesForNegativeValues;
// @property (copy) NSString *positiveFormat;
// @property (copy) NSDictionary *textAttributesForPositiveValues;
// @property BOOL allowsFloats;
// @property (copy) NSString *decimalSeparator;
// @property BOOL alwaysShowsDecimalSeparator;
// @property (copy) NSString *currencyDecimalSeparator;
// @property BOOL usesGroupingSeparator;
// @property (copy) NSString *groupingSeparator;
// @property (copy) NSString *zeroSymbol;
// @property (copy) NSDictionary *textAttributesForZero;
// @property (copy) NSString *nilSymbol;
// @property (copy) NSDictionary *textAttributesForNil;
// @property (copy) NSString *notANumberSymbol;
// @property (copy) NSDictionary *textAttributesForNotANumber;
// @property (copy) NSString *positiveInfinitySymbol;
// @property (copy) NSDictionary *textAttributesForPositiveInfinity;
// @property (copy) NSString *negativeInfinitySymbol;
// @property (copy) NSDictionary *textAttributesForNegativeInfinity;
// @property (copy) NSString *positivePrefix;
// @property (copy) NSString *positiveSuffix;
// @property (copy) NSString *negativePrefix;
// @property (copy) NSString *negativeSuffix;
// @property (copy) NSString *currencyCode;
// @property (copy) NSString *currencySymbol;
// @property (copy) NSString *internationalCurrencySymbol;
// @property (copy) NSString *percentSymbol;
// @property (copy) NSString *perMillSymbol;
// @property (copy) NSString *minusSign;
// @property (copy) NSString *plusSign;
// @property (copy) NSString *exponentSymbol;
// @property NSUInteger groupingSize;
// @property NSUInteger secondaryGroupingSize;
// @property (copy) NSNumber *multiplier;
// @property NSUInteger formatWidth;
// @property (copy) NSString *paddingCharacter;
typedef NSUInteger NSNumberFormatterPadPosition; enum {
NSNumberFormatterPadBeforePrefix = kCFNumberFormatterPadBeforePrefix,
NSNumberFormatterPadAfterPrefix = kCFNumberFormatterPadAfterPrefix,
NSNumberFormatterPadBeforeSuffix = kCFNumberFormatterPadBeforeSuffix,
NSNumberFormatterPadAfterSuffix = kCFNumberFormatterPadAfterSuffix
};
typedef NSUInteger NSNumberFormatterRoundingMode; enum {
NSNumberFormatterRoundCeiling = kCFNumberFormatterRoundCeiling,
NSNumberFormatterRoundFloor = kCFNumberFormatterRoundFloor,
NSNumberFormatterRoundDown = kCFNumberFormatterRoundDown,
NSNumberFormatterRoundUp = kCFNumberFormatterRoundUp,
NSNumberFormatterRoundHalfEven = kCFNumberFormatterRoundHalfEven,
NSNumberFormatterRoundHalfDown = kCFNumberFormatterRoundHalfDown,
NSNumberFormatterRoundHalfUp = kCFNumberFormatterRoundHalfUp
};
// @property NSNumberFormatterPadPosition paddingPosition;
// @property NSNumberFormatterRoundingMode roundingMode;
// @property (copy) NSNumber *roundingIncrement;
// @property NSUInteger minimumIntegerDigits;
// @property NSUInteger maximumIntegerDigits;
// @property NSUInteger minimumFractionDigits;
// @property NSUInteger maximumFractionDigits;
// @property (copy) NSNumber *minimum;
// @property (copy) NSNumber *maximum;
// @property (copy) NSString *currencyGroupingSeparator __attribute__((availability(macosx,introduced=10.5)));
// @property (getter=isLenient) BOOL lenient __attribute__((availability(macosx,introduced=10.5)));
// @property BOOL usesSignificantDigits __attribute__((availability(macosx,introduced=10.5)));
// @property NSUInteger minimumSignificantDigits __attribute__((availability(macosx,introduced=10.5)));
// @property NSUInteger maximumSignificantDigits __attribute__((availability(macosx,introduced=10.5)));
// @property (getter=isPartialStringValidationEnabled) BOOL partialStringValidationEnabled __attribute__((availability(macosx,introduced=10.5)));
/* @end */
// @class NSDecimalNumberHandler;
#ifndef _REWRITER_typedef_NSDecimalNumberHandler
#define _REWRITER_typedef_NSDecimalNumberHandler
typedef struct objc_object NSDecimalNumberHandler;
typedef struct {} _objc_exc_NSDecimalNumberHandler;
#endif
// @interface NSNumberFormatter (NSNumberFormatterCompatibility)
// @property BOOL hasThousandSeparators;
// @property (copy) NSString *thousandSeparator;
// @property BOOL localizesFormat;
// @property (copy) NSString *format;
// @property (copy) NSAttributedString *attributedStringForZero;
// @property (copy) NSAttributedString *attributedStringForNil;
// @property (copy) NSAttributedString *attributedStringForNotANumber;
// @property (copy) NSDecimalNumberHandler *roundingBehavior;
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSSet
#define _REWRITER_typedef_NSSet
typedef struct objc_object NSSet;
typedef struct {} _objc_exc_NSSet;
#endif
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.5)))
#ifndef _REWRITER_typedef_NSOperation
#define _REWRITER_typedef_NSOperation
typedef struct objc_object NSOperation;
typedef struct {} _objc_exc_NSOperation;
#endif
struct NSOperation_IMPL {
struct NSObject_IMPL NSObject_IVARS;
id _private;
int32_t _private1;
int32_t _private1b;
};
// - (void)start;
// - (void)main;
// @property (readonly, getter=isCancelled) BOOL cancelled;
// - (void)cancel;
// @property (readonly, getter=isExecuting) BOOL executing;
// @property (readonly, getter=isFinished) BOOL finished;
// @property (readonly, getter=isConcurrent) BOOL concurrent;
// @property (readonly, getter=isAsynchronous) BOOL asynchronous __attribute__((availability(macosx,introduced=10.8)));
// @property (readonly, getter=isReady) BOOL ready;
// - (void)addDependency:(NSOperation *)op;
// - (void)removeDependency:(NSOperation *)op;
// @property (readonly, copy) NSArray *dependencies;
typedef NSInteger NSOperationQueuePriority; enum {
NSOperationQueuePriorityVeryLow = -8L,
NSOperationQueuePriorityLow = -4L,
NSOperationQueuePriorityNormal = 0,
NSOperationQueuePriorityHigh = 4,
NSOperationQueuePriorityVeryHigh = 8
};
// @property NSOperationQueuePriority queuePriority;
// @property (copy) void (^completionBlock)(void) __attribute__((availability(macosx,introduced=10.6)));
// - (void)waitUntilFinished __attribute__((availability(macosx,introduced=10.6)));
// @property double threadPriority __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.10,message="" )));
// @property NSQualityOfService qualityOfService __attribute__((availability(macosx,introduced=10.10)));
// @property (copy) NSString *name __attribute__((availability(macosx,introduced=10.10)));
/* @end */
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.6)))
#ifndef _REWRITER_typedef_NSBlockOperation
#define _REWRITER_typedef_NSBlockOperation
typedef struct objc_object NSBlockOperation;
typedef struct {} _objc_exc_NSBlockOperation;
#endif
struct NSBlockOperation_IMPL {
struct NSOperation_IMPL NSOperation_IVARS;
id _private2;
void *_reserved2;
};
// + (instancetype)blockOperationWithBlock:(void (^)(void))block;
// - (void)addExecutionBlock:(void (^)(void))block;
// @property (readonly, copy) NSArray *executionBlocks;
/* @end */
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.5)))
#ifndef _REWRITER_typedef_NSInvocationOperation
#define _REWRITER_typedef_NSInvocationOperation
typedef struct objc_object NSInvocationOperation;
typedef struct {} _objc_exc_NSInvocationOperation;
#endif
struct NSInvocationOperation_IMPL {
struct NSOperation_IMPL NSOperation_IVARS;
id _inv;
id _exception;
void *_reserved2;
};
// - (instancetype)initWithTarget:(id)target selector:(SEL)sel object:(id)arg;
// - (instancetype)initWithInvocation:(NSInvocation *)inv __attribute__((objc_designated_initializer));
// @property (readonly, retain) NSInvocation *invocation;
// @property (readonly, retain) id result;
/* @end */
extern "C" NSString * const NSInvocationOperationVoidResultException __attribute__((availability(macosx,introduced=10.5)));
extern "C" NSString * const NSInvocationOperationCancelledException __attribute__((availability(macosx,introduced=10.5)));
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.5)))
#ifndef _REWRITER_typedef_NSOperationQueue
#define _REWRITER_typedef_NSOperationQueue
typedef struct objc_object NSOperationQueue;
typedef struct {} _objc_exc_NSOperationQueue;
#endif
struct NSOperationQueue_IMPL {
struct NSObject_IMPL NSObject_IVARS;
id _private;
void *_reserved;
};
// - (void)addOperation:(NSOperation *)op;
// - (void)addOperations:(NSArray *)ops waitUntilFinished:(BOOL)wait __attribute__((availability(macosx,introduced=10.6)));
// - (void)addOperationWithBlock:(void (^)(void))block __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSArray *operations;
// @property (readonly) NSUInteger operationCount __attribute__((availability(macosx,introduced=10.6)));
// @property NSInteger maxConcurrentOperationCount;
enum {
NSOperationQueueDefaultMaxConcurrentOperationCount = -1
};
// @property (getter=isSuspended) BOOL suspended;
// @property (copy) NSString *name __attribute__((availability(macosx,introduced=10.6)));
// @property NSQualityOfService qualityOfService __attribute__((availability(macosx,introduced=10.10)));
// @property (assign ) dispatch_queue_t underlyingQueue __attribute__((availability(macosx,introduced=10.10)));
// - (void)cancelAllOperations;
// - (void)waitUntilAllOperationsAreFinished;
// + (NSOperationQueue *)currentQueue __attribute__((availability(macosx,introduced=10.6)));
// + (NSOperationQueue *)mainQueue __attribute__((availability(macosx,introduced=10.6)));
/* @end */
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.6)))
#ifndef _REWRITER_typedef_NSOrthography
#define _REWRITER_typedef_NSOrthography
typedef struct objc_object NSOrthography;
typedef struct {} _objc_exc_NSOrthography;
#endif
struct NSOrthography_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly, copy) NSString *dominantScript;
// @property (readonly, copy) NSDictionary *languageMap;
// - (instancetype)initWithDominantScript:(NSString *)script languageMap:(NSDictionary *)map __attribute__((availability(macosx,introduced=10.6))) __attribute__((objc_designated_initializer));
// - (instancetype)initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSOrthography (NSOrthographyExtended)
// - (NSArray *)languagesForScript:(NSString *)script __attribute__((availability(macosx,introduced=10.6)));
// - (NSString *)dominantLanguageForScript:(NSString *)script __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSString *dominantLanguage __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSArray *allScripts __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSArray *allLanguages __attribute__((availability(macosx,introduced=10.6)));
/* @end */
// @interface NSOrthography (NSOrthographyCreation)
// + (instancetype)orthographyWithDominantScript:(NSString *)script languageMap:(NSDictionary *)map __attribute__((availability(macosx,introduced=10.6)));
/* @end */
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.5)))
#ifndef _REWRITER_typedef_NSPointerArray
#define _REWRITER_typedef_NSPointerArray
typedef struct objc_object NSPointerArray;
typedef struct {} _objc_exc_NSPointerArray;
#endif
struct NSPointerArray_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (instancetype)initWithOptions:(NSPointerFunctionsOptions)options __attribute__((objc_designated_initializer));
// - (instancetype)initWithPointerFunctions:(NSPointerFunctions *)functions __attribute__((objc_designated_initializer));
// + (NSPointerArray *)pointerArrayWithOptions:(NSPointerFunctionsOptions)options;
// + (NSPointerArray *)pointerArrayWithPointerFunctions:(NSPointerFunctions *)functions;
// @property (readonly, copy) NSPointerFunctions *pointerFunctions;
// - (void *)pointerAtIndex:(NSUInteger)index;
// - (void)addPointer:(void *)pointer;
// - (void)removePointerAtIndex:(NSUInteger)index;
// - (void)insertPointer:(void *)item atIndex:(NSUInteger)index;
// - (void)replacePointerAtIndex:(NSUInteger)index withPointer:(void *)item;
// - (void)compact;
// @property NSUInteger count;
/* @end */
// @interface NSPointerArray (NSPointerArrayConveniences)
// + pointerArrayWithStrongObjects __attribute__((availability(macosx,introduced=10.5 ,deprecated=10.8,message="" )));
// + pointerArrayWithWeakObjects __attribute__((availability(macosx,introduced=10.5 ,deprecated=10.8,message="" )));
// + (NSPointerArray *)strongObjectsPointerArray __attribute__((availability(macosx,introduced=10.8)));
// + (NSPointerArray *)weakObjectsPointerArray __attribute__((availability(macosx,introduced=10.8)));
// @property (readonly, copy) NSArray *allObjects;
/* @end */
typedef int NSSocketNativeHandle;
// @class NSRunLoop;
#ifndef _REWRITER_typedef_NSRunLoop
#define _REWRITER_typedef_NSRunLoop
typedef struct objc_object NSRunLoop;
typedef struct {} _objc_exc_NSRunLoop;
#endif
#ifndef _REWRITER_typedef_NSMutableArray
#define _REWRITER_typedef_NSMutableArray
typedef struct objc_object NSMutableArray;
typedef struct {} _objc_exc_NSMutableArray;
#endif
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
// @class NSConnection;
#ifndef _REWRITER_typedef_NSConnection
#define _REWRITER_typedef_NSConnection
typedef struct objc_object NSConnection;
typedef struct {} _objc_exc_NSConnection;
#endif
#ifndef _REWRITER_typedef_NSPortMessage
#define _REWRITER_typedef_NSPortMessage
typedef struct objc_object NSPortMessage;
typedef struct {} _objc_exc_NSPortMessage;
#endif
// @class NSData;
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
// @protocol NSPortDelegate, NSMachPortDelegate;
extern "C" NSString * const NSPortDidBecomeInvalidNotification;
#ifndef _REWRITER_typedef_NSPort
#define _REWRITER_typedef_NSPort
typedef struct objc_object NSPort;
typedef struct {} _objc_exc_NSPort;
#endif
struct NSPort_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// + (NSPort *)port;
// - (void)invalidate;
// @property (readonly, getter=isValid) BOOL valid;
// - (void)setDelegate:(id <NSPortDelegate>)anObject;
// - (id <NSPortDelegate>)delegate;
// - (void)scheduleInRunLoop:(NSRunLoop *)runLoop forMode:(NSString *)mode;
// - (void)removeFromRunLoop:(NSRunLoop *)runLoop forMode:(NSString *)mode;
// @property (readonly) NSUInteger reservedSpaceLength;
// - (BOOL)sendBeforeDate:(NSDate *)limitDate components:(NSMutableArray *)components from:(NSPort *) receivePort reserved:(NSUInteger)headerSpaceReserved;
// - (BOOL)sendBeforeDate:(NSDate *)limitDate msgid:(NSUInteger)msgID components:(NSMutableArray *)components from:(NSPort *)receivePort reserved:(NSUInteger)headerSpaceReserved;
// - (void)addConnection:(NSConnection *)conn toRunLoop:(NSRunLoop *)runLoop forMode:(NSString *)mode;
// - (void)removeConnection:(NSConnection *)conn fromRunLoop:(NSRunLoop *)runLoop forMode:(NSString *)mode;
/* @end */
// @protocol NSPortDelegate <NSObject>
/* @optional */
// - (void)handlePortMessage:(NSPortMessage *)message;
/* @end */
__attribute__((objc_arc_weak_reference_unavailable))
#ifndef _REWRITER_typedef_NSMachPort
#define _REWRITER_typedef_NSMachPort
typedef struct objc_object NSMachPort;
typedef struct {} _objc_exc_NSMachPort;
#endif
struct NSMachPort_IMPL {
struct NSPort_IMPL NSPort_IVARS;
id _delegate;
NSUInteger _flags;
uint32_t _machPort;
NSUInteger _reserved;
};
// + (NSPort *)portWithMachPort:(uint32_t)machPort;
// - (instancetype)initWithMachPort:(uint32_t)machPort;
// - (void)setDelegate:(id <NSMachPortDelegate>)anObject;
// - (id <NSMachPortDelegate>)delegate;
enum {
NSMachPortDeallocateNone = 0,
NSMachPortDeallocateSendRight = (1UL << 0),
NSMachPortDeallocateReceiveRight = (1UL << 1)
} __attribute__((availability(macosx,introduced=10.5)));
// + (NSPort *)portWithMachPort:(uint32_t)machPort options:(NSUInteger)f __attribute__((availability(macosx,introduced=10.5)));
// - (instancetype)initWithMachPort:(uint32_t)machPort options:(NSUInteger)f __attribute__((availability(macosx,introduced=10.5))) __attribute__((objc_designated_initializer));
// @property (readonly) uint32_t machPort;
// - (void)scheduleInRunLoop:(NSRunLoop *)runLoop forMode:(NSString *)mode;
// - (void)removeFromRunLoop:(NSRunLoop *)runLoop forMode:(NSString *)mode;
/* @end */
// @protocol NSMachPortDelegate <NSPortDelegate>
/* @optional */
// - (void)handleMachMessage:(void *)msg;
/* @end */
__attribute__((objc_arc_weak_reference_unavailable))
#ifndef _REWRITER_typedef_NSMessagePort
#define _REWRITER_typedef_NSMessagePort
typedef struct objc_object NSMessagePort;
typedef struct {} _objc_exc_NSMessagePort;
#endif
struct NSMessagePort_IMPL {
struct NSPort_IMPL NSPort_IVARS;
void *_port;
id _delegate;
};
/* @end */
#ifndef _REWRITER_typedef_NSSocketPort
#define _REWRITER_typedef_NSSocketPort
typedef struct objc_object NSSocketPort;
typedef struct {} _objc_exc_NSSocketPort;
#endif
struct NSSocketPort_IMPL {
struct NSPort_IMPL NSPort_IVARS;
void *_receiver;
id _connectors;
void *_loops;
void *_data;
id _signature;
id _delegate;
id _lock;
NSUInteger _maxSize;
NSUInteger _useCount;
NSUInteger _reserved;
};
// - (instancetype)init;
// - (instancetype)initWithTCPPort:(unsigned short)port;
// - (instancetype)initWithProtocolFamily:(int)family socketType:(int)type protocol:(int)protocol address:(NSData *)address __attribute__((objc_designated_initializer));
// - (instancetype)initWithProtocolFamily:(int)family socketType:(int)type protocol:(int)protocol socket:(NSSocketNativeHandle)sock __attribute__((objc_designated_initializer));
// - (instancetype)initRemoteWithTCPPort:(unsigned short)port host:(NSString *)hostName;
// - (instancetype)initRemoteWithProtocolFamily:(int)family socketType:(int)type protocol:(int)protocol address:(NSData *)address __attribute__((objc_designated_initializer));
// @property (readonly) int protocolFamily;
// @property (readonly) int socketType;
// @property (readonly) int protocol;
// @property (readonly, copy) NSData *address;
// @property (readonly) NSSocketNativeHandle socket;
/* @end */
enum {
NSWindowsNTOperatingSystem = 1,
NSWindows95OperatingSystem,
NSSolarisOperatingSystem,
NSHPUXOperatingSystem,
NSMACHOperatingSystem,
NSSunOSOperatingSystem,
NSOSF1OperatingSystem
} __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.10,message="" )));
typedef struct {
NSInteger majorVersion;
NSInteger minorVersion;
NSInteger patchVersion;
} NSOperatingSystemVersion;
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSProcessInfo
#define _REWRITER_typedef_NSProcessInfo
typedef struct objc_object NSProcessInfo;
typedef struct {} _objc_exc_NSProcessInfo;
#endif
struct NSProcessInfo_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSDictionary *environment;
NSArray *arguments;
NSString *hostName;
NSString *name;
NSInteger automaticTerminationOptOutCounter;
};
// + (NSProcessInfo *)processInfo;
// @property (readonly, copy) NSDictionary *environment;
// @property (readonly, copy) NSArray *arguments;
// @property (readonly, copy) NSString *hostName;
// @property (copy) NSString *processName;
// @property (readonly) int processIdentifier;
// @property (readonly, copy) NSString *globallyUniqueString;
// - (NSUInteger)operatingSystem __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.10,message="" "-operatingSystem always returns NSMACHOperatingSystem, use -operatingSystemVersion or -isOperatingSystemAtLeastVersion: instead")));
// - (NSString *)operatingSystemName __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.10,message="" "-operatingSystemName always returns NSMACHOperatingSystem, use -operatingSystemVersionString instead")));
// @property (readonly, copy) NSString *operatingSystemVersionString;
// @property (readonly) NSOperatingSystemVersion operatingSystemVersion __attribute__((availability(macosx,introduced=10.10)));
// @property (readonly) NSUInteger processorCount __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly) NSUInteger activeProcessorCount __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly) unsigned long long physicalMemory __attribute__((availability(macosx,introduced=10.5)));
// - (BOOL) isOperatingSystemAtLeastVersion:(NSOperatingSystemVersion)version __attribute__((availability(macosx,introduced=10.10)));
// @property (readonly) NSTimeInterval systemUptime __attribute__((availability(macosx,introduced=10.6)));
// - (void)disableSuddenTermination __attribute__((availability(macosx,introduced=10.6)));
// - (void)enableSuddenTermination __attribute__((availability(macosx,introduced=10.6)));
// - (void)disableAutomaticTermination:(NSString *)reason __attribute__((availability(macosx,introduced=10.7)));
// - (void)enableAutomaticTermination:(NSString *)reason __attribute__((availability(macosx,introduced=10.7)));
// @property BOOL automaticTerminationSupportEnabled __attribute__((availability(macosx,introduced=10.7)));
/* @end */
typedef uint64_t NSActivityOptions; enum {
NSActivityIdleDisplaySleepDisabled = (1ULL << 40),
NSActivityIdleSystemSleepDisabled = (1ULL << 20),
NSActivitySuddenTerminationDisabled = (1ULL << 14),
NSActivityAutomaticTerminationDisabled = (1ULL << 15),
NSActivityUserInitiated = (0x00FFFFFFULL | NSActivityIdleSystemSleepDisabled),
NSActivityUserInitiatedAllowingIdleSystemSleep = (NSActivityUserInitiated & ~NSActivityIdleSystemSleepDisabled),
NSActivityBackground = 0x000000FFULL,
NSActivityLatencyCritical = 0xFF00000000ULL,
} __attribute__((availability(macosx,introduced=10.9)));
// @interface NSProcessInfo ()
// - (id <NSObject>)beginActivityWithOptions:(NSActivityOptions)options reason:(NSString *)reason __attribute__((availability(macosx,introduced=10.9)));
// - (void)endActivity:(id <NSObject>)activity __attribute__((availability(macosx,introduced=10.9)));
// - (void)performActivityWithOptions:(NSActivityOptions)options reason:(NSString *)reason usingBlock:(void (^)(void))block __attribute__((availability(macosx,introduced=10.9)));
/* @end */
typedef NSInteger NSProcessInfoThermalState; enum {
NSProcessInfoThermalStateNominal,
NSProcessInfoThermalStateFair,
NSProcessInfoThermalStateSerious,
NSProcessInfoThermalStateCritical
} __attribute__((availability(macosx,introduced=10.10.3)));
// @interface NSProcessInfo ()
// // @property (readonly) NSProcessInfoThermalState thermalState __attribute__((availability(macosx,introduced=10.10.3)));
/* @end */
extern "C" NSString * const NSProcessInfoThermalStateDidChangeNotification __attribute__((availability(macosx,introduced=10.10.3)));
// @class NSMethodSignature;
#ifndef _REWRITER_typedef_NSMethodSignature
#define _REWRITER_typedef_NSMethodSignature
typedef struct objc_object NSMethodSignature;
typedef struct {} _objc_exc_NSMethodSignature;
#endif
#ifndef _REWRITER_typedef_NSInvocation
#define _REWRITER_typedef_NSInvocation
typedef struct objc_object NSInvocation;
typedef struct {} _objc_exc_NSInvocation;
#endif
__attribute__((objc_root_class))
#ifndef _REWRITER_typedef_NSProxy
#define _REWRITER_typedef_NSProxy
typedef struct objc_object NSProxy;
typedef struct {} _objc_exc_NSProxy;
#endif
struct NSProxy_IMPL {
Class isa;
};
// + (id)alloc;
// + (id)allocWithZone:(NSZone *)zone ;
// + (Class)class;
// - (void)forwardInvocation:(NSInvocation *)invocation;
// - (NSMethodSignature *)methodSignatureForSelector:(SEL)sel;
// - (void)dealloc;
// - (void)finalize;
// @property (readonly, copy) NSString *description;
// @property (readonly, copy) NSString *debugDescription;
// + (BOOL)respondsToSelector:(SEL)aSelector;
// - (BOOL)allowsWeakReference __attribute__((unavailable));
// - (BOOL)retainWeakReference __attribute__((unavailable));
/* @end */
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
#ifndef _REWRITER_typedef_NSTimeZone
#define _REWRITER_typedef_NSTimeZone
typedef struct objc_object NSTimeZone;
typedef struct {} _objc_exc_NSTimeZone;
#endif
#ifndef _REWRITER_typedef_NSOrthography
#define _REWRITER_typedef_NSOrthography
typedef struct objc_object NSOrthography;
typedef struct {} _objc_exc_NSOrthography;
#endif
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
#ifndef _REWRITER_typedef_NSRegularExpression
#define _REWRITER_typedef_NSRegularExpression
typedef struct objc_object NSRegularExpression;
typedef struct {} _objc_exc_NSRegularExpression;
#endif
typedef uint64_t NSTextCheckingType; enum {
NSTextCheckingTypeOrthography = 1ULL << 0,
NSTextCheckingTypeSpelling = 1ULL << 1,
NSTextCheckingTypeGrammar = 1ULL << 2,
NSTextCheckingTypeDate = 1ULL << 3,
NSTextCheckingTypeAddress = 1ULL << 4,
NSTextCheckingTypeLink = 1ULL << 5,
NSTextCheckingTypeQuote = 1ULL << 6,
NSTextCheckingTypeDash = 1ULL << 7,
NSTextCheckingTypeReplacement = 1ULL << 8,
NSTextCheckingTypeCorrection = 1ULL << 9,
NSTextCheckingTypeRegularExpression __attribute__((availability(macosx,introduced=10.7))) = 1ULL << 10,
NSTextCheckingTypePhoneNumber __attribute__((availability(macosx,introduced=10.7))) = 1ULL << 11,
NSTextCheckingTypeTransitInformation __attribute__((availability(macosx,introduced=10.7))) = 1ULL << 12
};
enum {
NSTextCheckingAllSystemTypes = 0xffffffffULL,
NSTextCheckingAllCustomTypes = 0xffffffffULL << 32,
NSTextCheckingAllTypes = (NSTextCheckingAllSystemTypes | NSTextCheckingAllCustomTypes)
};
typedef uint64_t NSTextCheckingTypes;
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.6)))
#ifndef _REWRITER_typedef_NSTextCheckingResult
#define _REWRITER_typedef_NSTextCheckingResult
typedef struct objc_object NSTextCheckingResult;
typedef struct {} _objc_exc_NSTextCheckingResult;
#endif
struct NSTextCheckingResult_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly) NSTextCheckingType resultType;
// @property (readonly) NSRange range;
/* @end */
// @interface NSTextCheckingResult (NSTextCheckingResultOptional)
// @property (readonly, copy) NSOrthography *orthography;
// @property (readonly, copy) NSArray *grammarDetails;
// @property (readonly, copy) NSDate *date;
// @property (readonly, copy) NSTimeZone *timeZone;
// @property (readonly) NSTimeInterval duration;
// @property (readonly, copy) NSDictionary *components __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSURL *URL;
// @property (readonly, copy) NSString *replacementString;
// @property (readonly, copy) NSArray *alternativeStrings __attribute__((availability(macosx,introduced=10.9)));
// @property (readonly, copy) NSRegularExpression *regularExpression __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSString *phoneNumber __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSDictionary *addressComponents;
// @property (readonly) NSUInteger numberOfRanges __attribute__((availability(macosx,introduced=10.7)));
// - (NSRange)rangeAtIndex:(NSUInteger)idx __attribute__((availability(macosx,introduced=10.7)));
// - (NSTextCheckingResult *)resultByAdjustingRangesWithOffset:(NSInteger)offset __attribute__((availability(macosx,introduced=10.7)));
/* @end */
extern "C" NSString * const NSTextCheckingNameKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSTextCheckingJobTitleKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSTextCheckingOrganizationKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSTextCheckingStreetKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSTextCheckingCityKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSTextCheckingStateKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSTextCheckingZIPKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSTextCheckingCountryKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSTextCheckingPhoneKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSTextCheckingAirlineKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSTextCheckingFlightKey __attribute__((availability(macosx,introduced=10.7)));
// @interface NSTextCheckingResult (NSTextCheckingResultCreation)
// + (NSTextCheckingResult *)orthographyCheckingResultWithRange:(NSRange)range orthography:(NSOrthography *)orthography;
// + (NSTextCheckingResult *)spellCheckingResultWithRange:(NSRange)range;
// + (NSTextCheckingResult *)grammarCheckingResultWithRange:(NSRange)range details:(NSArray *)details;
// + (NSTextCheckingResult *)dateCheckingResultWithRange:(NSRange)range date:(NSDate *)date;
// + (NSTextCheckingResult *)dateCheckingResultWithRange:(NSRange)range date:(NSDate *)date timeZone:(NSTimeZone *)timeZone duration:(NSTimeInterval)duration;
// + (NSTextCheckingResult *)addressCheckingResultWithRange:(NSRange)range components:(NSDictionary *)components;
// + (NSTextCheckingResult *)linkCheckingResultWithRange:(NSRange)range URL:(NSURL *)url;
// + (NSTextCheckingResult *)quoteCheckingResultWithRange:(NSRange)range replacementString:(NSString *)replacementString;
// + (NSTextCheckingResult *)dashCheckingResultWithRange:(NSRange)range replacementString:(NSString *)replacementString;
// + (NSTextCheckingResult *)replacementCheckingResultWithRange:(NSRange)range replacementString:(NSString *)replacementString;
// + (NSTextCheckingResult *)correctionCheckingResultWithRange:(NSRange)range replacementString:(NSString *)replacementString;
// + (NSTextCheckingResult *)correctionCheckingResultWithRange:(NSRange)range replacementString:(NSString *)replacementString alternativeStrings:(NSArray *)alternativeStrings __attribute__((availability(macosx,introduced=10.9)));
// + (NSTextCheckingResult *)regularExpressionCheckingResultWithRanges:(NSRangePointer)ranges count:(NSUInteger)count regularExpression:(NSRegularExpression *)regularExpression __attribute__((availability(macosx,introduced=10.7)));
// + (NSTextCheckingResult *)phoneNumberCheckingResultWithRange:(NSRange)range phoneNumber:(NSString *)phoneNumber __attribute__((availability(macosx,introduced=10.7)));
// + (NSTextCheckingResult *)transitInformationCheckingResultWithRange:(NSRange)range components:(NSDictionary *)components __attribute__((availability(macosx,introduced=10.7)));
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
typedef NSUInteger NSRegularExpressionOptions; enum {
NSRegularExpressionCaseInsensitive = 1 << 0,
NSRegularExpressionAllowCommentsAndWhitespace = 1 << 1,
NSRegularExpressionIgnoreMetacharacters = 1 << 2,
NSRegularExpressionDotMatchesLineSeparators = 1 << 3,
NSRegularExpressionAnchorsMatchLines = 1 << 4,
NSRegularExpressionUseUnixLineSeparators = 1 << 5,
NSRegularExpressionUseUnicodeWordBoundaries = 1 << 6
};
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.7)))
#ifndef _REWRITER_typedef_NSRegularExpression
#define _REWRITER_typedef_NSRegularExpression
typedef struct objc_object NSRegularExpression;
typedef struct {} _objc_exc_NSRegularExpression;
#endif
struct NSRegularExpression_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSString *_pattern;
NSUInteger _options;
void *_internal;
id _reserved1;
int32_t _checkout;
int32_t _reserved2;
};
// + (NSRegularExpression *)regularExpressionWithPattern:(NSString *)pattern options:(NSRegularExpressionOptions)options error:(NSError **)error;
// - (instancetype)initWithPattern:(NSString *)pattern options:(NSRegularExpressionOptions)options error:(NSError **)error __attribute__((objc_designated_initializer));
// @property (readonly, copy) NSString *pattern;
// @property (readonly) NSRegularExpressionOptions options;
// @property (readonly) NSUInteger numberOfCaptureGroups;
// + (NSString *)escapedPatternForString:(NSString *)string;
/* @end */
typedef NSUInteger NSMatchingOptions; enum {
NSMatchingReportProgress = 1 << 0,
NSMatchingReportCompletion = 1 << 1,
NSMatchingAnchored = 1 << 2,
NSMatchingWithTransparentBounds = 1 << 3,
NSMatchingWithoutAnchoringBounds = 1 << 4
};
typedef NSUInteger NSMatchingFlags; enum {
NSMatchingProgress = 1 << 0,
NSMatchingCompleted = 1 << 1,
NSMatchingHitEnd = 1 << 2,
NSMatchingRequiredEnd = 1 << 3,
NSMatchingInternalError = 1 << 4
};
// @interface NSRegularExpression (NSMatching)
// - (void)enumerateMatchesInString:(NSString *)string options:(NSMatchingOptions)options range:(NSRange)range usingBlock:(void (^)(NSTextCheckingResult *result, NSMatchingFlags flags, BOOL *stop))block;
// - (NSArray *)matchesInString:(NSString *)string options:(NSMatchingOptions)options range:(NSRange)range;
// - (NSUInteger)numberOfMatchesInString:(NSString *)string options:(NSMatchingOptions)options range:(NSRange)range;
// - (NSTextCheckingResult *)firstMatchInString:(NSString *)string options:(NSMatchingOptions)options range:(NSRange)range;
// - (NSRange)rangeOfFirstMatchInString:(NSString *)string options:(NSMatchingOptions)options range:(NSRange)range;
/* @end */
// @interface NSRegularExpression (NSReplacement)
// - (NSString *)stringByReplacingMatchesInString:(NSString *)string options:(NSMatchingOptions)options range:(NSRange)range withTemplate:(NSString *)templ;
// - (NSUInteger)replaceMatchesInString:(NSMutableString *)string options:(NSMatchingOptions)options range:(NSRange)range withTemplate:(NSString *)templ;
// - (NSString *)replacementStringForResult:(NSTextCheckingResult *)result inString:(NSString *)string offset:(NSInteger)offset template:(NSString *)templ;
// + (NSString *)escapedTemplateForString:(NSString *)string;
/* @end */
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.7)))
#ifndef _REWRITER_typedef_NSDataDetector
#define _REWRITER_typedef_NSDataDetector
typedef struct objc_object NSDataDetector;
typedef struct {} _objc_exc_NSDataDetector;
#endif
struct NSDataDetector_IMPL {
struct NSRegularExpression_IMPL NSRegularExpression_IVARS;
NSTextCheckingTypes _types;
};
// + (NSDataDetector *)dataDetectorWithTypes:(NSTextCheckingTypes)checkingTypes error:(NSError **)error;
// - (instancetype)initWithTypes:(NSTextCheckingTypes)checkingTypes error:(NSError **)error __attribute__((objc_designated_initializer));
// @property (readonly) NSTextCheckingTypes checkingTypes;
/* @end */
// @class NSTimer;
#ifndef _REWRITER_typedef_NSTimer
#define _REWRITER_typedef_NSTimer
typedef struct objc_object NSTimer;
typedef struct {} _objc_exc_NSTimer;
#endif
#ifndef _REWRITER_typedef_NSPort
#define _REWRITER_typedef_NSPort
typedef struct objc_object NSPort;
typedef struct {} _objc_exc_NSPort;
#endif
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
extern "C" NSString * const NSDefaultRunLoopMode;
extern "C" NSString * const NSRunLoopCommonModes __attribute__((availability(macosx,introduced=10.5)));
#ifndef _REWRITER_typedef_NSRunLoop
#define _REWRITER_typedef_NSRunLoop
typedef struct objc_object NSRunLoop;
typedef struct {} _objc_exc_NSRunLoop;
#endif
struct NSRunLoop_IMPL {
struct NSObject_IMPL NSObject_IVARS;
id _rl;
id _dperf;
id _perft;
id _info;
id _ports;
void *_reserved[6];
};
// + (NSRunLoop *)currentRunLoop;
// + (NSRunLoop *)mainRunLoop __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly, copy) NSString *currentMode;
// - (CFRunLoopRef)getCFRunLoop __attribute__((cf_returns_not_retained));
// - (void)addTimer:(NSTimer *)timer forMode:(NSString *)mode;
// - (void)addPort:(NSPort *)aPort forMode:(NSString *)mode;
// - (void)removePort:(NSPort *)aPort forMode:(NSString *)mode;
// - (NSDate *)limitDateForMode:(NSString *)mode;
// - (void)acceptInputForMode:(NSString *)mode beforeDate:(NSDate *)limitDate;
/* @end */
// @interface NSRunLoop (NSRunLoopConveniences)
// - (void)run;
// - (void)runUntilDate:(NSDate *)limitDate;
// - (BOOL)runMode:(NSString *)mode beforeDate:(NSDate *)limitDate;
// - (void)configureAsServer __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.5,message="" )));
/* @end */
// @interface NSObject (NSDelayedPerforming)
// - (void)performSelector:(SEL)aSelector withObject:(id)anArgument afterDelay:(NSTimeInterval)delay inModes:(NSArray *)modes;
// - (void)performSelector:(SEL)aSelector withObject:(id)anArgument afterDelay:(NSTimeInterval)delay;
// + (void)cancelPreviousPerformRequestsWithTarget:(id)aTarget selector:(SEL)aSelector object:(id)anArgument;
// + (void)cancelPreviousPerformRequestsWithTarget:(id)aTarget;
/* @end */
// @interface NSRunLoop (NSOrderedPerform)
// - (void)performSelector:(SEL)aSelector target:(id)target argument:(id)arg order:(NSUInteger)order modes:(NSArray *)modes;
// - (void)cancelPerformSelector:(SEL)aSelector target:(id)target argument:(id)arg;
// - (void)cancelPerformSelectorsWithTarget:(id)target;
/* @end */
#ifndef _REWRITER_typedef_NSSortDescriptor
#define _REWRITER_typedef_NSSortDescriptor
typedef struct objc_object NSSortDescriptor;
typedef struct {} _objc_exc_NSSortDescriptor;
#endif
struct NSSortDescriptor_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSUInteger _sortDescriptorFlags;
NSString *_key;
SEL _selector;
id _selectorOrBlock;
};
// + (instancetype)sortDescriptorWithKey:(NSString *)key ascending:(BOOL)ascending __attribute__((availability(macosx,introduced=10.6)));
// + (instancetype)sortDescriptorWithKey:(NSString *)key ascending:(BOOL)ascending selector:(SEL)selector __attribute__((availability(macosx,introduced=10.6)));
// - (instancetype)initWithKey:(NSString *)key ascending:(BOOL)ascending;
// - (instancetype)initWithKey:(NSString *)key ascending:(BOOL)ascending selector:(SEL)selector;
// @property (readonly, copy) NSString *key;
// @property (readonly) BOOL ascending;
// @property (readonly) SEL selector;
// - (void)allowEvaluation __attribute__((availability(macosx,introduced=10.9)));
// + (instancetype)sortDescriptorWithKey:(NSString *)key ascending:(BOOL)ascending comparator:(NSComparator)cmptr __attribute__((availability(macosx,introduced=10.6)));
// - (instancetype)initWithKey:(NSString *)key ascending:(BOOL)ascending comparator:(NSComparator)cmptr __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly) NSComparator comparator __attribute__((availability(macosx,introduced=10.6)));
// - (NSComparisonResult)compareObject:(id)object1 toObject:(id)object2;
// @property (readonly, retain) id reversedSortDescriptor;
/* @end */
// @interface NSSet (NSSortDescriptorSorting)
// - (NSArray *)sortedArrayUsingDescriptors:(NSArray *)sortDescriptors __attribute__((availability(macosx,introduced=10.6)));
/* @end */
// @interface NSArray (NSSortDescriptorSorting)
// - (NSArray *)sortedArrayUsingDescriptors:(NSArray *)sortDescriptors;
/* @end */
// @interface NSMutableArray (NSSortDescriptorSorting)
// - (void)sortUsingDescriptors:(NSArray *)sortDescriptors;
/* @end */
// @interface NSOrderedSet (NSKeyValueSorting)
// - (NSArray *)sortedArrayUsingDescriptors:(NSArray *)sortDescriptors __attribute__((availability(macosx,introduced=10.7)));
/* @end */
// @interface NSMutableOrderedSet (NSKeyValueSorting)
// - (void)sortUsingDescriptors:(NSArray *)sortDescriptors __attribute__((availability(macosx,introduced=10.7)));
/* @end */
// @class NSData;
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
#ifndef _REWRITER_typedef_NSHost
#define _REWRITER_typedef_NSHost
typedef struct objc_object NSHost;
typedef struct {} _objc_exc_NSHost;
#endif
#ifndef _REWRITER_typedef_NSInputStream
#define _REWRITER_typedef_NSInputStream
typedef struct objc_object NSInputStream;
typedef struct {} _objc_exc_NSInputStream;
#endif
#ifndef _REWRITER_typedef_NSOutputStream
#define _REWRITER_typedef_NSOutputStream
typedef struct objc_object NSOutputStream;
typedef struct {} _objc_exc_NSOutputStream;
#endif
#ifndef _REWRITER_typedef_NSRunLoop
#define _REWRITER_typedef_NSRunLoop
typedef struct objc_object NSRunLoop;
typedef struct {} _objc_exc_NSRunLoop;
#endif
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
// @protocol NSStreamDelegate;
typedef NSUInteger NSStreamStatus; enum {
NSStreamStatusNotOpen = 0,
NSStreamStatusOpening = 1,
NSStreamStatusOpen = 2,
NSStreamStatusReading = 3,
NSStreamStatusWriting = 4,
NSStreamStatusAtEnd = 5,
NSStreamStatusClosed = 6,
NSStreamStatusError = 7
};
typedef NSUInteger NSStreamEvent; enum {
NSStreamEventNone = 0,
NSStreamEventOpenCompleted = 1UL << 0,
NSStreamEventHasBytesAvailable = 1UL << 1,
NSStreamEventHasSpaceAvailable = 1UL << 2,
NSStreamEventErrorOccurred = 1UL << 3,
NSStreamEventEndEncountered = 1UL << 4
};
#ifndef _REWRITER_typedef_NSStream
#define _REWRITER_typedef_NSStream
typedef struct objc_object NSStream;
typedef struct {} _objc_exc_NSStream;
#endif
struct NSStream_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (void)open;
// - (void)close;
// @property (assign) id <NSStreamDelegate> delegate;
// - (id)propertyForKey:(NSString *)key;
// - (BOOL)setProperty:(id)property forKey:(NSString *)key;
// - (void)scheduleInRunLoop:(NSRunLoop *)aRunLoop forMode:(NSString *)mode;
// - (void)removeFromRunLoop:(NSRunLoop *)aRunLoop forMode:(NSString *)mode;
// @property (readonly) NSStreamStatus streamStatus;
// @property (readonly, copy) NSError *streamError;
/* @end */
#ifndef _REWRITER_typedef_NSInputStream
#define _REWRITER_typedef_NSInputStream
typedef struct objc_object NSInputStream;
typedef struct {} _objc_exc_NSInputStream;
#endif
struct NSInputStream_IMPL {
struct NSStream_IMPL NSStream_IVARS;
};
// - (NSInteger)read:(uint8_t *)buffer maxLength:(NSUInteger)len;
// - (BOOL)getBuffer:(uint8_t **)buffer length:(NSUInteger *)len;
// @property (readonly) BOOL hasBytesAvailable;
// - (instancetype)initWithData:(NSData *)data __attribute__((objc_designated_initializer));
// - (instancetype)initWithURL:(NSURL *)url __attribute__((availability(macosx,introduced=10.6))) __attribute__((objc_designated_initializer));
/* @end */
#ifndef _REWRITER_typedef_NSOutputStream
#define _REWRITER_typedef_NSOutputStream
typedef struct objc_object NSOutputStream;
typedef struct {} _objc_exc_NSOutputStream;
#endif
struct NSOutputStream_IMPL {
struct NSStream_IMPL NSStream_IVARS;
};
// - (NSInteger)write:(const uint8_t *)buffer maxLength:(NSUInteger)len;
// @property (readonly) BOOL hasSpaceAvailable;
// - (instancetype)initToMemory __attribute__((objc_designated_initializer));
// - (instancetype)initToBuffer:(uint8_t *)buffer capacity:(NSUInteger)capacity __attribute__((objc_designated_initializer));
// - (instancetype)initWithURL:(NSURL *)url append:(BOOL)shouldAppend __attribute__((availability(macosx,introduced=10.6))) __attribute__((objc_designated_initializer));
/* @end */
// @interface NSStream (NSSocketStreamCreationExtensions)
// + (void)getStreamsToHostWithName:(NSString *)hostname port:(NSInteger)port inputStream:(NSInputStream **)inputStream outputStream:(NSOutputStream **)outputStream __attribute__((availability(macosx,introduced=10.10)));
// + (void)getStreamsToHost:(NSHost *)host port:(NSInteger)port inputStream:(NSInputStream **)inputStream outputStream:(NSOutputStream **)outputStream __attribute__((availability(macosx,introduced=10.3 ,deprecated=10.10,message="" "Please use getStreamsToHostWithName:port:inputStream:outputStream: instead")));
/* @end */
// @interface NSStream (NSStreamBoundPairCreationExtensions)
// + (void)getBoundStreamsWithBufferSize:(NSUInteger)bufferSize inputStream:(NSInputStream **)inputStream outputStream:(NSOutputStream **)outputStream __attribute__((availability(macosx,introduced=10.10)));
/* @end */
// @interface NSInputStream (NSInputStreamExtensions)
// - (instancetype)initWithFileAtPath:(NSString *)path;
// + (instancetype)inputStreamWithData:(NSData *)data;
// + (instancetype)inputStreamWithFileAtPath:(NSString *)path;
// + (instancetype)inputStreamWithURL:(NSURL *)url __attribute__((availability(macosx,introduced=10.6)));
/* @end */
// @interface NSOutputStream (NSOutputStreamExtensions)
// - (instancetype)initToFileAtPath:(NSString *)path append:(BOOL)shouldAppend;
// + (instancetype)outputStreamToMemory;
// + (instancetype)outputStreamToBuffer:(uint8_t *)buffer capacity:(NSUInteger)capacity;
// + (instancetype)outputStreamToFileAtPath:(NSString *)path append:(BOOL)shouldAppend;
// + (instancetype)outputStreamWithURL:(NSURL *)url append:(BOOL)shouldAppend __attribute__((availability(macosx,introduced=10.6)));
/* @end */
// @protocol NSStreamDelegate <NSObject>
/* @optional */
// - (void)stream:(NSStream *)aStream handleEvent:(NSStreamEvent)eventCode;
/* @end */
extern "C" NSString * const NSStreamSocketSecurityLevelKey __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSocketSecurityLevelNone __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSocketSecurityLevelSSLv2 __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSocketSecurityLevelSSLv3 __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSocketSecurityLevelTLSv1 __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSocketSecurityLevelNegotiatedSSL __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSOCKSProxyConfigurationKey __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSOCKSProxyHostKey __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSOCKSProxyPortKey __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSOCKSProxyVersionKey __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSOCKSProxyUserKey __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSOCKSProxyPasswordKey __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSOCKSProxyVersion4 __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSOCKSProxyVersion5 __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamDataWrittenToMemoryStreamKey __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamFileCurrentOffsetKey __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSocketSSLErrorDomain __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamSOCKSErrorDomain __attribute__((availability(macosx,introduced=10.3)));
extern "C" NSString * const NSStreamNetworkServiceType __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSStreamNetworkServiceTypeVoIP __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSStreamNetworkServiceTypeVideo __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSStreamNetworkServiceTypeBackground __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSStreamNetworkServiceTypeVoice __attribute__((availability(macosx,introduced=10.7)));
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSMutableDictionary
#define _REWRITER_typedef_NSMutableDictionary
typedef struct objc_object NSMutableDictionary;
typedef struct {} _objc_exc_NSMutableDictionary;
#endif
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
#ifndef _REWRITER_typedef_NSThread
#define _REWRITER_typedef_NSThread
typedef struct objc_object NSThread;
typedef struct {} _objc_exc_NSThread;
#endif
struct NSThread_IMPL {
struct NSObject_IMPL NSObject_IVARS;
id _private;
uint8_t _bytes[44];
};
// + (NSThread *)currentThread;
// + (void)detachNewThreadSelector:(SEL)selector toTarget:(id)target withObject:(id)argument;
// + (BOOL)isMultiThreaded;
// @property (readonly, retain) NSMutableDictionary *threadDictionary;
// + (void)sleepUntilDate:(NSDate *)date;
// + (void)sleepForTimeInterval:(NSTimeInterval)ti;
// + (void)exit;
// + (double)threadPriority;
// + (BOOL)setThreadPriority:(double)p;
// @property double threadPriority __attribute__((availability(macosx,introduced=10.6)));
// @property NSQualityOfService qualityOfService __attribute__((availability(macosx,introduced=10.10)));
// + (NSArray *)callStackReturnAddresses __attribute__((availability(macosx,introduced=10.5)));
// + (NSArray *)callStackSymbols __attribute__((availability(macosx,introduced=10.6)));
// @property (copy) NSString *name __attribute__((availability(macosx,introduced=10.5)));
// @property NSUInteger stackSize __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly) BOOL isMainThread __attribute__((availability(macosx,introduced=10.5)));
// + (BOOL)isMainThread __attribute__((availability(macosx,introduced=10.5)));
// + (NSThread *)mainThread __attribute__((availability(macosx,introduced=10.5)));
// - (instancetype)init __attribute__((availability(macosx,introduced=10.5))) __attribute__((objc_designated_initializer));
// - (instancetype)initWithTarget:(id)target selector:(SEL)selector object:(id)argument __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly, getter=isExecuting) BOOL executing __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly, getter=isFinished) BOOL finished __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly, getter=isCancelled) BOOL cancelled __attribute__((availability(macosx,introduced=10.5)));
// - (void)cancel __attribute__((availability(macosx,introduced=10.5)));
// - (void)start __attribute__((availability(macosx,introduced=10.5)));
// - (void)main __attribute__((availability(macosx,introduced=10.5)));
/* @end */
extern "C" NSString * const NSWillBecomeMultiThreadedNotification;
extern "C" NSString * const NSDidBecomeSingleThreadedNotification;
extern "C" NSString * const NSThreadWillExitNotification;
// @interface NSObject (NSThreadPerformAdditions)
// - (void)performSelectorOnMainThread:(SEL)aSelector withObject:(id)arg waitUntilDone:(BOOL)wait modes:(NSArray *)array;
// - (void)performSelectorOnMainThread:(SEL)aSelector withObject:(id)arg waitUntilDone:(BOOL)wait;
// - (void)performSelector:(SEL)aSelector onThread:(NSThread *)thr withObject:(id)arg waitUntilDone:(BOOL)wait modes:(NSArray *)array __attribute__((availability(macosx,introduced=10.5)));
// - (void)performSelector:(SEL)aSelector onThread:(NSThread *)thr withObject:(id)arg waitUntilDone:(BOOL)wait __attribute__((availability(macosx,introduced=10.5)));
// - (void)performSelectorInBackground:(SEL)aSelector withObject:(id)arg __attribute__((availability(macosx,introduced=10.5)));
/* @end */
// @class NSString;
#ifndef _REWRITER_typedef_NSString
#define _REWRITER_typedef_NSString
typedef struct objc_object NSString;
typedef struct {} _objc_exc_NSString;
#endif
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
#ifndef _REWRITER_typedef_NSLocale
#define _REWRITER_typedef_NSLocale
typedef struct objc_object NSLocale;
typedef struct {} _objc_exc_NSLocale;
#endif
#ifndef _REWRITER_typedef_NSTimeZone
#define _REWRITER_typedef_NSTimeZone
typedef struct objc_object NSTimeZone;
typedef struct {} _objc_exc_NSTimeZone;
#endif
struct NSTimeZone_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// @property (readonly, copy) NSString *name;
// @property (readonly, copy) NSData *data;
// - (NSInteger)secondsFromGMTForDate:(NSDate *)aDate;
// - (NSString *)abbreviationForDate:(NSDate *)aDate;
// - (BOOL)isDaylightSavingTimeForDate:(NSDate *)aDate;
// - (NSTimeInterval)daylightSavingTimeOffsetForDate:(NSDate *)aDate __attribute__((availability(macosx,introduced=10.5)));
// - (NSDate *)nextDaylightSavingTimeTransitionAfterDate:(NSDate *)aDate __attribute__((availability(macosx,introduced=10.5)));
/* @end */
// @interface NSTimeZone (NSExtendedTimeZone)
// + (NSTimeZone *)systemTimeZone;
// + (void)resetSystemTimeZone;
// + (NSTimeZone *)defaultTimeZone;
// + (void)setDefaultTimeZone:(NSTimeZone *)aTimeZone;
// + (NSTimeZone *)localTimeZone;
// + (NSArray *)knownTimeZoneNames;
// + (NSDictionary *)abbreviationDictionary;
// + (void)setAbbreviationDictionary:(NSDictionary *)dict __attribute__((availability(macosx,introduced=10.6)));
// + (NSString *)timeZoneDataVersion __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly) NSInteger secondsFromGMT;
// @property (readonly, copy) NSString *abbreviation;
// @property (readonly, getter=isDaylightSavingTime) BOOL daylightSavingTime;
// @property (readonly) NSTimeInterval daylightSavingTimeOffset __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly, copy) NSDate *nextDaylightSavingTimeTransition __attribute__((availability(macosx,introduced=10.5)));
// @property (readonly, copy) NSString *description;
// - (BOOL)isEqualToTimeZone:(NSTimeZone *)aTimeZone;
typedef NSInteger NSTimeZoneNameStyle; enum {
NSTimeZoneNameStyleStandard,
NSTimeZoneNameStyleShortStandard,
NSTimeZoneNameStyleDaylightSaving,
NSTimeZoneNameStyleShortDaylightSaving,
NSTimeZoneNameStyleGeneric,
NSTimeZoneNameStyleShortGeneric
};
// - (NSString *)localizedName:(NSTimeZoneNameStyle)style locale:(NSLocale *)locale __attribute__((availability(macosx,introduced=10.5)));
/* @end */
// @interface NSTimeZone (NSTimeZoneCreation)
// + (instancetype)timeZoneWithName:(NSString *)tzName;
// + (instancetype)timeZoneWithName:(NSString *)tzName data:(NSData *)aData;
// - (instancetype)initWithName:(NSString *)tzName;
// - (instancetype)initWithName:(NSString *)tzName data:(NSData *)aData;
// + (instancetype)timeZoneForSecondsFromGMT:(NSInteger)seconds;
// + (instancetype)timeZoneWithAbbreviation:(NSString *)abbreviation;
/* @end */
extern "C" NSString * const NSSystemTimeZoneDidChangeNotification __attribute__((availability(macosx,introduced=10.5)));
#ifndef _REWRITER_typedef_NSTimer
#define _REWRITER_typedef_NSTimer
typedef struct objc_object NSTimer;
typedef struct {} _objc_exc_NSTimer;
#endif
struct NSTimer_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// + (NSTimer *)timerWithTimeInterval:(NSTimeInterval)ti invocation:(NSInvocation *)invocation repeats:(BOOL)yesOrNo;
// + (NSTimer *)scheduledTimerWithTimeInterval:(NSTimeInterval)ti invocation:(NSInvocation *)invocation repeats:(BOOL)yesOrNo;
// + (NSTimer *)timerWithTimeInterval:(NSTimeInterval)ti target:(id)aTarget selector:(SEL)aSelector userInfo:(id)userInfo repeats:(BOOL)yesOrNo;
// + (NSTimer *)scheduledTimerWithTimeInterval:(NSTimeInterval)ti target:(id)aTarget selector:(SEL)aSelector userInfo:(id)userInfo repeats:(BOOL)yesOrNo;
// - (instancetype)initWithFireDate:(NSDate *)date interval:(NSTimeInterval)ti target:(id)t selector:(SEL)s userInfo:(id)ui repeats:(BOOL)rep __attribute__((objc_designated_initializer));
// - (void)fire;
// @property (copy) NSDate *fireDate;
// @property (readonly) NSTimeInterval timeInterval;
// @property NSTimeInterval tolerance __attribute__((availability(macosx,introduced=10.9)));
// - (void)invalidate;
// @property (readonly, getter=isValid) BOOL valid;
// @property (readonly, retain) id userInfo;
/* @end */
// @class NSURLHandle;
#ifndef _REWRITER_typedef_NSURLHandle
#define _REWRITER_typedef_NSURLHandle
typedef struct objc_object NSURLHandle;
typedef struct {} _objc_exc_NSURLHandle;
#endif
#ifndef _REWRITER_typedef_NSMutableArray
#define _REWRITER_typedef_NSMutableArray
typedef struct objc_object NSMutableArray;
typedef struct {} _objc_exc_NSMutableArray;
#endif
#ifndef _REWRITER_typedef_NSMutableData
#define _REWRITER_typedef_NSMutableData
typedef struct objc_object NSMutableData;
typedef struct {} _objc_exc_NSMutableData;
#endif
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
extern "C" NSString *NSHTTPPropertyStatusCodeKey __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
extern "C" NSString *NSHTTPPropertyStatusReasonKey __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
extern "C" NSString *NSHTTPPropertyServerHTTPVersionKey __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
extern "C" NSString *NSHTTPPropertyRedirectionHeadersKey __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
extern "C" NSString *NSHTTPPropertyErrorPageDataKey __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
extern "C" NSString *NSHTTPPropertyHTTPProxy __attribute__((availability(macosx,introduced=10.2 ,deprecated=10.4,message="" )));
extern "C" NSString *NSFTPPropertyUserLoginKey __attribute__((availability(macosx,introduced=10.2 ,deprecated=10.4,message="" )));
extern "C" NSString *NSFTPPropertyUserPasswordKey __attribute__((availability(macosx,introduced=10.2 ,deprecated=10.4,message="" )));
extern "C" NSString *NSFTPPropertyActiveTransferModeKey __attribute__((availability(macosx,introduced=10.2 ,deprecated=10.4,message="" )));
extern "C" NSString *NSFTPPropertyFileOffsetKey __attribute__((availability(macosx,introduced=10.2 ,deprecated=10.4,message="" )));
extern "C" NSString *NSFTPPropertyFTPProxy __attribute__((availability(macosx,introduced=10.3 ,deprecated=10.4,message="" )));
typedef NSUInteger NSURLHandleStatus; enum {
NSURLHandleNotLoaded = 0,
NSURLHandleLoadSucceeded,
NSURLHandleLoadInProgress,
NSURLHandleLoadFailed
};
// @protocol NSURLHandleClient
// - (void)URLHandle:(NSURLHandle *)sender resourceDataDidBecomeAvailable:(NSData *)newBytes __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)URLHandleResourceDidBeginLoading:(NSURLHandle *)sender __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)URLHandleResourceDidFinishLoading:(NSURLHandle *)sender __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)URLHandleResourceDidCancelLoading:(NSURLHandle *)sender __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)URLHandle:(NSURLHandle *)sender resourceDidFailLoadingWithReason:(NSString *)reason __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
/* @end */
#ifndef _REWRITER_typedef_NSURLHandle
#define _REWRITER_typedef_NSURLHandle
typedef struct objc_object NSURLHandle;
typedef struct {} _objc_exc_NSURLHandle;
#endif
struct NSURLHandle_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSMutableArray *_clients;
id _data;
NSURLHandleStatus _status;
NSInteger _reserved;
};
// + (void)registerURLHandleClass:(Class)anURLHandleSubclass __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// + (Class)URLHandleClassForURL:(NSURL *)anURL __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (NSURLHandleStatus)status __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (NSString *)failureReason __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)addClient:(id <NSURLHandleClient>)client __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)removeClient:(id <NSURLHandleClient>)client __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)loadInBackground __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)cancelLoadInBackground __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (NSData *)resourceData __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (NSData *)availableResourceData __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (long long) expectedResourceDataSize __attribute__((availability(macosx,introduced=10.3 ,deprecated=10.4,message="" )));
// - (void)flushCachedData __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)backgroundLoadDidFailWithReason:(NSString *)reason __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)didLoadBytes:(NSData *)newBytes loadComplete:(BOOL)yorn __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// + (BOOL)canInitWithURL:(NSURL *)anURL __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// + (NSURLHandle *)cachedHandleForURL:(NSURL *)anURL __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - initWithURL:(NSURL *)anURL cached:(BOOL)willCache __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (id)propertyForKey:(NSString *)propertyKey __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (id)propertyForKeyIfAvailable:(NSString *)propertyKey __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (BOOL)writeProperty:(id)propertyValue forKey:(NSString *)propertyKey __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (BOOL)writeData:(NSData *)data __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (NSData *)loadInForeground __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)beginLoadInBackground __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)endLoadInBackground __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
/* @end */
// @class NSNumber;
#ifndef _REWRITER_typedef_NSNumber
#define _REWRITER_typedef_NSNumber
typedef struct objc_object NSNumber;
typedef struct {} _objc_exc_NSNumber;
#endif
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
struct NSURL_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSString *_urlString;
NSURL *_baseURL;
void *_clients;
void *_reserved;
};
extern "C" NSString *NSURLFileScheme;
// - (instancetype)initWithScheme:(NSString *)scheme host:(NSString *)host path:(NSString *)path;
// - (instancetype)initFileURLWithPath:(NSString *)path isDirectory:(BOOL)isDir __attribute__((availability(macosx,introduced=10.5))) __attribute__((objc_designated_initializer));
// - (instancetype)initFileURLWithPath:(NSString *)path __attribute__((objc_designated_initializer));
// + (NSURL *)fileURLWithPath:(NSString *)path isDirectory:(BOOL) isDir __attribute__((availability(macosx,introduced=10.5)));
// + (NSURL *)fileURLWithPath:(NSString *)path;
// - (instancetype)initFileURLWithFileSystemRepresentation:(const char *)path isDirectory:(BOOL)isDir relativeToURL:(NSURL *)baseURL __attribute__((availability(macosx,introduced=10.9))) __attribute__((objc_designated_initializer));
// + (NSURL *)fileURLWithFileSystemRepresentation:(const char *)path isDirectory:(BOOL) isDir relativeToURL:(NSURL *)baseURL __attribute__((availability(macosx,introduced=10.9)));
// - (instancetype)initWithString:(NSString *)URLString;
// - (instancetype)initWithString:(NSString *)URLString relativeToURL:(NSURL *)baseURL __attribute__((objc_designated_initializer));
// + (instancetype)URLWithString:(NSString *)URLString;
// + (instancetype)URLWithString:(NSString *)URLString relativeToURL:(NSURL *)baseURL;
// @property (readonly, copy) NSString *absoluteString;
// @property (readonly, copy) NSString *relativeString;
// @property (readonly, copy) NSURL *baseURL;
// @property (readonly, copy) NSURL *absoluteURL;
// @property (readonly, copy) NSString *scheme;
// @property (readonly, copy) NSString *resourceSpecifier;
// @property (readonly, copy) NSString *host;
// @property (readonly, copy) NSNumber *port;
// @property (readonly, copy) NSString *user;
// @property (readonly, copy) NSString *password;
// @property (readonly, copy) NSString *path;
// @property (readonly, copy) NSString *fragment;
// @property (readonly, copy) NSString *parameterString;
// @property (readonly, copy) NSString *query;
// @property (readonly, copy) NSString *relativePath;
// - (BOOL)getFileSystemRepresentation:(char *)buffer maxLength:(NSUInteger)maxBufferLength __attribute__((availability(macosx,introduced=10.9)));
// @property (readonly) const char *fileSystemRepresentation __attribute__((objc_returns_inner_pointer)) __attribute__((availability(macosx,introduced=10.9)));
// @property (readonly, getter=isFileURL) BOOL fileURL;
// @property (readonly, copy) NSURL *standardizedURL;
// - (BOOL)checkResourceIsReachableAndReturnError:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)isFileReferenceURL __attribute__((availability(macosx,introduced=10.6)));
// - (NSURL *)fileReferenceURL __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSURL *filePathURL __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)getResourceValue:(out id *)value forKey:(NSString *)key error:(out NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (NSDictionary *)resourceValuesForKeys:(NSArray *)keys error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)setResourceValue:(id)value forKey:(NSString *)key error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (BOOL)setResourceValues:(NSDictionary *)keyedValues error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLKeysOfUnsetValuesKey __attribute__((availability(macosx,introduced=10.7)));
// - (void)removeCachedResourceValueForKey:(NSString *)key __attribute__((availability(macosx,introduced=10.9)));
// - (void)removeAllCachedResourceValues __attribute__((availability(macosx,introduced=10.9)));
// - (void)setTemporaryResourceValue:(id)value forKey:(NSString *)key __attribute__((availability(macosx,introduced=10.9)));
extern "C" NSString * const NSURLNameKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLLocalizedNameKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLIsRegularFileKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLIsDirectoryKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLIsSymbolicLinkKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLIsVolumeKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLIsPackageKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLIsSystemImmutableKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLIsUserImmutableKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLIsHiddenKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLHasHiddenExtensionKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLCreationDateKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLContentAccessDateKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLContentModificationDateKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLAttributeModificationDateKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLLinkCountKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLParentDirectoryURLKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeURLKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLTypeIdentifierKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLLocalizedTypeDescriptionKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLLabelNumberKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLLabelColorKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLLocalizedLabelKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLEffectiveIconKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLCustomIconKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLFileResourceIdentifierKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeIdentifierKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLPreferredIOBlockSizeKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLIsReadableKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLIsWritableKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLIsExecutableKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLFileSecurityKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLIsExcludedFromBackupKey __attribute__((availability(macosx,introduced=10.8)));
extern "C" NSString * const NSURLTagNamesKey __attribute__((availability(macosx,introduced=10.9)));
extern "C" NSString * const NSURLPathKey __attribute__((availability(macosx,introduced=10.8)));
extern "C" NSString * const NSURLIsMountTriggerKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLGenerationIdentifierKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSURLDocumentIdentifierKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSURLAddedToDirectoryDateKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSURLQuarantinePropertiesKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSURLFileResourceTypeKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLFileResourceTypeNamedPipe __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLFileResourceTypeCharacterSpecial __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLFileResourceTypeDirectory __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLFileResourceTypeBlockSpecial __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLFileResourceTypeRegular __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLFileResourceTypeSymbolicLink __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLFileResourceTypeSocket __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLFileResourceTypeUnknown __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLThumbnailDictionaryKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSURLThumbnailKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSThumbnail1024x1024SizeKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSURLFileSizeKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLFileAllocatedSizeKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLTotalFileSizeKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLTotalFileAllocatedSizeKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLIsAliasFileKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeLocalizedFormatDescriptionKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeTotalCapacityKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeAvailableCapacityKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeResourceCountKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeSupportsPersistentIDsKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeSupportsSymbolicLinksKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeSupportsHardLinksKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeSupportsJournalingKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeIsJournalingKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeSupportsSparseFilesKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeSupportsZeroRunsKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeSupportsCaseSensitiveNamesKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeSupportsCasePreservedNamesKey __attribute__((availability(macosx,introduced=10.6)));
extern "C" NSString * const NSURLVolumeSupportsRootDirectoryDatesKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeSupportsVolumeSizesKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeSupportsRenamingKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeSupportsAdvisoryFileLockingKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeSupportsExtendedSecurityKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeIsBrowsableKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeMaximumFileSizeKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeIsEjectableKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeIsRemovableKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeIsInternalKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeIsAutomountedKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeIsLocalKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeIsReadOnlyKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeCreationDateKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeURLForRemountingKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeUUIDStringKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeNameKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLVolumeLocalizedNameKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLIsUbiquitousItemKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLUbiquitousItemHasUnresolvedConflictsKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLUbiquitousItemIsDownloadedKey __attribute__((availability(macosx,introduced=10.7 ,deprecated=10.9,message="" "Use NSURLUbiquitousItemDownloadingStatusKey instead")));
extern "C" NSString * const NSURLUbiquitousItemIsDownloadingKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLUbiquitousItemIsUploadedKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLUbiquitousItemIsUploadingKey __attribute__((availability(macosx,introduced=10.7)));
extern "C" NSString * const NSURLUbiquitousItemPercentDownloadedKey __attribute__((availability(macosx,introduced=10.7 ,deprecated=10.8,message="" )));
extern "C" NSString * const NSURLUbiquitousItemPercentUploadedKey __attribute__((availability(macosx,introduced=10.7 ,deprecated=10.8,message="" )));
extern "C" NSString * const NSURLUbiquitousItemDownloadingStatusKey __attribute__((availability(macosx,introduced=10.9)));
extern "C" NSString * const NSURLUbiquitousItemDownloadingErrorKey __attribute__((availability(macosx,introduced=10.9)));
extern "C" NSString * const NSURLUbiquitousItemUploadingErrorKey __attribute__((availability(macosx,introduced=10.9)));
extern "C" NSString * const NSURLUbiquitousItemDownloadRequestedKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSURLUbiquitousItemContainerDisplayNameKey __attribute__((availability(macosx,introduced=10.10)));
extern "C" NSString * const NSURLUbiquitousItemDownloadingStatusNotDownloaded __attribute__((availability(macosx,introduced=10.9)));
extern "C" NSString * const NSURLUbiquitousItemDownloadingStatusDownloaded __attribute__((availability(macosx,introduced=10.9)));
extern "C" NSString * const NSURLUbiquitousItemDownloadingStatusCurrent __attribute__((availability(macosx,introduced=10.9)));
typedef NSUInteger NSURLBookmarkCreationOptions; enum {
NSURLBookmarkCreationPreferFileIDResolution __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.9,message="" ))) = ( 1UL << 8 ),
NSURLBookmarkCreationMinimalBookmark = ( 1UL << 9 ),
NSURLBookmarkCreationSuitableForBookmarkFile = ( 1UL << 10 ),
NSURLBookmarkCreationWithSecurityScope __attribute__((availability(macosx,introduced=10.7))) = ( 1 << 11 ),
NSURLBookmarkCreationSecurityScopeAllowOnlyReadAccess __attribute__((availability(macosx,introduced=10.7))) = ( 1 << 12 ),
} __attribute__((availability(macosx,introduced=10.6)));
typedef NSUInteger NSURLBookmarkResolutionOptions; enum {
NSURLBookmarkResolutionWithoutUI = ( 1UL << 8 ),
NSURLBookmarkResolutionWithoutMounting = ( 1UL << 9 ),
NSURLBookmarkResolutionWithSecurityScope __attribute__((availability(macosx,introduced=10.7))) = ( 1 << 10 )
} __attribute__((availability(macosx,introduced=10.6)));
typedef NSUInteger NSURLBookmarkFileCreationOptions;
// - (NSData *)bookmarkDataWithOptions:(NSURLBookmarkCreationOptions)options includingResourceValuesForKeys:(NSArray *)keys relativeToURL:(NSURL *)relativeURL error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// - (instancetype)initByResolvingBookmarkData:(NSData *)bookmarkData options:(NSURLBookmarkResolutionOptions)options relativeToURL:(NSURL *)relativeURL bookmarkDataIsStale:(BOOL *)isStale error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// + (instancetype)URLByResolvingBookmarkData:(NSData *)bookmarkData options:(NSURLBookmarkResolutionOptions)options relativeToURL:(NSURL *)relativeURL bookmarkDataIsStale:(BOOL *)isStale error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// + (NSDictionary *)resourceValuesForKeys:(NSArray *)keys fromBookmarkData:(NSData *)bookmarkData __attribute__((availability(macosx,introduced=10.6)));
// + (BOOL)writeBookmarkData:(NSData *)bookmarkData toURL:(NSURL *)bookmarkFileURL options:(NSURLBookmarkFileCreationOptions)options error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// + (NSData *)bookmarkDataWithContentsOfURL:(NSURL *)bookmarkFileURL error:(NSError **)error __attribute__((availability(macosx,introduced=10.6)));
// + (instancetype)URLByResolvingAliasFileAtURL:(NSURL *)url options:(NSURLBookmarkResolutionOptions)options error:(NSError **)error __attribute__((availability(macosx,introduced=10.10)));
// - (BOOL)startAccessingSecurityScopedResource __attribute__((availability(macosx,introduced=10.7)));
// - (void)stopAccessingSecurityScopedResource __attribute__((availability(macosx,introduced=10.7)));
/* @end */
// @interface NSURL (NSPromisedItems)
// - (BOOL)getPromisedItemResourceValue:(id *)value forKey:(NSString *)key error:(NSError **)error __attribute__((availability(macosx,introduced=10.10)));
// - (NSDictionary *)promisedItemResourceValuesForKeys:(NSArray *)keys error:(NSError **)error __attribute__((availability(macosx,introduced=10.10)));
// - (BOOL)checkPromisedItemIsReachableAndReturnError:(NSError **)error __attribute__((availability(macosx,introduced=10.10)));
/* @end */
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.10)))
#ifndef _REWRITER_typedef_NSURLQueryItem
#define _REWRITER_typedef_NSURLQueryItem
typedef struct objc_object NSURLQueryItem;
typedef struct {} _objc_exc_NSURLQueryItem;
#endif
struct NSURLQueryItem_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSString *_name;
NSString *_value;
};
// - (instancetype)initWithName:(NSString *)name value:(NSString *)value __attribute__((objc_designated_initializer));
// + (instancetype)queryItemWithName:(NSString *)name value:(NSString *)value;
// @property (readonly) NSString *name;
// @property (readonly) NSString *value;
/* @end */
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.9)))
#ifndef _REWRITER_typedef_NSURLComponents
#define _REWRITER_typedef_NSURLComponents
typedef struct objc_object NSURLComponents;
typedef struct {} _objc_exc_NSURLComponents;
#endif
struct NSURLComponents_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (instancetype)init;
// - (instancetype)initWithURL:(NSURL *)url resolvingAgainstBaseURL:(BOOL)resolve;
// + (instancetype)componentsWithURL:(NSURL *)url resolvingAgainstBaseURL:(BOOL)resolve;
// - (instancetype)initWithString:(NSString *)URLString;
// + (instancetype)componentsWithString:(NSString *)URLString;
// @property (readonly, copy) NSURL *URL;
// - (NSURL *)URLRelativeToURL:(NSURL *)baseURL;
// @property (readonly, copy) NSString *string __attribute__((availability(macosx,introduced=10.10)));
// @property (copy) NSString *scheme;
// @property (copy) NSString *user;
// @property (copy) NSString *password;
// @property (copy) NSString *host;
// @property (copy) NSNumber *port;
// @property (copy) NSString *path;
// @property (copy) NSString *query;
// @property (copy) NSString *fragment;
// @property (copy) NSString *percentEncodedUser;
// @property (copy) NSString *percentEncodedPassword;
// @property (copy) NSString *percentEncodedHost;
// @property (copy) NSString *percentEncodedPath;
// @property (copy) NSString *percentEncodedQuery;
// @property (copy) NSString *percentEncodedFragment;
// @property (copy) NSArray *queryItems __attribute__((availability(macosx,introduced=10.10)));
/* @end */
// @interface NSCharacterSet (NSURLUtilities)
// + (NSCharacterSet *)URLUserAllowedCharacterSet __attribute__((availability(macosx,introduced=10.9)));
// + (NSCharacterSet *)URLPasswordAllowedCharacterSet __attribute__((availability(macosx,introduced=10.9)));
// + (NSCharacterSet *)URLHostAllowedCharacterSet __attribute__((availability(macosx,introduced=10.9)));
// + (NSCharacterSet *)URLPathAllowedCharacterSet __attribute__((availability(macosx,introduced=10.9)));
// + (NSCharacterSet *)URLQueryAllowedCharacterSet __attribute__((availability(macosx,introduced=10.9)));
// + (NSCharacterSet *)URLFragmentAllowedCharacterSet __attribute__((availability(macosx,introduced=10.9)));
/* @end */
// @interface NSString (NSURLUtilities)
// - (NSString *)stringByAddingPercentEncodingWithAllowedCharacters:(NSCharacterSet *)allowedCharacters __attribute__((availability(macosx,introduced=10.9)));
// @property (readonly, copy) NSString *stringByRemovingPercentEncoding __attribute__((availability(macosx,introduced=10.9)));
// - (NSString *)stringByAddingPercentEscapesUsingEncoding:(NSStringEncoding)enc;
// - (NSString *)stringByReplacingPercentEscapesUsingEncoding:(NSStringEncoding)enc;
/* @end */
// @interface NSURL (NSURLPathUtilities)
// + (NSURL *)fileURLWithPathComponents:(NSArray *)components __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSArray *pathComponents __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSString *lastPathComponent __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSString *pathExtension __attribute__((availability(macosx,introduced=10.6)));
// - (NSURL *)URLByAppendingPathComponent:(NSString *)pathComponent __attribute__((availability(macosx,introduced=10.6)));
// - (NSURL *)URLByAppendingPathComponent:(NSString *)pathComponent isDirectory:(BOOL)isDirectory __attribute__((availability(macosx,introduced=10.7)));
// @property (readonly, copy) NSURL *URLByDeletingLastPathComponent __attribute__((availability(macosx,introduced=10.6)));
// - (NSURL *)URLByAppendingPathExtension:(NSString *)pathExtension __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSURL *URLByDeletingPathExtension __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSURL *URLByStandardizingPath __attribute__((availability(macosx,introduced=10.6)));
// @property (readonly, copy) NSURL *URLByResolvingSymlinksInPath __attribute__((availability(macosx,introduced=10.6)));
/* @end */
__attribute__((visibility("default"))) __attribute__((availability(macosx,introduced=10.7)))
#ifndef _REWRITER_typedef_NSFileSecurity
#define _REWRITER_typedef_NSFileSecurity
typedef struct objc_object NSFileSecurity;
typedef struct {} _objc_exc_NSFileSecurity;
#endif
struct NSFileSecurity_IMPL {
struct NSObject_IMPL NSObject_IVARS;
};
// - (instancetype) initWithCoder:(NSCoder *)aDecoder __attribute__((objc_designated_initializer));
/* @end */
// @interface NSObject (NSURLClient)
// - (void)URL:(NSURL *)sender resourceDataDidBecomeAvailable:(NSData *)newBytes __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)URLResourceDidFinishLoading:(NSURL *)sender __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)URLResourceDidCancelLoading:(NSURL *)sender __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)URL:(NSURL *)sender resourceDidFailLoadingWithReason:(NSString *)reason __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
/* @end */
// @interface NSURL (NSURLLoading)
// - (NSData *)resourceDataUsingCache:(BOOL)shouldUseCache __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (void)loadResourceDataNotifyingClient:(id)client usingCache:(BOOL)shouldUseCache __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (id)propertyForKey:(NSString *)propertyKey __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (BOOL)setResourceData:(NSData *)data __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (BOOL)setProperty:(id)property forKey:(NSString *)propertyKey __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
// - (NSURLHandle *)URLHandleUsingCache:(BOOL)shouldUseCache __attribute__((availability(macosx,introduced=10.0 ,deprecated=10.4,message="" )));
/* @end */
// @class NSURLAuthenticationChallenge;
#ifndef _REWRITER_typedef_NSURLAuthenticationChallenge
#define _REWRITER_typedef_NSURLAuthenticationChallenge
typedef struct objc_object NSURLAuthenticationChallenge;
typedef struct {} _objc_exc_NSURLAuthenticationChallenge;
#endif
// @class NSURLCredential;
#ifndef _REWRITER_typedef_NSURLCredential
#define _REWRITER_typedef_NSURLCredential
typedef struct objc_object NSURLCredential;
typedef struct {} _objc_exc_NSURLCredential;
#endif
// @class NSURLProtectionSpace;
#ifndef _REWRITER_typedef_NSURLProtectionSpace
#define _REWRITER_typedef_NSURLProtectionSpace
typedef struct objc_object NSURLProtectionSpace;
typedef struct {} _objc_exc_NSURLProtectionSpace;
#endif
// @class NSURLResponse;
#ifndef _REWRITER_typedef_NSURLResponse
#define _REWRITER_typedef_NSURLResponse
typedef struct objc_object NSURLResponse;
typedef struct {} _objc_exc_NSURLResponse;
#endif
// @class NSError;
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
// @protocol NSURLAuthenticationChallengeSender <NSObject>
// - (void)useCredential:(NSURLCredential *)credential forAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge;
// - (void)continueWithoutCredentialForAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge;
// - (void)cancelAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge;
/* @optional */
// - (void)performDefaultHandlingForAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge;
// - (void)rejectProtectionSpaceAndContinueWithChallenge:(NSURLAuthenticationChallenge *)challenge;
/* @end */
// @class NSURLAuthenticationChallengeInternal;
#ifndef _REWRITER_typedef_NSURLAuthenticationChallengeInternal
#define _REWRITER_typedef_NSURLAuthenticationChallengeInternal
typedef struct objc_object NSURLAuthenticationChallengeInternal;
typedef struct {} _objc_exc_NSURLAuthenticationChallengeInternal;
#endif
#ifndef _REWRITER_typedef_NSURLAuthenticationChallenge
#define _REWRITER_typedef_NSURLAuthenticationChallenge
typedef struct objc_object NSURLAuthenticationChallenge;
typedef struct {} _objc_exc_NSURLAuthenticationChallenge;
#endif
struct NSURLAuthenticationChallenge_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSURLAuthenticationChallengeInternal *_internal;
};
// - (instancetype)initWithProtectionSpace:(NSURLProtectionSpace *)space proposedCredential:(NSURLCredential *)credential previousFailureCount:(NSInteger)previousFailureCount failureResponse:(NSURLResponse *)response error:(NSError *)error sender:(id<NSURLAuthenticationChallengeSender>)sender;
// - (instancetype)initWithAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge sender:(id<NSURLAuthenticationChallengeSender>)sender;
// @property (readonly, copy) NSURLProtectionSpace *protectionSpace;
// @property (readonly, copy) NSURLCredential *proposedCredential;
// @property (readonly) NSInteger previousFailureCount;
// @property (readonly, copy) NSURLResponse *failureResponse;
// @property (readonly, copy) NSError *error;
// @property (readonly, retain) id<NSURLAuthenticationChallengeSender> sender;
/* @end */
typedef NSUInteger NSURLCacheStoragePolicy; enum
{
NSURLCacheStorageAllowed,
NSURLCacheStorageAllowedInMemoryOnly,
NSURLCacheStorageNotAllowed,
};
// @class NSCachedURLResponseInternal;
#ifndef _REWRITER_typedef_NSCachedURLResponseInternal
#define _REWRITER_typedef_NSCachedURLResponseInternal
typedef struct objc_object NSCachedURLResponseInternal;
typedef struct {} _objc_exc_NSCachedURLResponseInternal;
#endif
// @class NSData;
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
// @class NSDictionary;
#ifndef _REWRITER_typedef_NSDictionary
#define _REWRITER_typedef_NSDictionary
typedef struct objc_object NSDictionary;
typedef struct {} _objc_exc_NSDictionary;
#endif
// @class NSURLRequest;
#ifndef _REWRITER_typedef_NSURLRequest
#define _REWRITER_typedef_NSURLRequest
typedef struct objc_object NSURLRequest;
typedef struct {} _objc_exc_NSURLRequest;
#endif
// @class NSURLResponse;
#ifndef _REWRITER_typedef_NSURLResponse
#define _REWRITER_typedef_NSURLResponse
typedef struct objc_object NSURLResponse;
typedef struct {} _objc_exc_NSURLResponse;
#endif
// @class NSDate;
#ifndef _REWRITER_typedef_NSDate
#define _REWRITER_typedef_NSDate
typedef struct objc_object NSDate;
typedef struct {} _objc_exc_NSDate;
#endif
// @class NSURLSessionDataTask;
#ifndef _REWRITER_typedef_NSURLSessionDataTask
#define _REWRITER_typedef_NSURLSessionDataTask
typedef struct objc_object NSURLSessionDataTask;
typedef struct {} _objc_exc_NSURLSessionDataTask;
#endif
#ifndef _REWRITER_typedef_NSCachedURLResponse
#define _REWRITER_typedef_NSCachedURLResponse
typedef struct objc_object NSCachedURLResponse;
typedef struct {} _objc_exc_NSCachedURLResponse;
#endif
struct NSCachedURLResponse_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSCachedURLResponseInternal *_internal;
};
// - (instancetype)initWithResponse:(NSURLResponse *)response data:(NSData *)data;
// - (instancetype)initWithResponse:(NSURLResponse *)response data:(NSData *)data userInfo:(NSDictionary *)userInfo storagePolicy:(NSURLCacheStoragePolicy)storagePolicy;
// @property (readonly, copy) NSURLResponse *response;
// @property (readonly, copy) NSData *data;
// @property (readonly, copy) NSDictionary *userInfo;
// @property (readonly) NSURLCacheStoragePolicy storagePolicy;
/* @end */
// @class NSURLRequest;
#ifndef _REWRITER_typedef_NSURLRequest
#define _REWRITER_typedef_NSURLRequest
typedef struct objc_object NSURLRequest;
typedef struct {} _objc_exc_NSURLRequest;
#endif
// @class NSURLCacheInternal;
#ifndef _REWRITER_typedef_NSURLCacheInternal
#define _REWRITER_typedef_NSURLCacheInternal
typedef struct objc_object NSURLCacheInternal;
typedef struct {} _objc_exc_NSURLCacheInternal;
#endif
#ifndef _REWRITER_typedef_NSURLCache
#define _REWRITER_typedef_NSURLCache
typedef struct objc_object NSURLCache;
typedef struct {} _objc_exc_NSURLCache;
#endif
struct NSURLCache_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSURLCacheInternal *_internal;
};
// + (NSURLCache *)sharedURLCache;
// + (void)setSharedURLCache:(NSURLCache *)cache;
// - (instancetype)initWithMemoryCapacity:(NSUInteger)memoryCapacity diskCapacity:(NSUInteger)diskCapacity diskPath:(NSString *)path;
// - (NSCachedURLResponse *)cachedResponseForRequest:(NSURLRequest *)request;
// - (void)storeCachedResponse:(NSCachedURLResponse *)cachedResponse forRequest:(NSURLRequest *)request;
// - (void)removeCachedResponseForRequest:(NSURLRequest *)request;
// - (void)removeAllCachedResponses;
// - (void)removeCachedResponsesSinceDate:(NSDate *)date __attribute__((availability(macosx,introduced=10.10)));
// @property NSUInteger memoryCapacity;
// @property NSUInteger diskCapacity;
// @property (readonly) NSUInteger currentMemoryUsage;
// @property (readonly) NSUInteger currentDiskUsage;
/* @end */
// @interface NSURLCache (NSURLSessionTaskAdditions)
// - (void)storeCachedResponse:(NSCachedURLResponse *)cachedResponse forDataTask:(NSURLSessionDataTask *)dataTask __attribute__((availability(macosx,introduced=10.10)));
// - (void)getCachedResponseForDataTask:(NSURLSessionDataTask *)dataTask completionHandler:(void (^) (NSCachedURLResponse *cachedResponse))completionHandler __attribute__((availability(macosx,introduced=10.10)));
// - (void)removeCachedResponseForDataTask:(NSURLSessionDataTask *)dataTask __attribute__((availability(macosx,introduced=10.10)));
/* @end */
// @class NSArray;
#ifndef _REWRITER_typedef_NSArray
#define _REWRITER_typedef_NSArray
typedef struct objc_object NSArray;
typedef struct {} _objc_exc_NSArray;
#endif
// @class NSURL;
#ifndef _REWRITER_typedef_NSURL
#define _REWRITER_typedef_NSURL
typedef struct objc_object NSURL;
typedef struct {} _objc_exc_NSURL;
#endif
// @class NSCachedURLResponse;
#ifndef _REWRITER_typedef_NSCachedURLResponse
#define _REWRITER_typedef_NSCachedURLResponse
typedef struct objc_object NSCachedURLResponse;
typedef struct {} _objc_exc_NSCachedURLResponse;
#endif
// @class NSData;
#ifndef _REWRITER_typedef_NSData
#define _REWRITER_typedef_NSData
typedef struct objc_object NSData;
typedef struct {} _objc_exc_NSData;
#endif
// @class NSError;
#ifndef _REWRITER_typedef_NSError
#define _REWRITER_typedef_NSError
typedef struct objc_object NSError;
typedef struct {} _objc_exc_NSError;
#endif
// @class NSURLAuthenticationChallenge;
#ifndef _REWRITER_typedef_NSURLAuthenticationChallenge
#define _REWRITER_typedef_NSURLAuthenticationChallenge
typedef struct objc_object NSURLAuthenticationChallenge;
typedef struct {} _objc_exc_NSURLAuthenticationChallenge;
#endif
// @class NSURLConnectionInternal;
#ifndef _REWRITER_typedef_NSURLConnectionInternal
#define _REWRITER_typedef_NSURLConnectionInternal
typedef struct objc_object NSURLConnectionInternal;
typedef struct {} _objc_exc_NSURLConnectionInternal;
#endif
// @class NSURLRequest;
#ifndef _REWRITER_typedef_NSURLRequest
#define _REWRITER_typedef_NSURLRequest
typedef struct objc_object NSURLRequest;
typedef struct {} _objc_exc_NSURLRequest;
#endif
// @class NSURLResponse;
#ifndef _REWRITER_typedef_NSURLResponse
#define _REWRITER_typedef_NSURLResponse
typedef struct objc_object NSURLResponse;
typedef struct {} _objc_exc_NSURLResponse;
#endif
// @class NSRunLoop;
#ifndef _REWRITER_typedef_NSRunLoop
#define _REWRITER_typedef_NSRunLoop
typedef struct objc_object NSRunLoop;
typedef struct {} _objc_exc_NSRunLoop;
#endif
// @class NSInputStream;
#ifndef _REWRITER_typedef_NSInputStream
#define _REWRITER_typedef_NSInputStream
typedef struct objc_object NSInputStream;
typedef struct {} _objc_exc_NSInputStream;
#endif
// @class NSURLProtectionSpace;
#ifndef _REWRITER_typedef_NSURLProtectionSpace
#define _REWRITER_typedef_NSURLProtectionSpace
typedef struct objc_object NSURLProtectionSpace;
typedef struct {} _objc_exc_NSURLProtectionSpace;
#endif
// @class NSOperationQueue;
#ifndef _REWRITER_typedef_NSOperationQueue
#define _REWRITER_typedef_NSOperationQueue
typedef struct objc_object NSOperationQueue;
typedef struct {} _objc_exc_NSOperationQueue;
#endif
// @protocol NSURLConnectionDelegate;
#ifndef _REWRITER_typedef_NSURLConnection
#define _REWRITER_typedef_NSURLConnection
typedef struct objc_object NSURLConnection;
typedef struct {} _objc_exc_NSURLConnection;
#endif
struct NSURLConnection_IMPL {
struct NSObject_IMPL NSObject_IVARS;
NSURLConnectionInternal *_internal;
};
// - (instancetype)initWithRequest:(NSURLRequest *)request delegate:(id)delegate startImmediately:(BOOL)startImmediately __attribute__((availability(macosx,introduced=10.5)));
// - (instancetype)initWithRequest:(NSURLRequest *)request delegate:(id)delegate;
// + (NSURLConnection*)connectionWithRequest:(NSURLRequest *)request delegate:(id)delegate;
// @property (readonly, copy) NSURLRequest *originalRequest __attribute__((availability(macosx,introduced=10.8)));
// @property (readonly, copy) NSURLRequest *currentRequest __attribute__((availability(macosx,introduced=10.8)));
// - (void)start __attribute__((availability(macosx,introduced=10.5)));
// - (void)cancel;
// - (void)scheduleInRunLoop:(NSRunLoop *)aRunLoop forMode:(NSString *)mode __attribute__((availability(macosx,introduced=10.5)));
// - (void)unscheduleFromRunLoop:(NSRunLoop *)aRunLoop forMode:(NSString *)mode __attribute__((availability(macosx,introduced=10.5)));
// - (void)setDelegateQueue:(NSOperationQueue*) queue __attribute__((availability(macosx,introduced=10.7)));
// + (BOOL)canHandleRequest:(NSURLRequest *)request;
/* @end */
// @protocol NSURLConnectionDelegate <NSObject>
/* @optional */
// - (void)connection:(NSURLConnection *)connection didFailWithError:(NSError *)error;
// - (BOOL)connectionShouldUseCredentialStorage:(NSURLConnection *)connection;
// - (void)connection:(NSURLConnection *)connection willSendRequestForAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge;
// - (BOOL)connection:(NSURLConnection *)connection canAuthenticateAgainstProtectionSpace:(NSURLProtectionSpace *)protectionSpace __attribute__((availability(macosx,introduced=10.6 ,deprecated=10.10,message="" "Use -connection:willSendRequestForAuthenticationChallenge: instead.")));
// - (void)connection:(NSURLConnection *)connection didReceiveAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge __attribute__((availability(macosx,introduced=10.2 ,deprecated=10.10,message="" "Use -connection:willSendRequestForAuthenticationChallenge: instead.")));
// - (void)connection:(NSURLConnection *)connection didCancelAuthenticationChallenge:(NSURLAuthenticationChallenge *)challenge __attribute__((availability(macosx,introduced=10.2 ,deprecated=10.10,message="" "Use -connection:willSendRequestForAuthenticationChallenge: instead.")));
/* @end */
// @protocol NSURLConnectionDataDelegate <NSURLConnectionDelegate>
/* @optional */
// - (NSURLRequest *)connection:(NSURLConnection *)connection willSendRequest:(NSURLRequest *)request redirectResponse:(NSURLResponse *)response;
// - (void)connection:(NSURLConnection *)connection didReceiveResponse:(NSURLResponse *)response;
// - (void)connection:(NSURLConnection *)connection didReceiveData:(NSData *)data;
// - (NSInputStream *)connection:(NSURLConnection *)connection needNewBodyStream:(NSURLRequest *)request;
#if 0
- (void)connection:(NSURLConnection *)connection didSendBodyData:(NSInteger)bytesWritten
totalBytesWritten:(NSInteger)totalBytesWritten
totalBytesExpectedToWrite:(NSInteger)totalBytesExpectedToWrite;
#endif
// - (NSCachedURLResponse *)connection:(NSURLConnection *)connection willCacheResponse:(NSCachedURLResponse *)cachedResponse;
// - (void)connectionDidFinishLoading:(NSURLConnection *)connection;
/* @end */
// @protocol NSURLConnectionDownloadDelegate <NSURLConnectionDelegate>
/* @optional */
// - (void)connection:(NSURLConnection *)connection didWriteData:(long long)bytesWritten totalBytesWritten:(long long)totalBytesWritten expectedTotalBytes:(long long) expectedTotalBytes;
// - (void)connectionDidResumeDownloading:(NSURLConnection *)connection totalBytesWritten:(long long)totalBytesWritten expectedTotalBytes:(long long) expectedTotalBytes;
/* @required */
// - (void)connectionDidFinishDownloading:(NSURLConnection *)connection destinationURL:(NSURL *) destinationURL;
/* @end */
// @interface NSURLConnection (NSURLConnectionSynchronousLoading)
// + (NSData *)sendSynchronousRequest:(NSURLRequest *)request returningResponse:(NSURLResponse **)response error:(NSError **)error;
/* @end */
// @interface NSURLConnection (NSURLConnectionQueuedLoading)
#if 0
+ (void)sendAsynchronousRequest:(NSURLRequest*) request
queue:(NSOperationQueue*) queue
completionHandler:(void (^)(NSURLResponse* response, NSData* data, NSError* connectionError)) handler __attribute__((availability(macosx,introduced=10.7)));
#endif
/* @end */
extern "C" {
typedef int64_t sint64;
typedef uint64_t uint64;
typedef int32_t sint32;
typedef int16_t sint16;
typedef int8_t sint8;
typedef uint32_t uint32;
typedef uint16_t uint16;
typedef uint8_t uint8;
typedef intptr_t CSSM_INTPTR;
typedef size_t CSSM_SIZE;
}
extern "C" {
enum {
CSSM_BASE_ERROR = -0x7FFF0000
};
enum {
CSSM_ERRORCODE_MODULE_EXTENT = 0x00000800,
CSSM_ERRORCODE_CUSTOM_OFFSET = 0x00000400,
CSSM_ERRORCODE_COMMON_EXTENT = 0x100
};
enum {
CSSM_CSSM_BASE_ERROR = CSSM_BASE_ERROR,
CSSM_CSSM_PRIVATE_ERROR = CSSM_BASE_ERROR + CSSM_ERRORCODE_CUSTOM_OFFSET,
CSSM_CSP_BASE_ERROR = CSSM_CSSM_BASE_ERROR + CSSM_ERRORCODE_MODULE_EXTENT,
CSSM_CSP_PRIVATE_ERROR = CSSM_CSP_BASE_ERROR + CSSM_ERRORCODE_CUSTOM_OFFSET,
CSSM_DL_BASE_ERROR = CSSM_CSP_BASE_ERROR + CSSM_ERRORCODE_MODULE_EXTENT,
CSSM_DL_PRIVATE_ERROR = CSSM_DL_BASE_ERROR + CSSM_ERRORCODE_CUSTOM_OFFSET,
CSSM_CL_BASE_ERROR = CSSM_DL_BASE_ERROR + CSSM_ERRORCODE_MODULE_EXTENT,
CSSM_CL_PRIVATE_ERROR = CSSM_CL_BASE_ERROR + CSSM_ERRORCODE_CUSTOM_OFFSET,
CSSM_TP_BASE_ERROR = CSSM_CL_BASE_ERROR + CSSM_ERRORCODE_MODULE_EXTENT,
CSSM_TP_PRIVATE_ERROR = CSSM_TP_BASE_ERROR + CSSM_ERRORCODE_CUSTOM_OFFSET ,
CSSM_KR_BASE_ERROR = CSSM_TP_BASE_ERROR + CSSM_ERRORCODE_MODULE_EXTENT,
CSSM_KR_PRIVATE_ERROR = CSSM_KR_BASE_ERROR + CSSM_ERRORCODE_CUSTOM_OFFSET,
CSSM_AC_BASE_ERROR = CSSM_KR_BASE_ERROR + CSSM_ERRORCODE_MODULE_EXTENT,
CSSM_AC_PRIVATE_ERROR = CSSM_AC_BASE_ERROR + CSSM_ERRORCODE_CUSTOM_OFFSET
};
enum {
CSSM_MDS_BASE_ERROR = CSSM_CSP_BASE_ERROR + CSSM_ERRORCODE_MODULE_EXTENT,
CSSM_MDS_PRIVATE_ERROR = CSSM_MDS_BASE_ERROR + CSSM_ERRORCODE_CUSTOM_OFFSET
};
enum {
CSSMERR_CSSM_INVALID_ADDIN_HANDLE =
CSSM_CSSM_BASE_ERROR + CSSM_ERRORCODE_COMMON_EXTENT + 1,
CSSMERR_CSSM_NOT_INITIALIZED =
CSSM_CSSM_BASE_ERROR + CSSM_ERRORCODE_COMMON_EXTENT + 2,
CSSMERR_CSSM_INVALID_HANDLE_USAGE =
CSSM_CSSM_BASE_ERROR + CSSM_ERRORCODE_COMMON_EXTENT + 3,
CSSMERR_CSSM_PVC_REFERENT_NOT_FOUND =
CSSM_CSSM_BASE_ERROR + CSSM_ERRORCODE_COMMON_EXTENT + 4,
CSSMERR_CSSM_FUNCTION_INTEGRITY_FAIL =
CSSM_CSSM_BASE_ERROR + CSSM_ERRORCODE_COMMON_EXTENT + 5
};
enum {
CSSM_ERRCODE_INTERNAL_ERROR = 0x0001,
CSSM_ERRCODE_MEMORY_ERROR = 0x0002,
CSSM_ERRCODE_MDS_ERROR = 0x0003,
CSSM_ERRCODE_INVALID_POINTER = 0x0004,
CSSM_ERRCODE_INVALID_INPUT_POINTER = 0x0005,
CSSM_ERRCODE_INVALID_OUTPUT_POINTER = 0x0006,
CSSM_ERRCODE_FUNCTION_NOT_IMPLEMENTED = 0x0007,
CSSM_ERRCODE_SELF_CHECK_FAILED = 0x0008,
CSSM_ERRCODE_OS_ACCESS_DENIED = 0x0009,
CSSM_ERRCODE_FUNCTION_FAILED = 0x000A,
CSSM_ERRCODE_MODULE_MANIFEST_VERIFY_FAILED = 0x000B,
CSSM_ERRCODE_INVALID_GUID = 0x000C
};
enum {
CSSM_ERRCODE_OPERATION_AUTH_DENIED = 0x0020,
CSSM_ERRCODE_OBJECT_USE_AUTH_DENIED = 0x0021,
CSSM_ERRCODE_OBJECT_MANIP_AUTH_DENIED = 0x0022,
CSSM_ERRCODE_OBJECT_ACL_NOT_SUPPORTED = 0x0023,
CSSM_ERRCODE_OBJECT_ACL_REQUIRED = 0x0024,
CSSM_ERRCODE_INVALID_ACCESS_CREDENTIALS = 0x0025,
CSSM_ERRCODE_INVALID_ACL_BASE_CERTS = 0x0026,
CSSM_ERRCODE_ACL_BASE_CERTS_NOT_SUPPORTED = 0x0027,
CSSM_ERRCODE_INVALID_SAMPLE_VALUE = 0x0028,
CSSM_ERRCODE_SAMPLE_VALUE_NOT_SUPPORTED = 0x0029,
CSSM_ERRCODE_INVALID_ACL_SUBJECT_VALUE = 0x002A,
CSSM_ERRCODE_ACL_SUBJECT_TYPE_NOT_SUPPORTED = 0x002B,
CSSM_ERRCODE_INVALID_ACL_CHALLENGE_CALLBACK = 0x002C,
CSSM_ERRCODE_ACL_CHALLENGE_CALLBACK_FAILED = 0x002D,
CSSM_ERRCODE_INVALID_ACL_ENTRY_TAG = 0x002E,
CSSM_ERRCODE_ACL_ENTRY_TAG_NOT_FOUND = 0x002F,
CSSM_ERRCODE_INVALID_ACL_EDIT_MODE = 0x0030,
CSSM_ERRCODE_ACL_CHANGE_FAILED = 0x0031,
CSSM_ERRCODE_INVALID_NEW_ACL_ENTRY = 0x0032,
CSSM_ERRCODE_INVALID_NEW_ACL_OWNER = 0x0033,
CSSM_ERRCODE_ACL_DELETE_FAILED = 0x0034,
CSSM_ERRCODE_ACL_REPLACE_FAILED = 0x0035,
CSSM_ERRCODE_ACL_ADD_FAILED = 0x0036
};
enum {
CSSM_ERRCODE_INVALID_CONTEXT_HANDLE = 0x0040,
CSSM_ERRCODE_INCOMPATIBLE_VERSION = 0x0041,
CSSM_ERRCODE_INVALID_CERTGROUP_POINTER = 0x0042,
CSSM_ERRCODE_INVALID_CERT_POINTER = 0x0043,
CSSM_ERRCODE_INVALID_CRL_POINTER = 0x0044,
CSSM_ERRCODE_INVALID_FIELD_POINTER = 0x0045,
CSSM_ERRCODE_INVALID_DATA = 0x0046,
CSSM_ERRCODE_CRL_ALREADY_SIGNED = 0x0047,
CSSM_ERRCODE_INVALID_NUMBER_OF_FIELDS = 0x0048,
CSSM_ERRCODE_VERIFICATION_FAILURE = 0x0049,
CSSM_ERRCODE_INVALID_DB_HANDLE = 0x004A,
CSSM_ERRCODE_PRIVILEGE_NOT_GRANTED = 0x004B,
CSSM_ERRCODE_INVALID_DB_LIST = 0x004C,
CSSM_ERRCODE_INVALID_DB_LIST_POINTER = 0x004D,
CSSM_ERRCODE_UNKNOWN_FORMAT = 0x004E,
CSSM_ERRCODE_UNKNOWN_TAG = 0x004F,
CSSM_ERRCODE_INVALID_CSP_HANDLE = 0x0050,
CSSM_ERRCODE_INVALID_DL_HANDLE = 0x0051,
CSSM_ERRCODE_INVALID_CL_HANDLE = 0x0052,
CSSM_ERRCODE_INVALID_TP_HANDLE = 0x0053,
CSSM_ERRCODE_INVALID_KR_HANDLE = 0x0054,
CSSM_ERRCODE_INVALID_AC_HANDLE = 0x0055,
CSSM_ERRCODE_INVALID_PASSTHROUGH_ID = 0x0056,
CSSM_ERRCODE_INVALID_NETWORK_ADDR = 0x0057,
CSSM_ERRCODE_INVALID_CRYPTO_DATA = 0x0058
};
enum {
CSSMERR_CSSM_INTERNAL_ERROR =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_INTERNAL_ERROR,
CSSMERR_CSSM_MEMORY_ERROR =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_MEMORY_ERROR,
CSSMERR_CSSM_MDS_ERROR =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_MDS_ERROR,
CSSMERR_CSSM_INVALID_POINTER =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_INVALID_POINTER,
CSSMERR_CSSM_INVALID_INPUT_POINTER =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_INVALID_INPUT_POINTER,
CSSMERR_CSSM_INVALID_OUTPUT_POINTER =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_INVALID_OUTPUT_POINTER,
CSSMERR_CSSM_FUNCTION_NOT_IMPLEMENTED =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_FUNCTION_NOT_IMPLEMENTED,
CSSMERR_CSSM_SELF_CHECK_FAILED =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_SELF_CHECK_FAILED,
CSSMERR_CSSM_OS_ACCESS_DENIED =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_OS_ACCESS_DENIED,
CSSMERR_CSSM_FUNCTION_FAILED =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_FUNCTION_FAILED,
CSSMERR_CSSM_MODULE_MANIFEST_VERIFY_FAILED =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_MODULE_MANIFEST_VERIFY_FAILED,
CSSMERR_CSSM_INVALID_GUID =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_INVALID_GUID
};
enum {
CSSMERR_CSSM_INVALID_CONTEXT_HANDLE =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_INVALID_CONTEXT_HANDLE,
CSSMERR_CSSM_INCOMPATIBLE_VERSION =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_INCOMPATIBLE_VERSION,
CSSMERR_CSSM_PRIVILEGE_NOT_GRANTED =
CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_PRIVILEGE_NOT_GRANTED
};
enum {
CSSM_CSSM_BASE_CSSM_ERROR =
CSSM_CSSM_BASE_ERROR + CSSM_ERRORCODE_COMMON_EXTENT + 0x10,
CSSMERR_CSSM_SCOPE_NOT_SUPPORTED = CSSM_CSSM_BASE_CSSM_ERROR + 1,
CSSMERR_CSSM_PVC_ALREADY_CONFIGURED = CSSM_CSSM_BASE_CSSM_ERROR + 2,
CSSMERR_CSSM_INVALID_PVC = CSSM_CSSM_BASE_CSSM_ERROR + 3,
CSSMERR_CSSM_EMM_LOAD_FAILED = CSSM_CSSM_BASE_CSSM_ERROR + 4,
CSSMERR_CSSM_EMM_UNLOAD_FAILED = CSSM_CSSM_BASE_CSSM_ERROR + 5,
CSSMERR_CSSM_ADDIN_LOAD_FAILED = CSSM_CSSM_BASE_CSSM_ERROR + 6,
CSSMERR_CSSM_INVALID_KEY_HIERARCHY = CSSM_CSSM_BASE_CSSM_ERROR + 7,
CSSMERR_CSSM_ADDIN_UNLOAD_FAILED = CSSM_CSSM_BASE_CSSM_ERROR + 8,
CSSMERR_CSSM_LIB_REF_NOT_FOUND = CSSM_CSSM_BASE_CSSM_ERROR + 9,
CSSMERR_CSSM_INVALID_ADDIN_FUNCTION_TABLE = CSSM_CSSM_BASE_CSSM_ERROR + 10,
CSSMERR_CSSM_EMM_AUTHENTICATE_FAILED = CSSM_CSSM_BASE_CSSM_ERROR + 11,
CSSMERR_CSSM_ADDIN_AUTHENTICATE_FAILED = CSSM_CSSM_BASE_CSSM_ERROR + 12,
CSSMERR_CSSM_INVALID_SERVICE_MASK = CSSM_CSSM_BASE_CSSM_ERROR + 13,
CSSMERR_CSSM_MODULE_NOT_LOADED = CSSM_CSSM_BASE_CSSM_ERROR + 14,
CSSMERR_CSSM_INVALID_SUBSERVICEID = CSSM_CSSM_BASE_CSSM_ERROR + 15,
CSSMERR_CSSM_BUFFER_TOO_SMALL = CSSM_CSSM_BASE_CSSM_ERROR + 16,
CSSMERR_CSSM_INVALID_ATTRIBUTE = CSSM_CSSM_BASE_CSSM_ERROR + 17,
CSSMERR_CSSM_ATTRIBUTE_NOT_IN_CONTEXT = CSSM_CSSM_BASE_CSSM_ERROR + 18,
CSSMERR_CSSM_MODULE_MANAGER_INITIALIZE_FAIL = CSSM_CSSM_BASE_CSSM_ERROR + 19,
CSSMERR_CSSM_MODULE_MANAGER_NOT_FOUND = CSSM_CSSM_BASE_CSSM_ERROR + 20,
CSSMERR_CSSM_EVENT_NOTIFICATION_CALLBACK_NOT_FOUND = CSSM_CSSM_BASE_CSSM_ERROR + 21
};
enum {
CSSMERR_CSP_INTERNAL_ERROR =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INTERNAL_ERROR,
CSSMERR_CSP_MEMORY_ERROR =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_MEMORY_ERROR,
CSSMERR_CSP_MDS_ERROR =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_MDS_ERROR,
CSSMERR_CSP_INVALID_POINTER =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_POINTER,
CSSMERR_CSP_INVALID_INPUT_POINTER =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_INPUT_POINTER,
CSSMERR_CSP_INVALID_OUTPUT_POINTER =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_OUTPUT_POINTER,
CSSMERR_CSP_FUNCTION_NOT_IMPLEMENTED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_FUNCTION_NOT_IMPLEMENTED,
CSSMERR_CSP_SELF_CHECK_FAILED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_SELF_CHECK_FAILED,
CSSMERR_CSP_OS_ACCESS_DENIED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_OS_ACCESS_DENIED,
CSSMERR_CSP_FUNCTION_FAILED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_FUNCTION_FAILED
};
enum {
CSSMERR_CSP_OPERATION_AUTH_DENIED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_OPERATION_AUTH_DENIED,
CSSMERR_CSP_OBJECT_USE_AUTH_DENIED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_OBJECT_USE_AUTH_DENIED,
CSSMERR_CSP_OBJECT_MANIP_AUTH_DENIED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_OBJECT_MANIP_AUTH_DENIED,
CSSMERR_CSP_OBJECT_ACL_NOT_SUPPORTED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_OBJECT_ACL_NOT_SUPPORTED,
CSSMERR_CSP_OBJECT_ACL_REQUIRED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_OBJECT_ACL_REQUIRED,
CSSMERR_CSP_INVALID_ACCESS_CREDENTIALS =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_ACCESS_CREDENTIALS,
CSSMERR_CSP_INVALID_ACL_BASE_CERTS =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_ACL_BASE_CERTS,
CSSMERR_CSP_ACL_BASE_CERTS_NOT_SUPPORTED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_ACL_BASE_CERTS_NOT_SUPPORTED,
CSSMERR_CSP_INVALID_SAMPLE_VALUE =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_SAMPLE_VALUE,
CSSMERR_CSP_SAMPLE_VALUE_NOT_SUPPORTED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_SAMPLE_VALUE_NOT_SUPPORTED,
CSSMERR_CSP_INVALID_ACL_SUBJECT_VALUE =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_ACL_SUBJECT_VALUE,
CSSMERR_CSP_ACL_SUBJECT_TYPE_NOT_SUPPORTED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_ACL_SUBJECT_TYPE_NOT_SUPPORTED,
CSSMERR_CSP_INVALID_ACL_CHALLENGE_CALLBACK =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_ACL_CHALLENGE_CALLBACK,
CSSMERR_CSP_ACL_CHALLENGE_CALLBACK_FAILED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_ACL_CHALLENGE_CALLBACK_FAILED,
CSSMERR_CSP_INVALID_ACL_ENTRY_TAG =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_ACL_ENTRY_TAG,
CSSMERR_CSP_ACL_ENTRY_TAG_NOT_FOUND =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_ACL_ENTRY_TAG_NOT_FOUND,
CSSMERR_CSP_INVALID_ACL_EDIT_MODE =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_ACL_EDIT_MODE,
CSSMERR_CSP_ACL_CHANGE_FAILED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_ACL_CHANGE_FAILED,
CSSMERR_CSP_INVALID_NEW_ACL_ENTRY =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_NEW_ACL_ENTRY,
CSSMERR_CSP_INVALID_NEW_ACL_OWNER =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_NEW_ACL_OWNER,
CSSMERR_CSP_ACL_DELETE_FAILED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_ACL_DELETE_FAILED,
CSSMERR_CSP_ACL_REPLACE_FAILED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_ACL_REPLACE_FAILED,
CSSMERR_CSP_ACL_ADD_FAILED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_ACL_ADD_FAILED
};
enum {
CSSMERR_CSP_INVALID_CONTEXT_HANDLE =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_CONTEXT_HANDLE,
CSSMERR_CSP_PRIVILEGE_NOT_GRANTED =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_PRIVILEGE_NOT_GRANTED,
CSSMERR_CSP_INVALID_DATA =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_DATA,
CSSMERR_CSP_INVALID_PASSTHROUGH_ID =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_PASSTHROUGH_ID,
CSSMERR_CSP_INVALID_CRYPTO_DATA =
CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INVALID_CRYPTO_DATA
};
enum {
CSSM_CSP_BASE_CSP_ERROR =
CSSM_CSP_BASE_ERROR + CSSM_ERRORCODE_COMMON_EXTENT,
CSSMERR_CSP_INPUT_LENGTH_ERROR = CSSM_CSP_BASE_CSP_ERROR + 1,
CSSMERR_CSP_OUTPUT_LENGTH_ERROR = CSSM_CSP_BASE_CSP_ERROR + 2,
CSSMERR_CSP_PRIVILEGE_NOT_SUPPORTED = CSSM_CSP_BASE_CSP_ERROR + 3,
CSSMERR_CSP_DEVICE_ERROR = CSSM_CSP_BASE_CSP_ERROR + 4,
CSSMERR_CSP_DEVICE_MEMORY_ERROR = CSSM_CSP_BASE_CSP_ERROR + 5,
CSSMERR_CSP_ATTACH_HANDLE_BUSY = CSSM_CSP_BASE_CSP_ERROR + 6,
CSSMERR_CSP_NOT_LOGGED_IN = CSSM_CSP_BASE_CSP_ERROR + 7,
CSSMERR_CSP_INVALID_KEY = CSSM_CSP_BASE_CSP_ERROR + 16,
CSSMERR_CSP_INVALID_KEY_REFERENCE = CSSM_CSP_BASE_CSP_ERROR + 17,
CSSMERR_CSP_INVALID_KEY_CLASS = CSSM_CSP_BASE_CSP_ERROR + 18,
CSSMERR_CSP_ALGID_MISMATCH = CSSM_CSP_BASE_CSP_ERROR + 19,
CSSMERR_CSP_KEY_USAGE_INCORRECT = CSSM_CSP_BASE_CSP_ERROR + 20,
CSSMERR_CSP_KEY_BLOB_TYPE_INCORRECT = CSSM_CSP_BASE_CSP_ERROR + 21,
CSSMERR_CSP_KEY_HEADER_INCONSISTENT = CSSM_CSP_BASE_CSP_ERROR + 22,
CSSMERR_CSP_UNSUPPORTED_KEY_FORMAT = CSSM_CSP_BASE_CSP_ERROR + 23,
CSSMERR_CSP_UNSUPPORTED_KEY_SIZE = CSSM_CSP_BASE_CSP_ERROR + 24,
CSSMERR_CSP_INVALID_KEY_POINTER = CSSM_CSP_BASE_CSP_ERROR + 25,
CSSMERR_CSP_INVALID_KEYUSAGE_MASK = CSSM_CSP_BASE_CSP_ERROR + 26,
CSSMERR_CSP_UNSUPPORTED_KEYUSAGE_MASK = CSSM_CSP_BASE_CSP_ERROR + 27,
CSSMERR_CSP_INVALID_KEYATTR_MASK = CSSM_CSP_BASE_CSP_ERROR + 28,
CSSMERR_CSP_UNSUPPORTED_KEYATTR_MASK = CSSM_CSP_BASE_CSP_ERROR + 29,
CSSMERR_CSP_INVALID_KEY_LABEL = CSSM_CSP_BASE_CSP_ERROR + 30,
CSSMERR_CSP_UNSUPPORTED_KEY_LABEL = CSSM_CSP_BASE_CSP_ERROR + 31,
CSSMERR_CSP_INVALID_KEY_FORMAT = CSSM_CSP_BASE_CSP_ERROR + 32,
CSSMERR_CSP_INVALID_DATA_COUNT = CSSM_CSP_BASE_CSP_ERROR + 40,
CSSMERR_CSP_VECTOR_OF_BUFS_UNSUPPORTED = CSSM_CSP_BASE_CSP_ERROR + 41,
CSSMERR_CSP_INVALID_INPUT_VECTOR = CSSM_CSP_BASE_CSP_ERROR + 42,
CSSMERR_CSP_INVALID_OUTPUT_VECTOR = CSSM_CSP_BASE_CSP_ERROR + 43,
CSSMERR_CSP_INVALID_CONTEXT = CSSM_CSP_BASE_CSP_ERROR + 48,
CSSMERR_CSP_INVALID_ALGORITHM = CSSM_CSP_BASE_CSP_ERROR + 49,
CSSMERR_CSP_INVALID_ATTR_KEY = CSSM_CSP_BASE_CSP_ERROR + 54,
CSSMERR_CSP_MISSING_ATTR_KEY = CSSM_CSP_BASE_CSP_ERROR + 55,
CSSMERR_CSP_INVALID_ATTR_INIT_VECTOR = CSSM_CSP_BASE_CSP_ERROR + 56,
CSSMERR_CSP_MISSING_ATTR_INIT_VECTOR = CSSM_CSP_BASE_CSP_ERROR + 57,
CSSMERR_CSP_INVALID_ATTR_SALT = CSSM_CSP_BASE_CSP_ERROR + 58,
CSSMERR_CSP_MISSING_ATTR_SALT = CSSM_CSP_BASE_CSP_ERROR + 59,
CSSMERR_CSP_INVALID_ATTR_PADDING = CSSM_CSP_BASE_CSP_ERROR + 60,
CSSMERR_CSP_MISSING_ATTR_PADDING = CSSM_CSP_BASE_CSP_ERROR + 61,
CSSMERR_CSP_INVALID_ATTR_RANDOM = CSSM_CSP_BASE_CSP_ERROR + 62,
CSSMERR_CSP_MISSING_ATTR_RANDOM = CSSM_CSP_BASE_CSP_ERROR + 63,
CSSMERR_CSP_INVALID_ATTR_SEED = CSSM_CSP_BASE_CSP_ERROR + 64,
CSSMERR_CSP_MISSING_ATTR_SEED = CSSM_CSP_BASE_CSP_ERROR + 65,
CSSMERR_CSP_INVALID_ATTR_PASSPHRASE = CSSM_CSP_BASE_CSP_ERROR + 66,
CSSMERR_CSP_MISSING_ATTR_PASSPHRASE = CSSM_CSP_BASE_CSP_ERROR + 67,
CSSMERR_CSP_INVALID_ATTR_KEY_LENGTH = CSSM_CSP_BASE_CSP_ERROR + 68,
CSSMERR_CSP_MISSING_ATTR_KEY_LENGTH = CSSM_CSP_BASE_CSP_ERROR + 69,
CSSMERR_CSP_INVALID_ATTR_BLOCK_SIZE = CSSM_CSP_BASE_CSP_ERROR + 70,
CSSMERR_CSP_MISSING_ATTR_BLOCK_SIZE = CSSM_CSP_BASE_CSP_ERROR + 71,
CSSMERR_CSP_INVALID_ATTR_OUTPUT_SIZE = CSSM_CSP_BASE_CSP_ERROR + 100,
CSSMERR_CSP_MISSING_ATTR_OUTPUT_SIZE = CSSM_CSP_BASE_CSP_ERROR + 101,
CSSMERR_CSP_INVALID_ATTR_ROUNDS = CSSM_CSP_BASE_CSP_ERROR + 102,
CSSMERR_CSP_MISSING_ATTR_ROUNDS = CSSM_CSP_BASE_CSP_ERROR + 103,
CSSMERR_CSP_INVALID_ATTR_ALG_PARAMS = CSSM_CSP_BASE_CSP_ERROR + 104,
CSSMERR_CSP_MISSING_ATTR_ALG_PARAMS = CSSM_CSP_BASE_CSP_ERROR + 105,
CSSMERR_CSP_INVALID_ATTR_LABEL = CSSM_CSP_BASE_CSP_ERROR + 106,
CSSMERR_CSP_MISSING_ATTR_LABEL = CSSM_CSP_BASE_CSP_ERROR + 107,
CSSMERR_CSP_INVALID_ATTR_KEY_TYPE = CSSM_CSP_BASE_CSP_ERROR + 108,
CSSMERR_CSP_MISSING_ATTR_KEY_TYPE = CSSM_CSP_BASE_CSP_ERROR + 109,
CSSMERR_CSP_INVALID_ATTR_MODE = CSSM_CSP_BASE_CSP_ERROR + 110,
CSSMERR_CSP_MISSING_ATTR_MODE = CSSM_CSP_BASE_CSP_ERROR + 111,
CSSMERR_CSP_INVALID_ATTR_EFFECTIVE_BITS = CSSM_CSP_BASE_CSP_ERROR + 112,
CSSMERR_CSP_MISSING_ATTR_EFFECTIVE_BITS = CSSM_CSP_BASE_CSP_ERROR + 113,
CSSMERR_CSP_INVALID_ATTR_START_DATE = CSSM_CSP_BASE_CSP_ERROR + 114,
CSSMERR_CSP_MISSING_ATTR_START_DATE = CSSM_CSP_BASE_CSP_ERROR + 115,
CSSMERR_CSP_INVALID_ATTR_END_DATE = CSSM_CSP_BASE_CSP_ERROR + 116,
CSSMERR_CSP_MISSING_ATTR_END_DATE = CSSM_CSP_BASE_CSP_ERROR + 117,
CSSMERR_CSP_INVALID_ATTR_VERSION = CSSM_CSP_BASE_CSP_ERROR + 118,
CSSMERR_CSP_MISSING_ATTR_VERSION = CSSM_CSP_BASE_CSP_ERROR + 119,
CSSMERR_CSP_INVALID_ATTR_PRIME = CSSM_CSP_BASE_CSP_ERROR + 120,
CSSMERR_CSP_MISSING_ATTR_PRIME = CSSM_CSP_BASE_CSP_ERROR + 121,
CSSMERR_CSP_INVALID_ATTR_BASE = CSSM_CSP_BASE_CSP_ERROR + 122,
CSSMERR_CSP_MISSING_ATTR_BASE = CSSM_CSP_BASE_CSP_ERROR + 123,
CSSMERR_CSP_INVALID_ATTR_SUBPRIME = CSSM_CSP_BASE_CSP_ERROR + 124,
CSSMERR_CSP_MISSING_ATTR_SUBPRIME = CSSM_CSP_BASE_CSP_ERROR + 125,
CSSMERR_CSP_INVALID_ATTR_ITERATION_COUNT = CSSM_CSP_BASE_CSP_ERROR + 126,
CSSMERR_CSP_MISSING_ATTR_ITERATION_COUNT = CSSM_CSP_BASE_CSP_ERROR + 127,
CSSMERR_CSP_INVALID_ATTR_DL_DB_HANDLE = CSSM_CSP_BASE_CSP_ERROR + 128,
CSSMERR_CSP_MISSING_ATTR_DL_DB_HANDLE = CSSM_CSP_BASE_CSP_ERROR + 129,
CSSMERR_CSP_INVALID_ATTR_ACCESS_CREDENTIALS = CSSM_CSP_BASE_CSP_ERROR + 130,
CSSMERR_CSP_MISSING_ATTR_ACCESS_CREDENTIALS = CSSM_CSP_BASE_CSP_ERROR + 131,
CSSMERR_CSP_INVALID_ATTR_PUBLIC_KEY_FORMAT = CSSM_CSP_BASE_CSP_ERROR + 132,
CSSMERR_CSP_MISSING_ATTR_PUBLIC_KEY_FORMAT = CSSM_CSP_BASE_CSP_ERROR + 133,
CSSMERR_CSP_INVALID_ATTR_PRIVATE_KEY_FORMAT = CSSM_CSP_BASE_CSP_ERROR + 134,
CSSMERR_CSP_MISSING_ATTR_PRIVATE_KEY_FORMAT = CSSM_CSP_BASE_CSP_ERROR + 135,
CSSMERR_CSP_INVALID_ATTR_SYMMETRIC_KEY_FORMAT = CSSM_CSP_BASE_CSP_ERROR + 136,
CSSMERR_CSP_MISSING_ATTR_SYMMETRIC_KEY_FORMAT = CSSM_CSP_BASE_CSP_ERROR + 137,
CSSMERR_CSP_INVALID_ATTR_WRAPPED_KEY_FORMAT = CSSM_CSP_BASE_CSP_ERROR + 138,
CSSMERR_CSP_MISSING_ATTR_WRAPPED_KEY_FORMAT = CSSM_CSP_BASE_CSP_ERROR + 139,
CSSMERR_CSP_STAGED_OPERATION_IN_PROGRESS = CSSM_CSP_BASE_CSP_ERROR + 72,
CSSMERR_CSP_STAGED_OPERATION_NOT_STARTED = CSSM_CSP_BASE_CSP_ERROR + 73,
CSSMERR_CSP_VERIFY_FAILED = CSSM_CSP_BASE_CSP_ERROR + 74,
CSSMERR_CSP_INVALID_SIGNATURE = CSSM_CSP_BASE_CSP_ERROR + 75,
CSSMERR_CSP_QUERY_SIZE_UNKNOWN = CSSM_CSP_BASE_CSP_ERROR + 76,
CSSMERR_CSP_BLOCK_SIZE_MISMATCH = CSSM_CSP_BASE_CSP_ERROR + 77,
CSSMERR_CSP_PRIVATE_KEY_NOT_FOUND = CSSM_CSP_BASE_CSP_ERROR + 78,
CSSMERR_CSP_PUBLIC_KEY_INCONSISTENT = CSSM_CSP_BASE_CSP_ERROR + 79,
CSSMERR_CSP_DEVICE_VERIFY_FAILED = CSSM_CSP_BASE_CSP_ERROR + 80,
CSSMERR_CSP_INVALID_LOGIN_NAME = CSSM_CSP_BASE_CSP_ERROR + 81,
CSSMERR_CSP_ALREADY_LOGGED_IN = CSSM_CSP_BASE_CSP_ERROR + 82,
CSSMERR_CSP_PRIVATE_KEY_ALREADY_EXISTS = CSSM_CSP_BASE_CSP_ERROR + 83,
CSSMERR_CSP_KEY_LABEL_ALREADY_EXISTS = CSSM_CSP_BASE_CSP_ERROR + 84,
CSSMERR_CSP_INVALID_DIGEST_ALGORITHM = CSSM_CSP_BASE_CSP_ERROR + 85,
CSSMERR_CSP_CRYPTO_DATA_CALLBACK_FAILED = CSSM_CSP_BASE_CSP_ERROR + 86
};
enum {
CSSMERR_TP_INTERNAL_ERROR =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INTERNAL_ERROR,
CSSMERR_TP_MEMORY_ERROR =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_MEMORY_ERROR,
CSSMERR_TP_MDS_ERROR =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_MDS_ERROR,
CSSMERR_TP_INVALID_POINTER =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_POINTER,
CSSMERR_TP_INVALID_INPUT_POINTER =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_INPUT_POINTER,
CSSMERR_TP_INVALID_OUTPUT_POINTER =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_OUTPUT_POINTER,
CSSMERR_TP_FUNCTION_NOT_IMPLEMENTED =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_FUNCTION_NOT_IMPLEMENTED,
CSSMERR_TP_SELF_CHECK_FAILED =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_SELF_CHECK_FAILED,
CSSMERR_TP_OS_ACCESS_DENIED =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_OS_ACCESS_DENIED,
CSSMERR_TP_FUNCTION_FAILED =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_FUNCTION_FAILED,
CSSMERR_TP_INVALID_CONTEXT_HANDLE =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_CONTEXT_HANDLE,
CSSMERR_TP_INVALID_DATA =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_DATA,
CSSMERR_TP_INVALID_DB_LIST =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_DB_LIST,
CSSMERR_TP_INVALID_CERTGROUP_POINTER =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_CERTGROUP_POINTER,
CSSMERR_TP_INVALID_CERT_POINTER =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_CERT_POINTER,
CSSMERR_TP_INVALID_CRL_POINTER =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_CRL_POINTER,
CSSMERR_TP_INVALID_FIELD_POINTER =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_FIELD_POINTER,
CSSMERR_TP_INVALID_NETWORK_ADDR =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_NETWORK_ADDR,
CSSMERR_TP_CRL_ALREADY_SIGNED =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_CRL_ALREADY_SIGNED,
CSSMERR_TP_INVALID_NUMBER_OF_FIELDS =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_NUMBER_OF_FIELDS,
CSSMERR_TP_VERIFICATION_FAILURE =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_VERIFICATION_FAILURE,
CSSMERR_TP_INVALID_DB_HANDLE =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_DB_HANDLE,
CSSMERR_TP_UNKNOWN_FORMAT =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_UNKNOWN_FORMAT,
CSSMERR_TP_UNKNOWN_TAG =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_UNKNOWN_TAG,
CSSMERR_TP_INVALID_PASSTHROUGH_ID =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_PASSTHROUGH_ID,
CSSMERR_TP_INVALID_CSP_HANDLE =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_CSP_HANDLE,
CSSMERR_TP_INVALID_DL_HANDLE =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_DL_HANDLE,
CSSMERR_TP_INVALID_CL_HANDLE =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_CL_HANDLE,
CSSMERR_TP_INVALID_DB_LIST_POINTER =
CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INVALID_DB_LIST_POINTER
};
enum {
CSSM_TP_BASE_TP_ERROR =
CSSM_TP_BASE_ERROR + CSSM_ERRORCODE_COMMON_EXTENT,
CSSMERR_TP_INVALID_CALLERAUTH_CONTEXT_POINTER = CSSM_TP_BASE_TP_ERROR + 1,
CSSMERR_TP_INVALID_IDENTIFIER_POINTER = CSSM_TP_BASE_TP_ERROR + 2,
CSSMERR_TP_INVALID_KEYCACHE_HANDLE = CSSM_TP_BASE_TP_ERROR + 3,
CSSMERR_TP_INVALID_CERTGROUP = CSSM_TP_BASE_TP_ERROR + 4,
CSSMERR_TP_INVALID_CRLGROUP = CSSM_TP_BASE_TP_ERROR + 5,
CSSMERR_TP_INVALID_CRLGROUP_POINTER = CSSM_TP_BASE_TP_ERROR + 6,
CSSMERR_TP_AUTHENTICATION_FAILED = CSSM_TP_BASE_TP_ERROR + 7,
CSSMERR_TP_CERTGROUP_INCOMPLETE = CSSM_TP_BASE_TP_ERROR + 8,
CSSMERR_TP_CERTIFICATE_CANT_OPERATE = CSSM_TP_BASE_TP_ERROR + 9,
CSSMERR_TP_CERT_EXPIRED = CSSM_TP_BASE_TP_ERROR + 10,
CSSMERR_TP_CERT_NOT_VALID_YET = CSSM_TP_BASE_TP_ERROR + 11,
CSSMERR_TP_CERT_REVOKED = CSSM_TP_BASE_TP_ERROR + 12,
CSSMERR_TP_CERT_SUSPENDED = CSSM_TP_BASE_TP_ERROR + 13,
CSSMERR_TP_INSUFFICIENT_CREDENTIALS = CSSM_TP_BASE_TP_ERROR + 14,
CSSMERR_TP_INVALID_ACTION = CSSM_TP_BASE_TP_ERROR + 15,
CSSMERR_TP_INVALID_ACTION_DATA = CSSM_TP_BASE_TP_ERROR + 16,
CSSMERR_TP_INVALID_ANCHOR_CERT = CSSM_TP_BASE_TP_ERROR + 18,
CSSMERR_TP_INVALID_AUTHORITY = CSSM_TP_BASE_TP_ERROR + 19,
CSSMERR_TP_VERIFY_ACTION_FAILED = CSSM_TP_BASE_TP_ERROR + 20,
CSSMERR_TP_INVALID_CERTIFICATE = CSSM_TP_BASE_TP_ERROR + 21,
CSSMERR_TP_INVALID_CERT_AUTHORITY = CSSM_TP_BASE_TP_ERROR + 22,
CSSMERR_TP_INVALID_CRL_AUTHORITY = CSSM_TP_BASE_TP_ERROR + 23,
CSSMERR_TP_INVALID_CRL_ENCODING = CSSM_TP_BASE_TP_ERROR + 24,
CSSMERR_TP_INVALID_CRL_TYPE = CSSM_TP_BASE_TP_ERROR + 25,
CSSMERR_TP_INVALID_CRL = CSSM_TP_BASE_TP_ERROR + 26,
CSSMERR_TP_INVALID_FORM_TYPE = CSSM_TP_BASE_TP_ERROR + 27,
CSSMERR_TP_INVALID_ID = CSSM_TP_BASE_TP_ERROR + 28,
CSSMERR_TP_INVALID_IDENTIFIER = CSSM_TP_BASE_TP_ERROR + 29,
CSSMERR_TP_INVALID_INDEX = CSSM_TP_BASE_TP_ERROR + 30,
CSSMERR_TP_INVALID_NAME = CSSM_TP_BASE_TP_ERROR + 31,
CSSMERR_TP_INVALID_POLICY_IDENTIFIERS = CSSM_TP_BASE_TP_ERROR + 32,
CSSMERR_TP_INVALID_TIMESTRING = CSSM_TP_BASE_TP_ERROR + 33,
CSSMERR_TP_INVALID_REASON = CSSM_TP_BASE_TP_ERROR + 34,
CSSMERR_TP_INVALID_REQUEST_INPUTS = CSSM_TP_BASE_TP_ERROR + 35,
CSSMERR_TP_INVALID_RESPONSE_VECTOR = CSSM_TP_BASE_TP_ERROR + 36,
CSSMERR_TP_INVALID_SIGNATURE = CSSM_TP_BASE_TP_ERROR + 37,
CSSMERR_TP_INVALID_STOP_ON_POLICY = CSSM_TP_BASE_TP_ERROR + 38,
CSSMERR_TP_INVALID_CALLBACK = CSSM_TP_BASE_TP_ERROR + 39,
CSSMERR_TP_INVALID_TUPLE = CSSM_TP_BASE_TP_ERROR + 40,
CSSMERR_TP_NOT_SIGNER = CSSM_TP_BASE_TP_ERROR + 41,
CSSMERR_TP_NOT_TRUSTED = CSSM_TP_BASE_TP_ERROR + 42,
CSSMERR_TP_NO_DEFAULT_AUTHORITY = CSSM_TP_BASE_TP_ERROR + 43,
CSSMERR_TP_REJECTED_FORM = CSSM_TP_BASE_TP_ERROR + 44,
CSSMERR_TP_REQUEST_LOST = CSSM_TP_BASE_TP_ERROR + 45,
CSSMERR_TP_REQUEST_REJECTED = CSSM_TP_BASE_TP_ERROR + 46,
CSSMERR_TP_UNSUPPORTED_ADDR_TYPE = CSSM_TP_BASE_TP_ERROR + 47,
CSSMERR_TP_UNSUPPORTED_SERVICE = CSSM_TP_BASE_TP_ERROR + 48,
CSSMERR_TP_INVALID_TUPLEGROUP_POINTER = CSSM_TP_BASE_TP_ERROR + 49,
CSSMERR_TP_INVALID_TUPLEGROUP = CSSM_TP_BASE_TP_ERROR + 50
};
enum {
CSSMERR_AC_INTERNAL_ERROR =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INTERNAL_ERROR,
CSSMERR_AC_MEMORY_ERROR =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_MEMORY_ERROR,
CSSMERR_AC_MDS_ERROR =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_MDS_ERROR,
CSSMERR_AC_INVALID_POINTER =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_POINTER,
CSSMERR_AC_INVALID_INPUT_POINTER =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_INPUT_POINTER,
CSSMERR_AC_INVALID_OUTPUT_POINTER =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_OUTPUT_POINTER,
CSSMERR_AC_FUNCTION_NOT_IMPLEMENTED =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_FUNCTION_NOT_IMPLEMENTED,
CSSMERR_AC_SELF_CHECK_FAILED =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_SELF_CHECK_FAILED,
CSSMERR_AC_OS_ACCESS_DENIED =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_OS_ACCESS_DENIED,
CSSMERR_AC_FUNCTION_FAILED =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_FUNCTION_FAILED,
CSSMERR_AC_INVALID_CONTEXT_HANDLE =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_CONTEXT_HANDLE,
CSSMERR_AC_INVALID_DATA =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_DATA,
CSSMERR_AC_INVALID_DB_LIST =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_DB_LIST,
CSSMERR_AC_INVALID_PASSTHROUGH_ID =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_PASSTHROUGH_ID,
CSSMERR_AC_INVALID_DL_HANDLE =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_DL_HANDLE,
CSSMERR_AC_INVALID_CL_HANDLE =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_CL_HANDLE,
CSSMERR_AC_INVALID_TP_HANDLE =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_TP_HANDLE,
CSSMERR_AC_INVALID_DB_HANDLE =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_DB_HANDLE,
CSSMERR_AC_INVALID_DB_LIST_POINTER =
CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INVALID_DB_LIST_POINTER
};
enum {
CSSM_AC_BASE_AC_ERROR =
CSSM_AC_BASE_ERROR + CSSM_ERRORCODE_COMMON_EXTENT,
CSSMERR_AC_INVALID_BASE_ACLS = CSSM_AC_BASE_AC_ERROR + 1,
CSSMERR_AC_INVALID_TUPLE_CREDENTIALS = CSSM_AC_BASE_AC_ERROR + 2,
CSSMERR_AC_INVALID_ENCODING = CSSM_AC_BASE_AC_ERROR + 3,
CSSMERR_AC_INVALID_VALIDITY_PERIOD = CSSM_AC_BASE_AC_ERROR + 4,
CSSMERR_AC_INVALID_REQUESTOR = CSSM_AC_BASE_AC_ERROR + 5,
CSSMERR_AC_INVALID_REQUEST_DESCRIPTOR = CSSM_AC_BASE_AC_ERROR + 6
};
enum {
CSSMERR_CL_INTERNAL_ERROR =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INTERNAL_ERROR,
CSSMERR_CL_MEMORY_ERROR =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_MEMORY_ERROR,
CSSMERR_CL_MDS_ERROR =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_MDS_ERROR,
CSSMERR_CL_INVALID_POINTER =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INVALID_POINTER,
CSSMERR_CL_INVALID_INPUT_POINTER =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INVALID_INPUT_POINTER,
CSSMERR_CL_INVALID_OUTPUT_POINTER =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INVALID_OUTPUT_POINTER,
CSSMERR_CL_FUNCTION_NOT_IMPLEMENTED =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_FUNCTION_NOT_IMPLEMENTED,
CSSMERR_CL_SELF_CHECK_FAILED =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_SELF_CHECK_FAILED,
CSSMERR_CL_OS_ACCESS_DENIED =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_OS_ACCESS_DENIED,
CSSMERR_CL_FUNCTION_FAILED =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_FUNCTION_FAILED,
CSSMERR_CL_INVALID_CONTEXT_HANDLE =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INVALID_CONTEXT_HANDLE,
CSSMERR_CL_INVALID_CERTGROUP_POINTER =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INVALID_CERTGROUP_POINTER,
CSSMERR_CL_INVALID_CERT_POINTER =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INVALID_CERT_POINTER,
CSSMERR_CL_INVALID_CRL_POINTER =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INVALID_CRL_POINTER,
CSSMERR_CL_INVALID_FIELD_POINTER =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INVALID_FIELD_POINTER,
CSSMERR_CL_INVALID_DATA =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INVALID_DATA,
CSSMERR_CL_CRL_ALREADY_SIGNED =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_CRL_ALREADY_SIGNED,
CSSMERR_CL_INVALID_NUMBER_OF_FIELDS =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INVALID_NUMBER_OF_FIELDS,
CSSMERR_CL_VERIFICATION_FAILURE =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_VERIFICATION_FAILURE,
CSSMERR_CL_UNKNOWN_FORMAT =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_UNKNOWN_FORMAT,
CSSMERR_CL_UNKNOWN_TAG =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_UNKNOWN_TAG,
CSSMERR_CL_INVALID_PASSTHROUGH_ID =
CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INVALID_PASSTHROUGH_ID
};
enum {
CSSM_CL_BASE_CL_ERROR =
CSSM_CL_BASE_ERROR + CSSM_ERRORCODE_COMMON_EXTENT,
CSSMERR_CL_INVALID_BUNDLE_POINTER = CSSM_CL_BASE_CL_ERROR + 1,
CSSMERR_CL_INVALID_CACHE_HANDLE = CSSM_CL_BASE_CL_ERROR + 2,
CSSMERR_CL_INVALID_RESULTS_HANDLE = CSSM_CL_BASE_CL_ERROR + 3,
CSSMERR_CL_INVALID_BUNDLE_INFO = CSSM_CL_BASE_CL_ERROR + 4,
CSSMERR_CL_INVALID_CRL_INDEX = CSSM_CL_BASE_CL_ERROR + 5,
CSSMERR_CL_INVALID_SCOPE = CSSM_CL_BASE_CL_ERROR + 6,
CSSMERR_CL_NO_FIELD_VALUES = CSSM_CL_BASE_CL_ERROR + 7,
CSSMERR_CL_SCOPE_NOT_SUPPORTED = CSSM_CL_BASE_CL_ERROR + 8
};
enum {
CSSMERR_DL_INTERNAL_ERROR =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INTERNAL_ERROR,
CSSMERR_DL_MEMORY_ERROR =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_MEMORY_ERROR,
CSSMERR_DL_MDS_ERROR =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_MDS_ERROR,
CSSMERR_DL_INVALID_POINTER =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_POINTER,
CSSMERR_DL_INVALID_INPUT_POINTER =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_INPUT_POINTER,
CSSMERR_DL_INVALID_OUTPUT_POINTER =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_OUTPUT_POINTER,
CSSMERR_DL_FUNCTION_NOT_IMPLEMENTED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_FUNCTION_NOT_IMPLEMENTED,
CSSMERR_DL_SELF_CHECK_FAILED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_SELF_CHECK_FAILED,
CSSMERR_DL_OS_ACCESS_DENIED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_OS_ACCESS_DENIED,
CSSMERR_DL_FUNCTION_FAILED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_FUNCTION_FAILED,
CSSMERR_DL_INVALID_CSP_HANDLE =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_CSP_HANDLE,
CSSMERR_DL_INVALID_DL_HANDLE =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_DL_HANDLE,
CSSMERR_DL_INVALID_CL_HANDLE =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_CL_HANDLE,
CSSMERR_DL_INVALID_DB_LIST_POINTER =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_DB_LIST_POINTER
};
enum {
CSSMERR_DL_OPERATION_AUTH_DENIED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_OPERATION_AUTH_DENIED,
CSSMERR_DL_OBJECT_USE_AUTH_DENIED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_OBJECT_USE_AUTH_DENIED,
CSSMERR_DL_OBJECT_MANIP_AUTH_DENIED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_OBJECT_MANIP_AUTH_DENIED,
CSSMERR_DL_OBJECT_ACL_NOT_SUPPORTED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_OBJECT_ACL_NOT_SUPPORTED,
CSSMERR_DL_OBJECT_ACL_REQUIRED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_OBJECT_ACL_REQUIRED,
CSSMERR_DL_INVALID_ACCESS_CREDENTIALS =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_ACCESS_CREDENTIALS,
CSSMERR_DL_INVALID_ACL_BASE_CERTS =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_ACL_BASE_CERTS,
CSSMERR_DL_ACL_BASE_CERTS_NOT_SUPPORTED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_ACL_BASE_CERTS_NOT_SUPPORTED,
CSSMERR_DL_INVALID_SAMPLE_VALUE =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_SAMPLE_VALUE,
CSSMERR_DL_SAMPLE_VALUE_NOT_SUPPORTED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_SAMPLE_VALUE_NOT_SUPPORTED,
CSSMERR_DL_INVALID_ACL_SUBJECT_VALUE =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_ACL_SUBJECT_VALUE,
CSSMERR_DL_ACL_SUBJECT_TYPE_NOT_SUPPORTED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_ACL_SUBJECT_TYPE_NOT_SUPPORTED,
CSSMERR_DL_INVALID_ACL_CHALLENGE_CALLBACK =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_ACL_CHALLENGE_CALLBACK,
CSSMERR_DL_ACL_CHALLENGE_CALLBACK_FAILED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_ACL_CHALLENGE_CALLBACK_FAILED,
CSSMERR_DL_INVALID_ACL_ENTRY_TAG =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_ACL_ENTRY_TAG,
CSSMERR_DL_ACL_ENTRY_TAG_NOT_FOUND =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_ACL_ENTRY_TAG_NOT_FOUND,
CSSMERR_DL_INVALID_ACL_EDIT_MODE =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_ACL_EDIT_MODE,
CSSMERR_DL_ACL_CHANGE_FAILED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_ACL_CHANGE_FAILED,
CSSMERR_DL_INVALID_NEW_ACL_ENTRY =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_NEW_ACL_ENTRY,
CSSMERR_DL_INVALID_NEW_ACL_OWNER =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_NEW_ACL_OWNER,
CSSMERR_DL_ACL_DELETE_FAILED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_ACL_DELETE_FAILED,
CSSMERR_DL_ACL_REPLACE_FAILED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_ACL_REPLACE_FAILED,
CSSMERR_DL_ACL_ADD_FAILED =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_ACL_ADD_FAILED
};
enum {
CSSMERR_DL_INVALID_DB_HANDLE =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_DB_HANDLE,
CSSMERR_DL_INVALID_PASSTHROUGH_ID =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_PASSTHROUGH_ID,
CSSMERR_DL_INVALID_NETWORK_ADDR =
CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INVALID_NETWORK_ADDR
};
enum {
CSSM_DL_BASE_DL_ERROR =
CSSM_DL_BASE_ERROR + CSSM_ERRORCODE_COMMON_EXTENT,
CSSMERR_DL_DATABASE_CORRUPT = CSSM_DL_BASE_DL_ERROR + 1,
CSSMERR_DL_INVALID_RECORD_INDEX = CSSM_DL_BASE_DL_ERROR + 8,
CSSMERR_DL_INVALID_RECORDTYPE = CSSM_DL_BASE_DL_ERROR + 9,
CSSMERR_DL_INVALID_FIELD_NAME = CSSM_DL_BASE_DL_ERROR + 10,
CSSMERR_DL_UNSUPPORTED_FIELD_FORMAT = CSSM_DL_BASE_DL_ERROR + 11,
CSSMERR_DL_UNSUPPORTED_INDEX_INFO = CSSM_DL_BASE_DL_ERROR + 12,
CSSMERR_DL_UNSUPPORTED_LOCALITY = CSSM_DL_BASE_DL_ERROR + 13,
CSSMERR_DL_UNSUPPORTED_NUM_ATTRIBUTES = CSSM_DL_BASE_DL_ERROR + 14,
CSSMERR_DL_UNSUPPORTED_NUM_INDEXES = CSSM_DL_BASE_DL_ERROR + 15,
CSSMERR_DL_UNSUPPORTED_NUM_RECORDTYPES = CSSM_DL_BASE_DL_ERROR + 16,
CSSMERR_DL_UNSUPPORTED_RECORDTYPE = CSSM_DL_BASE_DL_ERROR + 17,
CSSMERR_DL_FIELD_SPECIFIED_MULTIPLE = CSSM_DL_BASE_DL_ERROR + 18,
CSSMERR_DL_INCOMPATIBLE_FIELD_FORMAT = CSSM_DL_BASE_DL_ERROR + 19,
CSSMERR_DL_INVALID_PARSING_MODULE = CSSM_DL_BASE_DL_ERROR + 20,
CSSMERR_DL_INVALID_DB_NAME = CSSM_DL_BASE_DL_ERROR + 22,
CSSMERR_DL_DATASTORE_DOESNOT_EXIST = CSSM_DL_BASE_DL_ERROR + 23,
CSSMERR_DL_DATASTORE_ALREADY_EXISTS = CSSM_DL_BASE_DL_ERROR + 24,
CSSMERR_DL_DB_LOCKED = CSSM_DL_BASE_DL_ERROR + 25,
CSSMERR_DL_DATASTORE_IS_OPEN = CSSM_DL_BASE_DL_ERROR + 26,
CSSMERR_DL_RECORD_NOT_FOUND = CSSM_DL_BASE_DL_ERROR + 27,
CSSMERR_DL_MISSING_VALUE = CSSM_DL_BASE_DL_ERROR + 28,
CSSMERR_DL_UNSUPPORTED_QUERY = CSSM_DL_BASE_DL_ERROR + 29,
CSSMERR_DL_UNSUPPORTED_QUERY_LIMITS = CSSM_DL_BASE_DL_ERROR + 30,
CSSMERR_DL_UNSUPPORTED_NUM_SELECTION_PREDS = CSSM_DL_BASE_DL_ERROR + 31,
CSSMERR_DL_UNSUPPORTED_OPERATOR = CSSM_DL_BASE_DL_ERROR + 33,
CSSMERR_DL_INVALID_RESULTS_HANDLE = CSSM_DL_BASE_DL_ERROR + 34,
CSSMERR_DL_INVALID_DB_LOCATION = CSSM_DL_BASE_DL_ERROR + 35,
CSSMERR_DL_INVALID_ACCESS_REQUEST = CSSM_DL_BASE_DL_ERROR + 36,
CSSMERR_DL_INVALID_INDEX_INFO = CSSM_DL_BASE_DL_ERROR + 37,
CSSMERR_DL_INVALID_SELECTION_TAG = CSSM_DL_BASE_DL_ERROR + 38,
CSSMERR_DL_INVALID_NEW_OWNER = CSSM_DL_BASE_DL_ERROR + 39,
CSSMERR_DL_INVALID_RECORD_UID = CSSM_DL_BASE_DL_ERROR + 40,
CSSMERR_DL_INVALID_UNIQUE_INDEX_DATA = CSSM_DL_BASE_DL_ERROR + 41,
CSSMERR_DL_INVALID_MODIFY_MODE = CSSM_DL_BASE_DL_ERROR + 42,
CSSMERR_DL_INVALID_OPEN_PARAMETERS = CSSM_DL_BASE_DL_ERROR + 43,
CSSMERR_DL_RECORD_MODIFIED = CSSM_DL_BASE_DL_ERROR + 44,
CSSMERR_DL_ENDOFDATA = CSSM_DL_BASE_DL_ERROR + 45,
CSSMERR_DL_INVALID_QUERY = CSSM_DL_BASE_DL_ERROR + 46,
CSSMERR_DL_INVALID_VALUE = CSSM_DL_BASE_DL_ERROR + 47,
CSSMERR_DL_MULTIPLE_VALUES_UNSUPPORTED = CSSM_DL_BASE_DL_ERROR + 48,
CSSMERR_DL_STALE_UNIQUE_RECORD = CSSM_DL_BASE_DL_ERROR + 49
};
}
extern "C" {
typedef CSSM_INTPTR CSSM_HANDLE, *CSSM_HANDLE_PTR;
typedef uint64 CSSM_LONG_HANDLE, *CSSM_LONG_HANDLE_PTR;
typedef CSSM_HANDLE CSSM_MODULE_HANDLE, *CSSM_MODULE_HANDLE_PTR;
typedef CSSM_LONG_HANDLE CSSM_CC_HANDLE;
typedef CSSM_MODULE_HANDLE CSSM_CSP_HANDLE;
typedef CSSM_MODULE_HANDLE CSSM_TP_HANDLE;
typedef CSSM_MODULE_HANDLE CSSM_AC_HANDLE;
typedef CSSM_MODULE_HANDLE CSSM_CL_HANDLE;
typedef CSSM_MODULE_HANDLE CSSM_DL_HANDLE;
typedef CSSM_MODULE_HANDLE CSSM_DB_HANDLE;
enum {
CSSM_INVALID_HANDLE = 0
};
typedef sint32 CSSM_BOOL;
enum {
CSSM_FALSE = 0,
CSSM_TRUE = !CSSM_FALSE
};
typedef sint32 CSSM_RETURN;
enum {
CSSM_OK = 0
};
enum {
CSSM_MODULE_STRING_SIZE = 64
};
typedef char CSSM_STRING [CSSM_MODULE_STRING_SIZE + 4];
typedef struct cssm_data {
CSSM_SIZE Length;
uint8 *Data;
} CSSM_DATA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DATA_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_guid {
uint32 Data1;
uint16 Data2;
uint16 Data3;
uint8 Data4[8];
} CSSM_GUID __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_GUID_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_BITMASK;
typedef CSSM_BITMASK CSSM_KEY_HIERARCHY;
enum {
CSSM_KEY_HIERARCHY_NONE = 0,
CSSM_KEY_HIERARCHY_INTEG = 1,
CSSM_KEY_HIERARCHY_EXPORT = 2
};
typedef CSSM_BITMASK CSSM_PVC_MODE;
enum {
CSSM_PVC_NONE = 0,
CSSM_PVC_APP = 1,
CSSM_PVC_SP = 2
};
typedef uint32 CSSM_PRIVILEGE_SCOPE;
enum {
CSSM_PRIVILEGE_SCOPE_NONE = 0,
CSSM_PRIVILEGE_SCOPE_PROCESS = 1,
CSSM_PRIVILEGE_SCOPE_THREAD = 2
};
typedef struct cssm_version {
uint32 Major;
uint32 Minor;
} CSSM_VERSION __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_VERSION_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_SERVICE_MASK;
enum {
CSSM_SERVICE_CSSM = 0x1,
CSSM_SERVICE_CSP = 0x2,
CSSM_SERVICE_DL = 0x4,
CSSM_SERVICE_CL = 0x8,
CSSM_SERVICE_TP = 0x10,
CSSM_SERVICE_AC = 0x20,
CSSM_SERVICE_KR = 0x40
};
typedef CSSM_SERVICE_MASK CSSM_SERVICE_TYPE;
typedef struct cssm_subservice_uid {
CSSM_GUID Guid;
CSSM_VERSION Version;
uint32 SubserviceId;
CSSM_SERVICE_TYPE SubserviceType;
} CSSM_SUBSERVICE_UID __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_SUBSERVICE_UID_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_MODULE_EVENT, *CSSM_MODULE_EVENT_PTR;
enum {
CSSM_NOTIFY_INSERT = 1,
CSSM_NOTIFY_REMOVE = 2,
CSSM_NOTIFY_FAULT = 3
};
typedef CSSM_RETURN ( *CSSM_API_ModuleEventHandler)
(const CSSM_GUID *ModuleGuid,
void* AppNotifyCallbackCtx,
uint32 SubserviceId,
CSSM_SERVICE_TYPE ServiceType,
CSSM_MODULE_EVENT EventType);
typedef uint32 CSSM_ATTACH_FLAGS;
enum {
CSSM_ATTACH_READ_ONLY = 0x00000001
};
typedef uint64 CSSM_PRIVILEGE;
typedef CSSM_PRIVILEGE CSSM_USEE_TAG;
enum {
CSSM_USEE_LAST = 0xFF,
CSSM_USEE_NONE = 0,
CSSM_USEE_DOMESTIC = 1,
CSSM_USEE_FINANCIAL = 2,
CSSM_USEE_KRLE = 3,
CSSM_USEE_KRENT = 4,
CSSM_USEE_SSL = 5,
CSSM_USEE_AUTHENTICATION = 6,
CSSM_USEE_KEYEXCH = 7,
CSSM_USEE_MEDICAL = 8,
CSSM_USEE_INSURANCE = 9,
CSSM_USEE_WEAK = 10
};
typedef uint32 CSSM_NET_ADDRESS_TYPE;
enum {
CSSM_ADDR_NONE = 0,
CSSM_ADDR_CUSTOM = 1,
CSSM_ADDR_URL = 2,
CSSM_ADDR_SOCKADDR = 3,
CSSM_ADDR_NAME = 4
};
typedef struct cssm_net_address {
CSSM_NET_ADDRESS_TYPE AddressType;
CSSM_DATA Address;
} CSSM_NET_ADDRESS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_NET_ADDRESS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_NET_PROTOCOL;
enum {
CSSM_NET_PROTO_NONE = 0,
CSSM_NET_PROTO_CUSTOM = 1,
CSSM_NET_PROTO_UNSPECIFIED = 2,
CSSM_NET_PROTO_LDAP = 3,
CSSM_NET_PROTO_LDAPS = 4,
CSSM_NET_PROTO_LDAPNS = 5,
CSSM_NET_PROTO_X500DAP = 6,
CSSM_NET_PROTO_FTP = 7,
CSSM_NET_PROTO_FTPS = 8,
CSSM_NET_PROTO_OCSP = 9,
CSSM_NET_PROTO_CMP = 10,
CSSM_NET_PROTO_CMPS = 11
};
typedef CSSM_RETURN ( *CSSM_CALLBACK)
(CSSM_DATA_PTR OutData, void *CallerCtx);
typedef struct cssm_crypto_data {
CSSM_DATA Param;
CSSM_CALLBACK Callback;
void *CallerCtx;
} CSSM_CRYPTO_DATA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_CRYPTO_DATA_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef sint32 CSSM_WORDID_TYPE;
enum {
CSSM_WORDID__UNK_ = -1,
CSSM_WORDID__NLU_ = 0,
CSSM_WORDID__STAR_ = 1,
CSSM_WORDID_A = 2,
CSSM_WORDID_ACL = 3,
CSSM_WORDID_ALPHA = 4,
CSSM_WORDID_B = 5,
CSSM_WORDID_BER = 6,
CSSM_WORDID_BINARY = 7,
CSSM_WORDID_BIOMETRIC = 8,
CSSM_WORDID_C = 9,
CSSM_WORDID_CANCELED = 10,
CSSM_WORDID_CERT = 11,
CSSM_WORDID_COMMENT = 12,
CSSM_WORDID_CRL = 13,
CSSM_WORDID_CUSTOM = 14,
CSSM_WORDID_D = 15,
CSSM_WORDID_DATE = 16,
CSSM_WORDID_DB_DELETE = 17,
CSSM_WORDID_DB_EXEC_STORED_QUERY = 18,
CSSM_WORDID_DB_INSERT = 19,
CSSM_WORDID_DB_MODIFY = 20,
CSSM_WORDID_DB_READ = 21,
CSSM_WORDID_DBS_CREATE = 22,
CSSM_WORDID_DBS_DELETE = 23,
CSSM_WORDID_DECRYPT = 24,
CSSM_WORDID_DELETE = 25,
CSSM_WORDID_DELTA_CRL = 26,
CSSM_WORDID_DER = 27,
CSSM_WORDID_DERIVE = 28,
CSSM_WORDID_DISPLAY = 29,
CSSM_WORDID_DO = 30,
CSSM_WORDID_DSA = 31,
CSSM_WORDID_DSA_SHA1 = 32,
CSSM_WORDID_E = 33,
CSSM_WORDID_ELGAMAL = 34,
CSSM_WORDID_ENCRYPT = 35,
CSSM_WORDID_ENTRY = 36,
CSSM_WORDID_EXPORT_CLEAR = 37,
CSSM_WORDID_EXPORT_WRAPPED = 38,
CSSM_WORDID_G = 39,
CSSM_WORDID_GE = 40,
CSSM_WORDID_GENKEY = 41,
CSSM_WORDID_HASH = 42,
CSSM_WORDID_HASHED_PASSWORD = 43,
CSSM_WORDID_HASHED_SUBJECT = 44,
CSSM_WORDID_HAVAL = 45,
CSSM_WORDID_IBCHASH = 46,
CSSM_WORDID_IMPORT_CLEAR = 47,
CSSM_WORDID_IMPORT_WRAPPED = 48,
CSSM_WORDID_INTEL = 49,
CSSM_WORDID_ISSUER = 50,
CSSM_WORDID_ISSUER_INFO = 51,
CSSM_WORDID_K_OF_N = 52,
CSSM_WORDID_KEA = 53,
CSSM_WORDID_KEYHOLDER = 54,
CSSM_WORDID_L = 55,
CSSM_WORDID_LE = 56,
CSSM_WORDID_LOGIN = 57,
CSSM_WORDID_LOGIN_NAME = 58,
CSSM_WORDID_MAC = 59,
CSSM_WORDID_MD2 = 60,
CSSM_WORDID_MD2WITHRSA = 61,
CSSM_WORDID_MD4 = 62,
CSSM_WORDID_MD5 = 63,
CSSM_WORDID_MD5WITHRSA = 64,
CSSM_WORDID_N = 65,
CSSM_WORDID_NAME = 66,
CSSM_WORDID_NDR = 67,
CSSM_WORDID_NHASH = 68,
CSSM_WORDID_NOT_AFTER = 69,
CSSM_WORDID_NOT_BEFORE = 70,
CSSM_WORDID_NULL = 71,
CSSM_WORDID_NUMERIC = 72,
CSSM_WORDID_OBJECT_HASH = 73,
CSSM_WORDID_ONE_TIME = 74,
CSSM_WORDID_ONLINE = 75,
CSSM_WORDID_OWNER = 76,
CSSM_WORDID_P = 77,
CSSM_WORDID_PAM_NAME = 78,
CSSM_WORDID_PASSWORD = 79,
CSSM_WORDID_PGP = 80,
CSSM_WORDID_PREFIX = 81,
CSSM_WORDID_PRIVATE_KEY = 82,
CSSM_WORDID_PROMPTED_BIOMETRIC = 83,
CSSM_WORDID_PROMPTED_PASSWORD = 84,
CSSM_WORDID_PROPAGATE = 85,
CSSM_WORDID_PROTECTED_BIOMETRIC = 86,
CSSM_WORDID_PROTECTED_PASSWORD = 87,
CSSM_WORDID_PROTECTED_PIN = 88,
CSSM_WORDID_PUBLIC_KEY = 89,
CSSM_WORDID_PUBLIC_KEY_FROM_CERT = 90,
CSSM_WORDID_Q = 91,
CSSM_WORDID_RANGE = 92,
CSSM_WORDID_REVAL = 93,
CSSM_WORDID_RIPEMAC = 94,
CSSM_WORDID_RIPEMD = 95,
CSSM_WORDID_RIPEMD160 = 96,
CSSM_WORDID_RSA = 97,
CSSM_WORDID_RSA_ISO9796 = 98,
CSSM_WORDID_RSA_PKCS = 99,
CSSM_WORDID_RSA_PKCS_MD5 = 100,
CSSM_WORDID_RSA_PKCS_SHA1 = 101,
CSSM_WORDID_RSA_PKCS1 = 102,
CSSM_WORDID_RSA_PKCS1_MD5 = 103,
CSSM_WORDID_RSA_PKCS1_SHA1 = 104,
CSSM_WORDID_RSA_PKCS1_SIG = 105,
CSSM_WORDID_RSA_RAW = 106,
CSSM_WORDID_SDSIV1 = 107,
CSSM_WORDID_SEQUENCE = 108,
CSSM_WORDID_SET = 109,
CSSM_WORDID_SEXPR = 110,
CSSM_WORDID_SHA1 = 111,
CSSM_WORDID_SHA1WITHDSA = 112,
CSSM_WORDID_SHA1WITHECDSA = 113,
CSSM_WORDID_SHA1WITHRSA = 114,
CSSM_WORDID_SIGN = 115,
CSSM_WORDID_SIGNATURE = 116,
CSSM_WORDID_SIGNED_NONCE = 117,
CSSM_WORDID_SIGNED_SECRET = 118,
CSSM_WORDID_SPKI = 119,
CSSM_WORDID_SUBJECT = 120,
CSSM_WORDID_SUBJECT_INFO = 121,
CSSM_WORDID_TAG = 122,
CSSM_WORDID_THRESHOLD = 123,
CSSM_WORDID_TIME = 124,
CSSM_WORDID_URI = 125,
CSSM_WORDID_VERSION = 126,
CSSM_WORDID_X509_ATTRIBUTE = 127,
CSSM_WORDID_X509V1 = 128,
CSSM_WORDID_X509V2 = 129,
CSSM_WORDID_X509V3 = 130,
CSSM_WORDID_X9_ATTRIBUTE = 131,
CSSM_WORDID_VENDOR_START = 0x00010000,
CSSM_WORDID_VENDOR_END = 0x7FFF0000
};
typedef uint32 CSSM_LIST_ELEMENT_TYPE, *CSSM_LIST_ELEMENT_TYPE_PTR;
enum {
CSSM_LIST_ELEMENT_DATUM = 0x00,
CSSM_LIST_ELEMENT_SUBLIST = 0x01,
CSSM_LIST_ELEMENT_WORDID = 0x02
};
typedef uint32 CSSM_LIST_TYPE, *CSSM_LIST_TYPE_PTR;
enum {
CSSM_LIST_TYPE_UNKNOWN = 0,
CSSM_LIST_TYPE_CUSTOM = 1,
CSSM_LIST_TYPE_SEXPR = 2
};
typedef struct cssm_list_element *CSSM_LIST_ELEMENT_PTR;
typedef struct cssm_list {
CSSM_LIST_TYPE ListType;
CSSM_LIST_ELEMENT_PTR Head;
CSSM_LIST_ELEMENT_PTR Tail;
} CSSM_LIST __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_LIST_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_list_element {
struct cssm_list_element *NextElement;
CSSM_WORDID_TYPE WordID;
CSSM_LIST_ELEMENT_TYPE ElementType;
union {
CSSM_LIST Sublist;
CSSM_DATA Word;
} Element;
} CSSM_LIST_ELEMENT;
typedef struct {
CSSM_LIST Issuer;
CSSM_LIST Subject;
CSSM_BOOL Delegate;
CSSM_LIST AuthorizationTag;
CSSM_LIST ValidityPeriod;
} CSSM_TUPLE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TUPLE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tuplegroup {
uint32 NumberOfTuples;
CSSM_TUPLE_PTR Tuples;
} CSSM_TUPLEGROUP __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TUPLEGROUP_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef CSSM_WORDID_TYPE CSSM_SAMPLE_TYPE;
enum {
CSSM_SAMPLE_TYPE_PASSWORD = CSSM_WORDID_PASSWORD,
CSSM_SAMPLE_TYPE_HASHED_PASSWORD = CSSM_WORDID_HASHED_PASSWORD,
CSSM_SAMPLE_TYPE_PROTECTED_PASSWORD = CSSM_WORDID_PROTECTED_PASSWORD,
CSSM_SAMPLE_TYPE_PROMPTED_PASSWORD = CSSM_WORDID_PROMPTED_PASSWORD,
CSSM_SAMPLE_TYPE_SIGNED_NONCE = CSSM_WORDID_SIGNED_NONCE,
CSSM_SAMPLE_TYPE_SIGNED_SECRET = CSSM_WORDID_SIGNED_SECRET,
CSSM_SAMPLE_TYPE_BIOMETRIC = CSSM_WORDID_BIOMETRIC,
CSSM_SAMPLE_TYPE_PROTECTED_BIOMETRIC = CSSM_WORDID_PROTECTED_BIOMETRIC,
CSSM_SAMPLE_TYPE_PROMPTED_BIOMETRIC = CSSM_WORDID_PROMPTED_BIOMETRIC,
CSSM_SAMPLE_TYPE_THRESHOLD = CSSM_WORDID_THRESHOLD
};
typedef struct cssm_sample {
CSSM_LIST TypedSample;
const CSSM_SUBSERVICE_UID *Verifier;
} CSSM_SAMPLE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_SAMPLE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_samplegroup {
uint32 NumberOfSamples;
const CSSM_SAMPLE *Samples;
} CSSM_SAMPLEGROUP __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_SAMPLEGROUP_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef void *( *CSSM_MALLOC)
(CSSM_SIZE size,
void *allocref);
typedef void ( *CSSM_FREE)
(void *memblock,
void *allocref);
typedef void *( *CSSM_REALLOC)
(void *memblock,
CSSM_SIZE size,
void *allocref);
typedef void *( *CSSM_CALLOC)
(uint32 num,
CSSM_SIZE size,
void *allocref);
typedef struct cssm_memory_funcs {
CSSM_MALLOC malloc_func;
CSSM_FREE free_func;
CSSM_REALLOC realloc_func;
CSSM_CALLOC calloc_func;
void *AllocRef;
} CSSM_MEMORY_FUNCS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_MEMORY_FUNCS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef CSSM_MEMORY_FUNCS CSSM_API_MEMORY_FUNCS;
typedef CSSM_API_MEMORY_FUNCS *CSSM_API_MEMORY_FUNCS_PTR;
typedef CSSM_RETURN ( * CSSM_CHALLENGE_CALLBACK)
(const CSSM_LIST *Challenge,
CSSM_SAMPLEGROUP_PTR Response,
void *CallerCtx,
const CSSM_MEMORY_FUNCS *MemFuncs);
typedef uint32 CSSM_CERT_TYPE, *CSSM_CERT_TYPE_PTR;
enum {
CSSM_CERT_UNKNOWN = 0x00,
CSSM_CERT_X_509v1 = 0x01,
CSSM_CERT_X_509v2 = 0x02,
CSSM_CERT_X_509v3 = 0x03,
CSSM_CERT_PGP = 0x04,
CSSM_CERT_SPKI = 0x05,
CSSM_CERT_SDSIv1 = 0x06,
CSSM_CERT_Intel = 0x08,
CSSM_CERT_X_509_ATTRIBUTE = 0x09,
CSSM_CERT_X9_ATTRIBUTE = 0x0A,
CSSM_CERT_TUPLE = 0x0B,
CSSM_CERT_ACL_ENTRY = 0x0C,
CSSM_CERT_MULTIPLE = 0x7FFE,
CSSM_CERT_LAST = 0x7FFF,
CSSM_CL_CUSTOM_CERT_TYPE = 0x08000
};
typedef uint32 CSSM_CERT_ENCODING, *CSSM_CERT_ENCODING_PTR;
enum {
CSSM_CERT_ENCODING_UNKNOWN = 0x00,
CSSM_CERT_ENCODING_CUSTOM = 0x01,
CSSM_CERT_ENCODING_BER = 0x02,
CSSM_CERT_ENCODING_DER = 0x03,
CSSM_CERT_ENCODING_NDR = 0x04,
CSSM_CERT_ENCODING_SEXPR = 0x05,
CSSM_CERT_ENCODING_PGP = 0x06,
CSSM_CERT_ENCODING_MULTIPLE = 0x7FFE,
CSSM_CERT_ENCODING_LAST = 0x7FFF,
CSSM_CL_CUSTOM_CERT_ENCODING = 0x8000
};
typedef struct cssm_encoded_cert {
CSSM_CERT_TYPE CertType;
CSSM_CERT_ENCODING CertEncoding;
CSSM_DATA CertBlob;
} CSSM_ENCODED_CERT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_ENCODED_CERT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_CERT_PARSE_FORMAT, *CSSM_CERT_PARSE_FORMAT_PTR;
enum {
CSSM_CERT_PARSE_FORMAT_NONE = 0x00,
CSSM_CERT_PARSE_FORMAT_CUSTOM = 0x01,
CSSM_CERT_PARSE_FORMAT_SEXPR = 0x02,
CSSM_CERT_PARSE_FORMAT_COMPLEX = 0x03,
CSSM_CERT_PARSE_FORMAT_OID_NAMED = 0x04,
CSSM_CERT_PARSE_FORMAT_TUPLE = 0x05,
CSSM_CERT_PARSE_FORMAT_MULTIPLE = 0x7FFE,
CSSM_CERT_PARSE_FORMAT_LAST = 0x7FFF,
CSSM_CL_CUSTOM_CERT_PARSE_FORMAT = 0x8000
};
typedef struct cssm_parsed_cert {
CSSM_CERT_TYPE CertType;
CSSM_CERT_PARSE_FORMAT ParsedCertFormat;
void *ParsedCert;
} CSSM_PARSED_CERT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_PARSED_CERT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_cert_pair {
CSSM_ENCODED_CERT EncodedCert;
CSSM_PARSED_CERT ParsedCert;
} CSSM_CERT_PAIR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_CERT_PAIR_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_CERTGROUP_TYPE, *CSSM_CERTGROUP_TYPE_PTR;
enum {
CSSM_CERTGROUP_DATA = 0x00,
CSSM_CERTGROUP_ENCODED_CERT = 0x01,
CSSM_CERTGROUP_PARSED_CERT = 0x02,
CSSM_CERTGROUP_CERT_PAIR = 0x03
};
typedef struct cssm_certgroup {
CSSM_CERT_TYPE CertType;
CSSM_CERT_ENCODING CertEncoding;
uint32 NumCerts;
union {
CSSM_DATA_PTR CertList;
CSSM_ENCODED_CERT_PTR EncodedCertList;
CSSM_PARSED_CERT_PTR ParsedCertList;
CSSM_CERT_PAIR_PTR PairCertList;
} GroupList;
CSSM_CERTGROUP_TYPE CertGroupType;
void *Reserved;
} CSSM_CERTGROUP, *CSSM_CERTGROUP_PTR;
typedef struct cssm_base_certs {
CSSM_TP_HANDLE TPHandle;
CSSM_CL_HANDLE CLHandle;
CSSM_CERTGROUP Certs;
} CSSM_BASE_CERTS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_BASE_CERTS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_access_credentials {
CSSM_STRING EntryTag;
CSSM_BASE_CERTS BaseCerts;
CSSM_SAMPLEGROUP Samples;
CSSM_CHALLENGE_CALLBACK Callback;
void *CallerCtx;
} CSSM_ACCESS_CREDENTIALS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_ACCESS_CREDENTIALS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef sint32 CSSM_ACL_SUBJECT_TYPE;
enum {
CSSM_ACL_SUBJECT_TYPE_ANY = CSSM_WORDID__STAR_,
CSSM_ACL_SUBJECT_TYPE_THRESHOLD = CSSM_WORDID_THRESHOLD,
CSSM_ACL_SUBJECT_TYPE_PASSWORD = CSSM_WORDID_PASSWORD,
CSSM_ACL_SUBJECT_TYPE_PROTECTED_PASSWORD = CSSM_WORDID_PROTECTED_PASSWORD,
CSSM_ACL_SUBJECT_TYPE_PROMPTED_PASSWORD = CSSM_WORDID_PROMPTED_PASSWORD,
CSSM_ACL_SUBJECT_TYPE_PUBLIC_KEY = CSSM_WORDID_PUBLIC_KEY,
CSSM_ACL_SUBJECT_TYPE_HASHED_SUBJECT = CSSM_WORDID_HASHED_SUBJECT,
CSSM_ACL_SUBJECT_TYPE_BIOMETRIC = CSSM_WORDID_BIOMETRIC,
CSSM_ACL_SUBJECT_TYPE_PROTECTED_BIOMETRIC = CSSM_WORDID_PROTECTED_BIOMETRIC,
CSSM_ACL_SUBJECT_TYPE_PROMPTED_BIOMETRIC = CSSM_WORDID_PROMPTED_BIOMETRIC,
CSSM_ACL_SUBJECT_TYPE_LOGIN_NAME = CSSM_WORDID_LOGIN_NAME,
CSSM_ACL_SUBJECT_TYPE_EXT_PAM_NAME = CSSM_WORDID_PAM_NAME
};
typedef sint32 CSSM_ACL_AUTHORIZATION_TAG;
enum {
CSSM_ACL_AUTHORIZATION_TAG_VENDOR_DEFINED_START = 0x00010000,
CSSM_ACL_AUTHORIZATION_ANY = CSSM_WORDID__STAR_,
CSSM_ACL_AUTHORIZATION_LOGIN = CSSM_WORDID_LOGIN,
CSSM_ACL_AUTHORIZATION_GENKEY = CSSM_WORDID_GENKEY,
CSSM_ACL_AUTHORIZATION_DELETE = CSSM_WORDID_DELETE,
CSSM_ACL_AUTHORIZATION_EXPORT_WRAPPED = CSSM_WORDID_EXPORT_WRAPPED,
CSSM_ACL_AUTHORIZATION_EXPORT_CLEAR = CSSM_WORDID_EXPORT_CLEAR,
CSSM_ACL_AUTHORIZATION_IMPORT_WRAPPED = CSSM_WORDID_IMPORT_WRAPPED,
CSSM_ACL_AUTHORIZATION_IMPORT_CLEAR = CSSM_WORDID_IMPORT_CLEAR,
CSSM_ACL_AUTHORIZATION_SIGN = CSSM_WORDID_SIGN,
CSSM_ACL_AUTHORIZATION_ENCRYPT = CSSM_WORDID_ENCRYPT,
CSSM_ACL_AUTHORIZATION_DECRYPT = CSSM_WORDID_DECRYPT,
CSSM_ACL_AUTHORIZATION_MAC = CSSM_WORDID_MAC,
CSSM_ACL_AUTHORIZATION_DERIVE = CSSM_WORDID_DERIVE,
CSSM_ACL_AUTHORIZATION_DBS_CREATE = CSSM_WORDID_DBS_CREATE,
CSSM_ACL_AUTHORIZATION_DBS_DELETE = CSSM_WORDID_DBS_DELETE,
CSSM_ACL_AUTHORIZATION_DB_READ = CSSM_WORDID_DB_READ,
CSSM_ACL_AUTHORIZATION_DB_INSERT = CSSM_WORDID_DB_INSERT,
CSSM_ACL_AUTHORIZATION_DB_MODIFY = CSSM_WORDID_DB_MODIFY,
CSSM_ACL_AUTHORIZATION_DB_DELETE = CSSM_WORDID_DB_DELETE
};
typedef struct cssm_authorizationgroup {
uint32 NumberOfAuthTags;
CSSM_ACL_AUTHORIZATION_TAG *AuthTags;
} CSSM_AUTHORIZATIONGROUP __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_AUTHORIZATIONGROUP_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_acl_validity_period {
CSSM_DATA StartDate;
CSSM_DATA EndDate;
} CSSM_ACL_VALIDITY_PERIOD __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_ACL_VALIDITY_PERIOD_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_acl_entry_prototype {
CSSM_LIST TypedSubject;
CSSM_BOOL Delegate;
CSSM_AUTHORIZATIONGROUP Authorization;
CSSM_ACL_VALIDITY_PERIOD TimeRange;
CSSM_STRING EntryTag;
} CSSM_ACL_ENTRY_PROTOTYPE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_ACL_ENTRY_PROTOTYPE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_acl_owner_prototype {
CSSM_LIST TypedSubject;
CSSM_BOOL Delegate;
} CSSM_ACL_OWNER_PROTOTYPE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_ACL_OWNER_PROTOTYPE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef CSSM_RETURN ( * CSSM_ACL_SUBJECT_CALLBACK)
(const CSSM_LIST *SubjectRequest,
CSSM_LIST_PTR SubjectResponse,
void *CallerContext,
const CSSM_MEMORY_FUNCS *MemFuncs);
typedef struct cssm_acl_entry_input {
CSSM_ACL_ENTRY_PROTOTYPE Prototype;
CSSM_ACL_SUBJECT_CALLBACK Callback;
void *CallerContext;
} CSSM_ACL_ENTRY_INPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_ACL_ENTRY_INPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_resource_control_context {
CSSM_ACCESS_CREDENTIALS_PTR AccessCred;
CSSM_ACL_ENTRY_INPUT InitialAclEntry;
} CSSM_RESOURCE_CONTROL_CONTEXT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_RESOURCE_CONTROL_CONTEXT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef CSSM_HANDLE CSSM_ACL_HANDLE;
typedef struct cssm_acl_entry_info {
CSSM_ACL_ENTRY_PROTOTYPE EntryPublicInfo;
CSSM_ACL_HANDLE EntryHandle;
} CSSM_ACL_ENTRY_INFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_ACL_ENTRY_INFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_ACL_EDIT_MODE;
enum {
CSSM_ACL_EDIT_MODE_ADD = 1,
CSSM_ACL_EDIT_MODE_DELETE = 2,
CSSM_ACL_EDIT_MODE_REPLACE = 3
};
typedef struct cssm_acl_edit {
CSSM_ACL_EDIT_MODE EditMode;
CSSM_ACL_HANDLE OldEntryHandle;
const CSSM_ACL_ENTRY_INPUT *NewEntry;
} CSSM_ACL_EDIT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_ACL_EDIT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef void ( *CSSM_PROC_ADDR) ();
typedef CSSM_PROC_ADDR *CSSM_PROC_ADDR_PTR;
typedef struct cssm_func_name_addr {
CSSM_STRING Name;
CSSM_PROC_ADDR Address;
} CSSM_FUNC_NAME_ADDR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_FUNC_NAME_ADDR_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_date {
uint8 Year[4];
uint8 Month[2];
uint8 Day[2];
} CSSM_DATE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DATE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_range {
uint32 Min;
uint32 Max;
} CSSM_RANGE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_RANGE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_query_size_data {
uint32 SizeInputBlock;
uint32 SizeOutputBlock;
} CSSM_QUERY_SIZE_DATA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_QUERY_SIZE_DATA_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_HEADERVERSION;
enum {
CSSM_KEYHEADER_VERSION = 2
};
typedef struct cssm_key_size {
uint32 LogicalKeySizeInBits;
uint32 EffectiveKeySizeInBits;
} CSSM_KEY_SIZE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_KEY_SIZE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_KEYBLOB_TYPE;
enum {
CSSM_KEYBLOB_RAW = 0,
CSSM_KEYBLOB_REFERENCE = 2,
CSSM_KEYBLOB_WRAPPED = 3,
CSSM_KEYBLOB_OTHER = 0xFFFFFFFF
};
typedef uint32 CSSM_KEYBLOB_FORMAT;
enum {
CSSM_KEYBLOB_RAW_FORMAT_NONE = 0,
CSSM_KEYBLOB_RAW_FORMAT_PKCS1 = 1,
CSSM_KEYBLOB_RAW_FORMAT_PKCS3 = 2,
CSSM_KEYBLOB_RAW_FORMAT_MSCAPI = 3,
CSSM_KEYBLOB_RAW_FORMAT_PGP = 4,
CSSM_KEYBLOB_RAW_FORMAT_FIPS186 = 5,
CSSM_KEYBLOB_RAW_FORMAT_BSAFE = 6,
CSSM_KEYBLOB_RAW_FORMAT_CCA = 9,
CSSM_KEYBLOB_RAW_FORMAT_PKCS8 = 10,
CSSM_KEYBLOB_RAW_FORMAT_SPKI = 11,
CSSM_KEYBLOB_RAW_FORMAT_OCTET_STRING = 12,
CSSM_KEYBLOB_RAW_FORMAT_OTHER = 0xFFFFFFFF
};
enum {
CSSM_KEYBLOB_WRAPPED_FORMAT_NONE = 0,
CSSM_KEYBLOB_WRAPPED_FORMAT_PKCS8 = 1,
CSSM_KEYBLOB_WRAPPED_FORMAT_PKCS7 = 2,
CSSM_KEYBLOB_WRAPPED_FORMAT_MSCAPI = 3,
CSSM_KEYBLOB_WRAPPED_FORMAT_OTHER = 0xFFFFFFFF
};
enum {
CSSM_KEYBLOB_REF_FORMAT_INTEGER = 0,
CSSM_KEYBLOB_REF_FORMAT_STRING = 1,
CSSM_KEYBLOB_REF_FORMAT_SPKI = 2,
CSSM_KEYBLOB_REF_FORMAT_OTHER = 0xFFFFFFFF
};
typedef uint32 CSSM_KEYCLASS;
enum {
CSSM_KEYCLASS_PUBLIC_KEY = 0,
CSSM_KEYCLASS_PRIVATE_KEY = 1,
CSSM_KEYCLASS_SESSION_KEY = 2,
CSSM_KEYCLASS_SECRET_PART = 3,
CSSM_KEYCLASS_OTHER = 0xFFFFFFFF
};
typedef uint32 CSSM_KEYATTR_FLAGS;
enum {
CSSM_KEYATTR_RETURN_DEFAULT = 0x00000000,
CSSM_KEYATTR_RETURN_DATA = 0x10000000,
CSSM_KEYATTR_RETURN_REF = 0x20000000,
CSSM_KEYATTR_RETURN_NONE = 0x40000000,
CSSM_KEYATTR_PERMANENT = 0x00000001,
CSSM_KEYATTR_PRIVATE = 0x00000002,
CSSM_KEYATTR_MODIFIABLE = 0x00000004,
CSSM_KEYATTR_SENSITIVE = 0x00000008,
CSSM_KEYATTR_EXTRACTABLE = 0x00000020,
CSSM_KEYATTR_ALWAYS_SENSITIVE = 0x00000010,
CSSM_KEYATTR_NEVER_EXTRACTABLE = 0x00000040
};
typedef uint32 CSSM_KEYUSE;
enum {
CSSM_KEYUSE_ANY = 0x80000000,
CSSM_KEYUSE_ENCRYPT = 0x00000001,
CSSM_KEYUSE_DECRYPT = 0x00000002,
CSSM_KEYUSE_SIGN = 0x00000004,
CSSM_KEYUSE_VERIFY = 0x00000008,
CSSM_KEYUSE_SIGN_RECOVER = 0x00000010,
CSSM_KEYUSE_VERIFY_RECOVER = 0x00000020,
CSSM_KEYUSE_WRAP = 0x00000040,
CSSM_KEYUSE_UNWRAP = 0x00000080,
CSSM_KEYUSE_DERIVE = 0x00000100
};
typedef uint32 CSSM_ALGORITHMS;
enum {
CSSM_ALGID_NONE = 0,
CSSM_ALGID_CUSTOM = CSSM_ALGID_NONE + 1,
CSSM_ALGID_DH = CSSM_ALGID_NONE + 2,
CSSM_ALGID_PH = CSSM_ALGID_NONE + 3,
CSSM_ALGID_KEA = CSSM_ALGID_NONE + 4,
CSSM_ALGID_MD2 = CSSM_ALGID_NONE + 5,
CSSM_ALGID_MD4 = CSSM_ALGID_NONE + 6,
CSSM_ALGID_MD5 = CSSM_ALGID_NONE + 7,
CSSM_ALGID_SHA1 = CSSM_ALGID_NONE + 8,
CSSM_ALGID_NHASH = CSSM_ALGID_NONE + 9,
CSSM_ALGID_HAVAL = CSSM_ALGID_NONE + 10,
CSSM_ALGID_RIPEMD = CSSM_ALGID_NONE + 11,
CSSM_ALGID_IBCHASH = CSSM_ALGID_NONE + 12,
CSSM_ALGID_RIPEMAC = CSSM_ALGID_NONE + 13,
CSSM_ALGID_DES = CSSM_ALGID_NONE + 14,
CSSM_ALGID_DESX = CSSM_ALGID_NONE + 15,
CSSM_ALGID_RDES = CSSM_ALGID_NONE + 16,
CSSM_ALGID_3DES_3KEY_EDE = CSSM_ALGID_NONE + 17,
CSSM_ALGID_3DES_2KEY_EDE = CSSM_ALGID_NONE + 18,
CSSM_ALGID_3DES_1KEY_EEE = CSSM_ALGID_NONE + 19,
CSSM_ALGID_3DES_3KEY = CSSM_ALGID_3DES_3KEY_EDE,
CSSM_ALGID_3DES_3KEY_EEE = CSSM_ALGID_NONE + 20,
CSSM_ALGID_3DES_2KEY = CSSM_ALGID_3DES_2KEY_EDE,
CSSM_ALGID_3DES_2KEY_EEE = CSSM_ALGID_NONE + 21,
CSSM_ALGID_3DES_1KEY = CSSM_ALGID_3DES_3KEY_EEE,
CSSM_ALGID_IDEA = CSSM_ALGID_NONE + 22,
CSSM_ALGID_RC2 = CSSM_ALGID_NONE + 23,
CSSM_ALGID_RC5 = CSSM_ALGID_NONE + 24,
CSSM_ALGID_RC4 = CSSM_ALGID_NONE + 25,
CSSM_ALGID_SEAL = CSSM_ALGID_NONE + 26,
CSSM_ALGID_CAST = CSSM_ALGID_NONE + 27,
CSSM_ALGID_BLOWFISH = CSSM_ALGID_NONE + 28,
CSSM_ALGID_SKIPJACK = CSSM_ALGID_NONE + 29,
CSSM_ALGID_LUCIFER = CSSM_ALGID_NONE + 30,
CSSM_ALGID_MADRYGA = CSSM_ALGID_NONE + 31,
CSSM_ALGID_FEAL = CSSM_ALGID_NONE + 32,
CSSM_ALGID_REDOC = CSSM_ALGID_NONE + 33,
CSSM_ALGID_REDOC3 = CSSM_ALGID_NONE + 34,
CSSM_ALGID_LOKI = CSSM_ALGID_NONE + 35,
CSSM_ALGID_KHUFU = CSSM_ALGID_NONE + 36,
CSSM_ALGID_KHAFRE = CSSM_ALGID_NONE + 37,
CSSM_ALGID_MMB = CSSM_ALGID_NONE + 38,
CSSM_ALGID_GOST = CSSM_ALGID_NONE + 39,
CSSM_ALGID_SAFER = CSSM_ALGID_NONE + 40,
CSSM_ALGID_CRAB = CSSM_ALGID_NONE + 41,
CSSM_ALGID_RSA = CSSM_ALGID_NONE + 42,
CSSM_ALGID_DSA = CSSM_ALGID_NONE + 43,
CSSM_ALGID_MD5WithRSA = CSSM_ALGID_NONE + 44,
CSSM_ALGID_MD2WithRSA = CSSM_ALGID_NONE + 45,
CSSM_ALGID_ElGamal = CSSM_ALGID_NONE + 46,
CSSM_ALGID_MD2Random = CSSM_ALGID_NONE + 47,
CSSM_ALGID_MD5Random = CSSM_ALGID_NONE + 48,
CSSM_ALGID_SHARandom = CSSM_ALGID_NONE + 49,
CSSM_ALGID_DESRandom = CSSM_ALGID_NONE + 50,
CSSM_ALGID_SHA1WithRSA = CSSM_ALGID_NONE + 51,
CSSM_ALGID_CDMF = CSSM_ALGID_NONE + 52,
CSSM_ALGID_CAST3 = CSSM_ALGID_NONE + 53,
CSSM_ALGID_CAST5 = CSSM_ALGID_NONE + 54,
CSSM_ALGID_GenericSecret = CSSM_ALGID_NONE + 55,
CSSM_ALGID_ConcatBaseAndKey = CSSM_ALGID_NONE + 56,
CSSM_ALGID_ConcatKeyAndBase = CSSM_ALGID_NONE + 57,
CSSM_ALGID_ConcatBaseAndData = CSSM_ALGID_NONE + 58,
CSSM_ALGID_ConcatDataAndBase = CSSM_ALGID_NONE + 59,
CSSM_ALGID_XORBaseAndData = CSSM_ALGID_NONE + 60,
CSSM_ALGID_ExtractFromKey = CSSM_ALGID_NONE + 61,
CSSM_ALGID_SSL3PreMasterGen = CSSM_ALGID_NONE + 62,
CSSM_ALGID_SSL3MasterDerive = CSSM_ALGID_NONE + 63,
CSSM_ALGID_SSL3KeyAndMacDerive = CSSM_ALGID_NONE + 64,
CSSM_ALGID_SSL3MD5_MAC = CSSM_ALGID_NONE + 65,
CSSM_ALGID_SSL3SHA1_MAC = CSSM_ALGID_NONE + 66,
CSSM_ALGID_PKCS5_PBKDF1_MD5 = CSSM_ALGID_NONE + 67,
CSSM_ALGID_PKCS5_PBKDF1_MD2 = CSSM_ALGID_NONE + 68,
CSSM_ALGID_PKCS5_PBKDF1_SHA1 = CSSM_ALGID_NONE + 69,
CSSM_ALGID_WrapLynks = CSSM_ALGID_NONE + 70,
CSSM_ALGID_WrapSET_OAEP = CSSM_ALGID_NONE + 71,
CSSM_ALGID_BATON = CSSM_ALGID_NONE + 72,
CSSM_ALGID_ECDSA = CSSM_ALGID_NONE + 73,
CSSM_ALGID_MAYFLY = CSSM_ALGID_NONE + 74,
CSSM_ALGID_JUNIPER = CSSM_ALGID_NONE + 75,
CSSM_ALGID_FASTHASH = CSSM_ALGID_NONE + 76,
CSSM_ALGID_3DES = CSSM_ALGID_NONE + 77,
CSSM_ALGID_SSL3MD5 = CSSM_ALGID_NONE + 78,
CSSM_ALGID_SSL3SHA1 = CSSM_ALGID_NONE + 79,
CSSM_ALGID_FortezzaTimestamp = CSSM_ALGID_NONE + 80,
CSSM_ALGID_SHA1WithDSA = CSSM_ALGID_NONE + 81,
CSSM_ALGID_SHA1WithECDSA = CSSM_ALGID_NONE + 82,
CSSM_ALGID_DSA_BSAFE = CSSM_ALGID_NONE + 83,
CSSM_ALGID_ECDH = CSSM_ALGID_NONE + 84,
CSSM_ALGID_ECMQV = CSSM_ALGID_NONE + 85,
CSSM_ALGID_PKCS12_SHA1_PBE = CSSM_ALGID_NONE + 86,
CSSM_ALGID_ECNRA = CSSM_ALGID_NONE + 87,
CSSM_ALGID_SHA1WithECNRA = CSSM_ALGID_NONE + 88,
CSSM_ALGID_ECES = CSSM_ALGID_NONE + 89,
CSSM_ALGID_ECAES = CSSM_ALGID_NONE + 90,
CSSM_ALGID_SHA1HMAC = CSSM_ALGID_NONE + 91,
CSSM_ALGID_FIPS186Random = CSSM_ALGID_NONE + 92,
CSSM_ALGID_ECC = CSSM_ALGID_NONE + 93,
CSSM_ALGID_MQV = CSSM_ALGID_NONE + 94,
CSSM_ALGID_NRA = CSSM_ALGID_NONE + 95,
CSSM_ALGID_IntelPlatformRandom = CSSM_ALGID_NONE + 96,
CSSM_ALGID_UTC = CSSM_ALGID_NONE + 97,
CSSM_ALGID_HAVAL3 = CSSM_ALGID_NONE + 98,
CSSM_ALGID_HAVAL4 = CSSM_ALGID_NONE + 99,
CSSM_ALGID_HAVAL5 = CSSM_ALGID_NONE + 100,
CSSM_ALGID_TIGER = CSSM_ALGID_NONE + 101,
CSSM_ALGID_MD5HMAC = CSSM_ALGID_NONE + 102,
CSSM_ALGID_PKCS5_PBKDF2 = CSSM_ALGID_NONE + 103,
CSSM_ALGID_RUNNING_COUNTER = CSSM_ALGID_NONE + 104,
CSSM_ALGID_LAST = CSSM_ALGID_NONE + 0x7FFFFFFF,
CSSM_ALGID_VENDOR_DEFINED = CSSM_ALGID_NONE + 0x80000000
};
typedef uint32 CSSM_ENCRYPT_MODE;
enum {
CSSM_ALGMODE_NONE = 0,
CSSM_ALGMODE_CUSTOM = CSSM_ALGMODE_NONE + 1,
CSSM_ALGMODE_ECB = CSSM_ALGMODE_NONE + 2,
CSSM_ALGMODE_ECBPad = CSSM_ALGMODE_NONE + 3,
CSSM_ALGMODE_CBC = CSSM_ALGMODE_NONE + 4,
CSSM_ALGMODE_CBC_IV8 = CSSM_ALGMODE_NONE + 5,
CSSM_ALGMODE_CBCPadIV8 = CSSM_ALGMODE_NONE + 6,
CSSM_ALGMODE_CFB = CSSM_ALGMODE_NONE + 7,
CSSM_ALGMODE_CFB_IV8 = CSSM_ALGMODE_NONE + 8,
CSSM_ALGMODE_CFBPadIV8 = CSSM_ALGMODE_NONE + 9,
CSSM_ALGMODE_OFB = CSSM_ALGMODE_NONE + 10,
CSSM_ALGMODE_OFB_IV8 = CSSM_ALGMODE_NONE + 11,
CSSM_ALGMODE_OFBPadIV8 = CSSM_ALGMODE_NONE + 12,
CSSM_ALGMODE_COUNTER = CSSM_ALGMODE_NONE + 13,
CSSM_ALGMODE_BC = CSSM_ALGMODE_NONE + 14,
CSSM_ALGMODE_PCBC = CSSM_ALGMODE_NONE + 15,
CSSM_ALGMODE_CBCC = CSSM_ALGMODE_NONE + 16,
CSSM_ALGMODE_OFBNLF = CSSM_ALGMODE_NONE + 17,
CSSM_ALGMODE_PBC = CSSM_ALGMODE_NONE + 18,
CSSM_ALGMODE_PFB = CSSM_ALGMODE_NONE + 19,
CSSM_ALGMODE_CBCPD = CSSM_ALGMODE_NONE + 20,
CSSM_ALGMODE_PUBLIC_KEY = CSSM_ALGMODE_NONE + 21,
CSSM_ALGMODE_PRIVATE_KEY = CSSM_ALGMODE_NONE + 22,
CSSM_ALGMODE_SHUFFLE = CSSM_ALGMODE_NONE + 23,
CSSM_ALGMODE_ECB64 = CSSM_ALGMODE_NONE + 24,
CSSM_ALGMODE_CBC64 = CSSM_ALGMODE_NONE + 25,
CSSM_ALGMODE_OFB64 = CSSM_ALGMODE_NONE + 26,
CSSM_ALGMODE_CFB32 = CSSM_ALGMODE_NONE + 28,
CSSM_ALGMODE_CFB16 = CSSM_ALGMODE_NONE + 29,
CSSM_ALGMODE_CFB8 = CSSM_ALGMODE_NONE + 30,
CSSM_ALGMODE_WRAP = CSSM_ALGMODE_NONE + 31,
CSSM_ALGMODE_PRIVATE_WRAP = CSSM_ALGMODE_NONE + 32,
CSSM_ALGMODE_RELAYX = CSSM_ALGMODE_NONE + 33,
CSSM_ALGMODE_ECB128 = CSSM_ALGMODE_NONE + 34,
CSSM_ALGMODE_ECB96 = CSSM_ALGMODE_NONE + 35,
CSSM_ALGMODE_CBC128 = CSSM_ALGMODE_NONE + 36,
CSSM_ALGMODE_OAEP_HASH = CSSM_ALGMODE_NONE + 37,
CSSM_ALGMODE_PKCS1_EME_V15 = CSSM_ALGMODE_NONE + 38,
CSSM_ALGMODE_PKCS1_EME_OAEP = CSSM_ALGMODE_NONE + 39,
CSSM_ALGMODE_PKCS1_EMSA_V15 = CSSM_ALGMODE_NONE + 40,
CSSM_ALGMODE_ISO_9796 = CSSM_ALGMODE_NONE + 41,
CSSM_ALGMODE_X9_31 = CSSM_ALGMODE_NONE + 42,
CSSM_ALGMODE_LAST = CSSM_ALGMODE_NONE + 0x7FFFFFFF,
CSSM_ALGMODE_VENDOR_DEFINED = CSSM_ALGMODE_NONE + 0x80000000
};
typedef struct cssm_keyheader {
CSSM_HEADERVERSION HeaderVersion;
CSSM_GUID CspId;
CSSM_KEYBLOB_TYPE BlobType;
CSSM_KEYBLOB_FORMAT Format;
CSSM_ALGORITHMS AlgorithmId;
CSSM_KEYCLASS KeyClass;
uint32 LogicalKeySizeInBits;
CSSM_KEYATTR_FLAGS KeyAttr;
CSSM_KEYUSE KeyUsage;
CSSM_DATE StartDate;
CSSM_DATE EndDate;
CSSM_ALGORITHMS WrapAlgorithmId;
CSSM_ENCRYPT_MODE WrapMode;
uint32 Reserved;
} CSSM_KEYHEADER __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_KEYHEADER_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_key {
CSSM_KEYHEADER KeyHeader;
CSSM_DATA KeyData;
} CSSM_KEY __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_KEY_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef CSSM_KEY CSSM_WRAP_KEY, *CSSM_WRAP_KEY_PTR;
typedef uint32 CSSM_CSPTYPE;
enum {
CSSM_CSP_SOFTWARE = 1,
CSSM_CSP_HARDWARE = CSSM_CSP_SOFTWARE + 1,
CSSM_CSP_HYBRID = CSSM_CSP_SOFTWARE + 2
};
typedef struct cssm_dl_db_handle {
CSSM_DL_HANDLE DLHandle;
CSSM_DB_HANDLE DBHandle;
} CSSM_DL_DB_HANDLE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DL_DB_HANDLE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_CONTEXT_TYPE;
enum {
CSSM_ALGCLASS_NONE = 0,
CSSM_ALGCLASS_CUSTOM = CSSM_ALGCLASS_NONE + 1,
CSSM_ALGCLASS_SIGNATURE = CSSM_ALGCLASS_NONE + 2,
CSSM_ALGCLASS_SYMMETRIC = CSSM_ALGCLASS_NONE + 3,
CSSM_ALGCLASS_DIGEST = CSSM_ALGCLASS_NONE + 4,
CSSM_ALGCLASS_RANDOMGEN = CSSM_ALGCLASS_NONE + 5,
CSSM_ALGCLASS_UNIQUEGEN = CSSM_ALGCLASS_NONE + 6,
CSSM_ALGCLASS_MAC = CSSM_ALGCLASS_NONE + 7,
CSSM_ALGCLASS_ASYMMETRIC = CSSM_ALGCLASS_NONE + 8,
CSSM_ALGCLASS_KEYGEN = CSSM_ALGCLASS_NONE + 9,
CSSM_ALGCLASS_DERIVEKEY = CSSM_ALGCLASS_NONE + 10
};
enum {
CSSM_ATTRIBUTE_DATA_NONE = 0x00000000,
CSSM_ATTRIBUTE_DATA_UINT32 = 0x10000000,
CSSM_ATTRIBUTE_DATA_CSSM_DATA = 0x20000000,
CSSM_ATTRIBUTE_DATA_CRYPTO_DATA = 0x30000000,
CSSM_ATTRIBUTE_DATA_KEY = 0x40000000,
CSSM_ATTRIBUTE_DATA_STRING = 0x50000000,
CSSM_ATTRIBUTE_DATA_DATE = 0x60000000,
CSSM_ATTRIBUTE_DATA_RANGE = 0x70000000,
CSSM_ATTRIBUTE_DATA_ACCESS_CREDENTIALS = 0x80000000,
CSSM_ATTRIBUTE_DATA_VERSION = 0x01000000,
CSSM_ATTRIBUTE_DATA_DL_DB_HANDLE = 0x02000000,
CSSM_ATTRIBUTE_DATA_KR_PROFILE = 0x03000000,
CSSM_ATTRIBUTE_TYPE_MASK = 0xFF000000
};
typedef uint32 CSSM_ATTRIBUTE_TYPE;
enum {
CSSM_ATTRIBUTE_NONE = 0,
CSSM_ATTRIBUTE_CUSTOM = CSSM_ATTRIBUTE_DATA_CSSM_DATA | 1,
CSSM_ATTRIBUTE_DESCRIPTION = CSSM_ATTRIBUTE_DATA_STRING | 2,
CSSM_ATTRIBUTE_KEY = CSSM_ATTRIBUTE_DATA_KEY | 3,
CSSM_ATTRIBUTE_INIT_VECTOR = CSSM_ATTRIBUTE_DATA_CSSM_DATA | 4,
CSSM_ATTRIBUTE_SALT = CSSM_ATTRIBUTE_DATA_CSSM_DATA | 5,
CSSM_ATTRIBUTE_PADDING = CSSM_ATTRIBUTE_DATA_UINT32 | 6,
CSSM_ATTRIBUTE_RANDOM = CSSM_ATTRIBUTE_DATA_CSSM_DATA | 7,
CSSM_ATTRIBUTE_SEED = CSSM_ATTRIBUTE_DATA_CRYPTO_DATA | 8,
CSSM_ATTRIBUTE_PASSPHRASE = CSSM_ATTRIBUTE_DATA_CRYPTO_DATA | 9,
CSSM_ATTRIBUTE_KEY_LENGTH = CSSM_ATTRIBUTE_DATA_UINT32 | 10,
CSSM_ATTRIBUTE_KEY_LENGTH_RANGE = CSSM_ATTRIBUTE_DATA_RANGE | 11,
CSSM_ATTRIBUTE_BLOCK_SIZE = CSSM_ATTRIBUTE_DATA_UINT32 | 12,
CSSM_ATTRIBUTE_OUTPUT_SIZE = CSSM_ATTRIBUTE_DATA_UINT32 | 13,
CSSM_ATTRIBUTE_ROUNDS = CSSM_ATTRIBUTE_DATA_UINT32 | 14,
CSSM_ATTRIBUTE_IV_SIZE = CSSM_ATTRIBUTE_DATA_UINT32 | 15,
CSSM_ATTRIBUTE_ALG_PARAMS = CSSM_ATTRIBUTE_DATA_CSSM_DATA | 16,
CSSM_ATTRIBUTE_LABEL = CSSM_ATTRIBUTE_DATA_CSSM_DATA | 17,
CSSM_ATTRIBUTE_KEY_TYPE = CSSM_ATTRIBUTE_DATA_UINT32 | 18,
CSSM_ATTRIBUTE_MODE = CSSM_ATTRIBUTE_DATA_UINT32 | 19,
CSSM_ATTRIBUTE_EFFECTIVE_BITS = CSSM_ATTRIBUTE_DATA_UINT32 | 20,
CSSM_ATTRIBUTE_START_DATE = CSSM_ATTRIBUTE_DATA_DATE | 21,
CSSM_ATTRIBUTE_END_DATE = CSSM_ATTRIBUTE_DATA_DATE | 22,
CSSM_ATTRIBUTE_KEYUSAGE = CSSM_ATTRIBUTE_DATA_UINT32 | 23,
CSSM_ATTRIBUTE_KEYATTR = CSSM_ATTRIBUTE_DATA_UINT32 | 24,
CSSM_ATTRIBUTE_VERSION = CSSM_ATTRIBUTE_DATA_VERSION | 25,
CSSM_ATTRIBUTE_PRIME = CSSM_ATTRIBUTE_DATA_CSSM_DATA | 26,
CSSM_ATTRIBUTE_BASE = CSSM_ATTRIBUTE_DATA_CSSM_DATA | 27,
CSSM_ATTRIBUTE_SUBPRIME = CSSM_ATTRIBUTE_DATA_CSSM_DATA | 28,
CSSM_ATTRIBUTE_ALG_ID = CSSM_ATTRIBUTE_DATA_UINT32 | 29,
CSSM_ATTRIBUTE_ITERATION_COUNT = CSSM_ATTRIBUTE_DATA_UINT32 | 30,
CSSM_ATTRIBUTE_ROUNDS_RANGE = CSSM_ATTRIBUTE_DATA_RANGE | 31,
CSSM_ATTRIBUTE_KRPROFILE_LOCAL = CSSM_ATTRIBUTE_DATA_KR_PROFILE | 32,
CSSM_ATTRIBUTE_KRPROFILE_REMOTE = CSSM_ATTRIBUTE_DATA_KR_PROFILE | 33,
CSSM_ATTRIBUTE_CSP_HANDLE = CSSM_ATTRIBUTE_DATA_UINT32 | 34,
CSSM_ATTRIBUTE_DL_DB_HANDLE = CSSM_ATTRIBUTE_DATA_DL_DB_HANDLE | 35,
CSSM_ATTRIBUTE_ACCESS_CREDENTIALS = CSSM_ATTRIBUTE_DATA_ACCESS_CREDENTIALS | 36,
CSSM_ATTRIBUTE_PUBLIC_KEY_FORMAT = CSSM_ATTRIBUTE_DATA_UINT32 | 37,
CSSM_ATTRIBUTE_PRIVATE_KEY_FORMAT = CSSM_ATTRIBUTE_DATA_UINT32 | 38,
CSSM_ATTRIBUTE_SYMMETRIC_KEY_FORMAT=CSSM_ATTRIBUTE_DATA_UINT32 | 39,
CSSM_ATTRIBUTE_WRAPPED_KEY_FORMAT = CSSM_ATTRIBUTE_DATA_UINT32 | 40
};
typedef uint32 CSSM_PADDING;
enum {
CSSM_PADDING_NONE = 0,
CSSM_PADDING_CUSTOM = CSSM_PADDING_NONE + 1,
CSSM_PADDING_ZERO = CSSM_PADDING_NONE + 2,
CSSM_PADDING_ONE = CSSM_PADDING_NONE + 3,
CSSM_PADDING_ALTERNATE = CSSM_PADDING_NONE + 4,
CSSM_PADDING_FF = CSSM_PADDING_NONE + 5,
CSSM_PADDING_PKCS5 = CSSM_PADDING_NONE + 6,
CSSM_PADDING_PKCS7 = CSSM_PADDING_NONE + 7,
CSSM_PADDING_CIPHERSTEALING = CSSM_PADDING_NONE + 8,
CSSM_PADDING_RANDOM = CSSM_PADDING_NONE + 9,
CSSM_PADDING_PKCS1 = CSSM_PADDING_NONE + 10,
CSSM_PADDING_VENDOR_DEFINED = CSSM_PADDING_NONE + 0x80000000
};
typedef CSSM_ALGORITHMS CSSM_KEY_TYPE;
typedef struct cssm_context_attribute {
CSSM_ATTRIBUTE_TYPE AttributeType;
uint32 AttributeLength;
union cssm_context_attribute_value {
char *String;
uint32 Uint32;
CSSM_ACCESS_CREDENTIALS_PTR AccessCredentials;
CSSM_KEY_PTR Key;
CSSM_DATA_PTR Data;
CSSM_PADDING Padding;
CSSM_DATE_PTR Date;
CSSM_RANGE_PTR Range;
CSSM_CRYPTO_DATA_PTR CryptoData;
CSSM_VERSION_PTR Version;
CSSM_DL_DB_HANDLE_PTR DLDBHandle;
struct cssm_kr_profile *KRProfile;
} Attribute;
} CSSM_CONTEXT_ATTRIBUTE, *CSSM_CONTEXT_ATTRIBUTE_PTR;
typedef struct cssm_context {
CSSM_CONTEXT_TYPE ContextType;
CSSM_ALGORITHMS AlgorithmType;
uint32 NumberOfAttributes;
CSSM_CONTEXT_ATTRIBUTE_PTR ContextAttributes;
CSSM_CSP_HANDLE CSPHandle;
CSSM_BOOL Privileged;
uint32 EncryptionProhibited;
uint32 WorkFactor;
uint32 Reserved;
} CSSM_CONTEXT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_CONTEXT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_SC_FLAGS;
enum {
CSSM_CSP_TOK_RNG = 0x00000001,
CSSM_CSP_TOK_CLOCK_EXISTS = 0x00000040
};
typedef uint32 CSSM_CSP_READER_FLAGS;
enum {
CSSM_CSP_RDR_TOKENPRESENT = 0x00000001,
CSSM_CSP_RDR_EXISTS = 0x00000002,
CSSM_CSP_RDR_HW = 0x00000004
};
typedef uint32 CSSM_CSP_FLAGS;
enum {
CSSM_CSP_TOK_WRITE_PROTECTED = 0x00000002,
CSSM_CSP_TOK_LOGIN_REQUIRED = 0x00000004,
CSSM_CSP_TOK_USER_PIN_INITIALIZED = 0x00000008,
CSSM_CSP_TOK_PROT_AUTHENTICATION = 0x00000100,
CSSM_CSP_TOK_USER_PIN_EXPIRED = 0x00100000,
CSSM_CSP_TOK_SESSION_KEY_PASSWORD = 0x00200000,
CSSM_CSP_TOK_PRIVATE_KEY_PASSWORD = 0x00400000,
CSSM_CSP_STORES_PRIVATE_KEYS = 0x01000000,
CSSM_CSP_STORES_PUBLIC_KEYS = 0x02000000,
CSSM_CSP_STORES_SESSION_KEYS = 0x04000000,
CSSM_CSP_STORES_CERTIFICATES = 0x08000000,
CSSM_CSP_STORES_GENERIC = 0x10000000
};
typedef uint32 CSSM_PKCS_OAEP_MGF;
enum {
CSSM_PKCS_OAEP_MGF_NONE = 0,
CSSM_PKCS_OAEP_MGF1_SHA1 = CSSM_PKCS_OAEP_MGF_NONE + 1,
CSSM_PKCS_OAEP_MGF1_MD5 = CSSM_PKCS_OAEP_MGF_NONE + 2
};
typedef uint32 CSSM_PKCS_OAEP_PSOURCE;
enum {
CSSM_PKCS_OAEP_PSOURCE_NONE = 0,
CSSM_PKCS_OAEP_PSOURCE_Pspecified = CSSM_PKCS_OAEP_PSOURCE_NONE + 1
};
typedef struct cssm_pkcs1_oaep_params {
uint32 HashAlgorithm;
CSSM_DATA HashParams;
CSSM_PKCS_OAEP_MGF MGF;
CSSM_DATA MGFParams;
CSSM_PKCS_OAEP_PSOURCE PSource;
CSSM_DATA PSourceParams;
} CSSM_PKCS1_OAEP_PARAMS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_PKCS1_OAEP_PARAMS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_csp_operational_statistics {
CSSM_BOOL UserAuthenticated;
CSSM_CSP_FLAGS DeviceFlags;
uint32 TokenMaxSessionCount;
uint32 TokenOpenedSessionCount;
uint32 TokenMaxRWSessionCount;
uint32 TokenOpenedRWSessionCount;
uint32 TokenTotalPublicMem;
uint32 TokenFreePublicMem;
uint32 TokenTotalPrivateMem;
uint32 TokenFreePrivateMem;
} CSSM_CSP_OPERATIONAL_STATISTICS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_CSP_OPERATIONAL_STATISTICS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
enum {
CSSM_VALUE_NOT_AVAILABLE = -1
};
typedef struct cssm_pkcs5_pbkdf1_params {
CSSM_DATA Passphrase;
CSSM_DATA InitVector;
} CSSM_PKCS5_PBKDF1_PARAMS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_PKCS5_PBKDF1_PARAMS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_PKCS5_PBKDF2_PRF;
enum {
CSSM_PKCS5_PBKDF2_PRF_HMAC_SHA1 = 0
};
typedef struct cssm_pkcs5_pbkdf2_params {
CSSM_DATA Passphrase;
CSSM_PKCS5_PBKDF2_PRF PseudoRandomFunction;
} CSSM_PKCS5_PBKDF2_PARAMS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_PKCS5_PBKDF2_PARAMS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_kea_derive_params {
CSSM_DATA Rb;
CSSM_DATA Yb;
} CSSM_KEA_DERIVE_PARAMS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_KEA_DERIVE_PARAMS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tp_authority_id {
CSSM_DATA *AuthorityCert;
CSSM_NET_ADDRESS_PTR AuthorityLocation;
} CSSM_TP_AUTHORITY_ID __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_AUTHORITY_ID_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_TP_AUTHORITY_REQUEST_TYPE, *CSSM_TP_AUTHORITY_REQUEST_TYPE_PTR;
enum {
CSSM_TP_AUTHORITY_REQUEST_CERTISSUE = 0x01,
CSSM_TP_AUTHORITY_REQUEST_CERTREVOKE = 0x02,
CSSM_TP_AUTHORITY_REQUEST_CERTSUSPEND = 0x03,
CSSM_TP_AUTHORITY_REQUEST_CERTRESUME = 0x04,
CSSM_TP_AUTHORITY_REQUEST_CERTVERIFY = 0x05,
CSSM_TP_AUTHORITY_REQUEST_CERTNOTARIZE = 0x06,
CSSM_TP_AUTHORITY_REQUEST_CERTUSERECOVER = 0x07,
CSSM_TP_AUTHORITY_REQUEST_CRLISSUE = 0x100
};
typedef CSSM_RETURN ( * CSSM_TP_VERIFICATION_RESULTS_CALLBACK)
(CSSM_MODULE_HANDLE ModuleHandle,
void *CallerCtx,
CSSM_DATA_PTR VerifiedCert);
typedef CSSM_DATA CSSM_OID, *CSSM_OID_PTR;
typedef struct cssm_field {
CSSM_OID FieldOid;
CSSM_DATA FieldValue;
} CSSM_FIELD __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_FIELD_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tp_policyinfo {
uint32 NumberOfPolicyIds;
CSSM_FIELD_PTR PolicyIds;
void *PolicyControl;
} CSSM_TP_POLICYINFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_POLICYINFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_TP_SERVICES;
enum {
CSSM_TP_KEY_ARCHIVE = 0x0001,
CSSM_TP_CERT_PUBLISH = 0x0002,
CSSM_TP_CERT_NOTIFY_RENEW = 0x0004,
CSSM_TP_CERT_DIR_UPDATE = 0x0008,
CSSM_TP_CRL_DISTRIBUTE = 0x0010
};
typedef uint32 CSSM_TP_ACTION;
enum {
CSSM_TP_ACTION_DEFAULT = 0
};
typedef uint32 CSSM_TP_STOP_ON;
enum {
CSSM_TP_STOP_ON_POLICY = 0,
CSSM_TP_STOP_ON_NONE = 1,
CSSM_TP_STOP_ON_FIRST_PASS = 2,
CSSM_TP_STOP_ON_FIRST_FAIL = 3
};
typedef char *CSSM_TIMESTRING;
typedef struct cssm_dl_db_list {
uint32 NumHandles;
CSSM_DL_DB_HANDLE_PTR DLDBHandle;
} CSSM_DL_DB_LIST __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DL_DB_LIST_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tp_callerauth_context {
CSSM_TP_POLICYINFO Policy;
CSSM_TIMESTRING VerifyTime;
CSSM_TP_STOP_ON VerificationAbortOn;
CSSM_TP_VERIFICATION_RESULTS_CALLBACK CallbackWithVerifiedCert;
uint32 NumberOfAnchorCerts;
CSSM_DATA_PTR AnchorCerts;
CSSM_DL_DB_LIST_PTR DBList;
CSSM_ACCESS_CREDENTIALS_PTR CallerCredentials;
} CSSM_TP_CALLERAUTH_CONTEXT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CALLERAUTH_CONTEXT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_CRL_PARSE_FORMAT, * CSSM_CRL_PARSE_FORMAT_PTR;
enum {
CSSM_CRL_PARSE_FORMAT_NONE = 0x00,
CSSM_CRL_PARSE_FORMAT_CUSTOM = 0x01,
CSSM_CRL_PARSE_FORMAT_SEXPR = 0x02,
CSSM_CRL_PARSE_FORMAT_COMPLEX = 0x03,
CSSM_CRL_PARSE_FORMAT_OID_NAMED = 0x04,
CSSM_CRL_PARSE_FORMAT_TUPLE = 0x05,
CSSM_CRL_PARSE_FORMAT_MULTIPLE = 0x7FFE,
CSSM_CRL_PARSE_FORMAT_LAST = 0x7FFF,
CSSM_CL_CUSTOM_CRL_PARSE_FORMAT = 0x8000
};
typedef uint32 CSSM_CRL_TYPE, *CSSM_CRL_TYPE_PTR;
enum {
CSSM_CRL_TYPE_UNKNOWN = 0x00,
CSSM_CRL_TYPE_X_509v1 = 0x01,
CSSM_CRL_TYPE_X_509v2 = 0x02,
CSSM_CRL_TYPE_SPKI = 0x03,
CSSM_CRL_TYPE_MULTIPLE = 0x7FFE
};
typedef uint32 CSSM_CRL_ENCODING, *CSSM_CRL_ENCODING_PTR;
enum {
CSSM_CRL_ENCODING_UNKNOWN = 0x00,
CSSM_CRL_ENCODING_CUSTOM = 0x01,
CSSM_CRL_ENCODING_BER = 0x02,
CSSM_CRL_ENCODING_DER = 0x03,
CSSM_CRL_ENCODING_BLOOM = 0x04,
CSSM_CRL_ENCODING_SEXPR = 0x05,
CSSM_CRL_ENCODING_MULTIPLE = 0x7FFE
};
typedef struct cssm_encoded_crl {
CSSM_CRL_TYPE CrlType;
CSSM_CRL_ENCODING CrlEncoding;
CSSM_DATA CrlBlob;
} CSSM_ENCODED_CRL __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_ENCODED_CRL_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_parsed_crl {
CSSM_CRL_TYPE CrlType;
CSSM_CRL_PARSE_FORMAT ParsedCrlFormat;
void *ParsedCrl;
} CSSM_PARSED_CRL __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_PARSED_CRL_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_crl_pair {
CSSM_ENCODED_CRL EncodedCrl;
CSSM_PARSED_CRL ParsedCrl;
} CSSM_CRL_PAIR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_CRL_PAIR_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_CRLGROUP_TYPE, * CSSM_CRLGROUP_TYPE_PTR;
enum {
CSSM_CRLGROUP_DATA = 0x00,
CSSM_CRLGROUP_ENCODED_CRL = 0x01,
CSSM_CRLGROUP_PARSED_CRL = 0x02,
CSSM_CRLGROUP_CRL_PAIR = 0x03
};
typedef struct cssm_crlgroup {
CSSM_CRL_TYPE CrlType;
CSSM_CRL_ENCODING CrlEncoding;
uint32 NumberOfCrls;
union {
CSSM_DATA_PTR CrlList;
CSSM_ENCODED_CRL_PTR EncodedCrlList;
CSSM_PARSED_CRL_PTR ParsedCrlList;
CSSM_CRL_PAIR_PTR PairCrlList;
} GroupCrlList;
CSSM_CRLGROUP_TYPE CrlGroupType;
} CSSM_CRLGROUP, *CSSM_CRLGROUP_PTR;
typedef struct cssm_fieldgroup {
int NumberOfFields;
CSSM_FIELD_PTR Fields;
} CSSM_FIELDGROUP __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_FIELDGROUP_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_EVIDENCE_FORM;
enum {
CSSM_EVIDENCE_FORM_UNSPECIFIC = 0x0,
CSSM_EVIDENCE_FORM_CERT = 0x1,
CSSM_EVIDENCE_FORM_CRL = 0x2,
CSSM_EVIDENCE_FORM_CERT_ID = 0x3,
CSSM_EVIDENCE_FORM_CRL_ID = 0x4,
CSSM_EVIDENCE_FORM_VERIFIER_TIME = 0x5,
CSSM_EVIDENCE_FORM_CRL_THISTIME = 0x6,
CSSM_EVIDENCE_FORM_CRL_NEXTTIME = 0x7,
CSSM_EVIDENCE_FORM_POLICYINFO = 0x8,
CSSM_EVIDENCE_FORM_TUPLEGROUP = 0x9
};
typedef struct cssm_evidence {
CSSM_EVIDENCE_FORM EvidenceForm;
void *Evidence;
} CSSM_EVIDENCE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_EVIDENCE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tp_verify_context {
CSSM_TP_ACTION Action;
CSSM_DATA ActionData;
CSSM_CRLGROUP Crls;
CSSM_TP_CALLERAUTH_CONTEXT_PTR Cred;
} CSSM_TP_VERIFY_CONTEXT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_VERIFY_CONTEXT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tp_verify_context_result {
uint32 NumberOfEvidences;
CSSM_EVIDENCE_PTR Evidence;
} CSSM_TP_VERIFY_CONTEXT_RESULT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_VERIFY_CONTEXT_RESULT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tp_request_set {
uint32 NumberOfRequests;
void *Requests;
} CSSM_TP_REQUEST_SET __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_REQUEST_SET_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tp_result_set {
uint32 NumberOfResults;
void *Results;
} CSSM_TP_RESULT_SET __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_RESULT_SET_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_TP_CONFIRM_STATUS, *CSSM_TP_CONFIRM_STATUS_PTR;
enum {
CSSM_TP_CONFIRM_STATUS_UNKNOWN = 0x0,
CSSM_TP_CONFIRM_ACCEPT = 0x1,
CSSM_TP_CONFIRM_REJECT = 0x2
};
typedef struct cssm_tp_confirm_response {
uint32 NumberOfResponses;
CSSM_TP_CONFIRM_STATUS_PTR Responses;
} CSSM_TP_CONFIRM_RESPONSE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CONFIRM_RESPONSE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
enum {
CSSM_ESTIMATED_TIME_UNKNOWN = -1
};
enum {
CSSM_ELAPSED_TIME_UNKNOWN = -1,
CSSM_ELAPSED_TIME_COMPLETE = -2
};
typedef struct cssm_tp_certissue_input {
CSSM_SUBSERVICE_UID CSPSubserviceUid;
CSSM_CL_HANDLE CLHandle;
uint32 NumberOfTemplateFields;
CSSM_FIELD_PTR SubjectCertFields;
CSSM_TP_SERVICES MoreServiceRequests;
uint32 NumberOfServiceControls;
CSSM_FIELD_PTR ServiceControls;
CSSM_ACCESS_CREDENTIALS_PTR UserCredentials;
} CSSM_TP_CERTISSUE_INPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CERTISSUE_INPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_TP_CERTISSUE_STATUS;
enum {
CSSM_TP_CERTISSUE_STATUS_UNKNOWN = 0x0,
CSSM_TP_CERTISSUE_OK = 0x1,
CSSM_TP_CERTISSUE_OKWITHCERTMODS = 0x2,
CSSM_TP_CERTISSUE_OKWITHSERVICEMODS = 0x3,
CSSM_TP_CERTISSUE_REJECTED = 0x4,
CSSM_TP_CERTISSUE_NOT_AUTHORIZED = 0x5,
CSSM_TP_CERTISSUE_WILL_BE_REVOKED = 0x6
};
typedef struct cssm_tp_certissue_output {
CSSM_TP_CERTISSUE_STATUS IssueStatus;
CSSM_CERTGROUP_PTR CertGroup;
CSSM_TP_SERVICES PerformedServiceRequests;
} CSSM_TP_CERTISSUE_OUTPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CERTISSUE_OUTPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_TP_CERTCHANGE_ACTION;
enum {
CSSM_TP_CERTCHANGE_NONE = 0x0,
CSSM_TP_CERTCHANGE_REVOKE = 0x1,
CSSM_TP_CERTCHANGE_HOLD = 0x2,
CSSM_TP_CERTCHANGE_RELEASE = 0x3
};
typedef uint32 CSSM_TP_CERTCHANGE_REASON;
enum {
CSSM_TP_CERTCHANGE_REASON_UNKNOWN = 0x0,
CSSM_TP_CERTCHANGE_REASON_KEYCOMPROMISE = 0x1,
CSSM_TP_CERTCHANGE_REASON_CACOMPROMISE = 0x2,
CSSM_TP_CERTCHANGE_REASON_CEASEOPERATION = 0x3,
CSSM_TP_CERTCHANGE_REASON_AFFILIATIONCHANGE = 0x4,
CSSM_TP_CERTCHANGE_REASON_SUPERCEDED = 0x5,
CSSM_TP_CERTCHANGE_REASON_SUSPECTEDCOMPROMISE = 0x6,
CSSM_TP_CERTCHANGE_REASON_HOLDRELEASE = 0x7
};
typedef struct cssm_tp_certchange_input {
CSSM_TP_CERTCHANGE_ACTION Action;
CSSM_TP_CERTCHANGE_REASON Reason;
CSSM_CL_HANDLE CLHandle;
CSSM_DATA_PTR Cert;
CSSM_FIELD_PTR ChangeInfo;
CSSM_TIMESTRING StartTime;
CSSM_ACCESS_CREDENTIALS_PTR CallerCredentials;
} CSSM_TP_CERTCHANGE_INPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CERTCHANGE_INPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_TP_CERTCHANGE_STATUS;
enum {
CSSM_TP_CERTCHANGE_STATUS_UNKNOWN = 0x0,
CSSM_TP_CERTCHANGE_OK = 0x1,
CSSM_TP_CERTCHANGE_OKWITHNEWTIME = 0x2,
CSSM_TP_CERTCHANGE_WRONGCA = 0x3,
CSSM_TP_CERTCHANGE_REJECTED = 0x4,
CSSM_TP_CERTCHANGE_NOT_AUTHORIZED = 0x5
};
typedef struct cssm_tp_certchange_output {
CSSM_TP_CERTCHANGE_STATUS ActionStatus;
CSSM_FIELD RevokeInfo;
} CSSM_TP_CERTCHANGE_OUTPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CERTCHANGE_OUTPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tp_certverify_input {
CSSM_CL_HANDLE CLHandle;
CSSM_DATA_PTR Cert;
CSSM_TP_VERIFY_CONTEXT_PTR VerifyContext;
} CSSM_TP_CERTVERIFY_INPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CERTVERIFY_INPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_TP_CERTVERIFY_STATUS;
enum {
CSSM_TP_CERTVERIFY_UNKNOWN = 0x0,
CSSM_TP_CERTVERIFY_VALID = 0x1,
CSSM_TP_CERTVERIFY_INVALID = 0x2,
CSSM_TP_CERTVERIFY_REVOKED = 0x3,
CSSM_TP_CERTVERIFY_SUSPENDED = 0x4,
CSSM_TP_CERTVERIFY_EXPIRED = 0x5,
CSSM_TP_CERTVERIFY_NOT_VALID_YET = 0x6,
CSSM_TP_CERTVERIFY_INVALID_AUTHORITY = 0x7,
CSSM_TP_CERTVERIFY_INVALID_SIGNATURE = 0x8,
CSSM_TP_CERTVERIFY_INVALID_CERT_VALUE = 0x9,
CSSM_TP_CERTVERIFY_INVALID_CERTGROUP = 0xA,
CSSM_TP_CERTVERIFY_INVALID_POLICY = 0xB,
CSSM_TP_CERTVERIFY_INVALID_POLICY_IDS = 0xC,
CSSM_TP_CERTVERIFY_INVALID_BASIC_CONSTRAINTS = 0xD,
CSSM_TP_CERTVERIFY_INVALID_CRL_DIST_PT = 0xE,
CSSM_TP_CERTVERIFY_INVALID_NAME_TREE = 0xF,
CSSM_TP_CERTVERIFY_UNKNOWN_CRITICAL_EXT = 0x10
};
typedef struct cssm_tp_certverify_output {
CSSM_TP_CERTVERIFY_STATUS VerifyStatus;
uint32 NumberOfEvidence;
CSSM_EVIDENCE_PTR Evidence;
} CSSM_TP_CERTVERIFY_OUTPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CERTVERIFY_OUTPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tp_certnotarize_input {
CSSM_CL_HANDLE CLHandle;
uint32 NumberOfFields;
CSSM_FIELD_PTR MoreFields;
CSSM_FIELD_PTR SignScope;
uint32 ScopeSize;
CSSM_TP_SERVICES MoreServiceRequests;
uint32 NumberOfServiceControls;
CSSM_FIELD_PTR ServiceControls;
CSSM_ACCESS_CREDENTIALS_PTR UserCredentials;
} CSSM_TP_CERTNOTARIZE_INPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CERTNOTARIZE_INPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_TP_CERTNOTARIZE_STATUS;
enum {
CSSM_TP_CERTNOTARIZE_STATUS_UNKNOWN = 0x0,
CSSM_TP_CERTNOTARIZE_OK = 0x1,
CSSM_TP_CERTNOTARIZE_OKWITHOUTFIELDS = 0x2,
CSSM_TP_CERTNOTARIZE_OKWITHSERVICEMODS = 0x3,
CSSM_TP_CERTNOTARIZE_REJECTED = 0x4,
CSSM_TP_CERTNOTARIZE_NOT_AUTHORIZED = 0x5
};
typedef struct cssm_tp_certnotarize_output {
CSSM_TP_CERTNOTARIZE_STATUS NotarizeStatus;
CSSM_CERTGROUP_PTR NotarizedCertGroup;
CSSM_TP_SERVICES PerformedServiceRequests;
} CSSM_TP_CERTNOTARIZE_OUTPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CERTNOTARIZE_OUTPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tp_certreclaim_input {
CSSM_CL_HANDLE CLHandle;
uint32 NumberOfSelectionFields;
CSSM_FIELD_PTR SelectionFields;
CSSM_ACCESS_CREDENTIALS_PTR UserCredentials;
} CSSM_TP_CERTRECLAIM_INPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CERTRECLAIM_INPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_TP_CERTRECLAIM_STATUS;
enum {
CSSM_TP_CERTRECLAIM_STATUS_UNKNOWN = 0x0,
CSSM_TP_CERTRECLAIM_OK = 0x1,
CSSM_TP_CERTRECLAIM_NOMATCH = 0x2,
CSSM_TP_CERTRECLAIM_REJECTED = 0x3,
CSSM_TP_CERTRECLAIM_NOT_AUTHORIZED = 0x4
};
typedef struct cssm_tp_certreclaim_output {
CSSM_TP_CERTRECLAIM_STATUS ReclaimStatus;
CSSM_CERTGROUP_PTR ReclaimedCertGroup;
CSSM_LONG_HANDLE KeyCacheHandle;
} CSSM_TP_CERTRECLAIM_OUTPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CERTRECLAIM_OUTPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_tp_crlissue_input {
CSSM_CL_HANDLE CLHandle;
uint32 CrlIdentifier;
CSSM_TIMESTRING CrlThisTime;
CSSM_FIELD_PTR PolicyIdentifier;
CSSM_ACCESS_CREDENTIALS_PTR CallerCredentials;
} CSSM_TP_CRLISSUE_INPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CRLISSUE_INPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_TP_CRLISSUE_STATUS;
enum {
CSSM_TP_CRLISSUE_STATUS_UNKNOWN = 0x0,
CSSM_TP_CRLISSUE_OK = 0x1,
CSSM_TP_CRLISSUE_NOT_CURRENT = 0x2,
CSSM_TP_CRLISSUE_INVALID_DOMAIN = 0x3,
CSSM_TP_CRLISSUE_UNKNOWN_IDENTIFIER = 0x4,
CSSM_TP_CRLISSUE_REJECTED = 0x5,
CSSM_TP_CRLISSUE_NOT_AUTHORIZED = 0x6
};
typedef struct cssm_tp_crlissue_output {
CSSM_TP_CRLISSUE_STATUS IssueStatus;
CSSM_ENCODED_CRL_PTR Crl;
CSSM_TIMESTRING CrlNextTime;
} CSSM_TP_CRLISSUE_OUTPUT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_TP_CRLISSUE_OUTPUT_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_TP_FORM_TYPE;
enum {
CSSM_TP_FORM_TYPE_GENERIC = 0x0,
CSSM_TP_FORM_TYPE_REGISTRATION = 0x1
};
typedef uint32 CSSM_CL_TEMPLATE_TYPE;
enum {
CSSM_CL_TEMPLATE_INTERMEDIATE_CERT = 1,
CSSM_CL_TEMPLATE_PKIX_CERTTEMPLATE = 2
};
typedef uint32 CSSM_CERT_BUNDLE_TYPE;
enum {
CSSM_CERT_BUNDLE_UNKNOWN = 0x00,
CSSM_CERT_BUNDLE_CUSTOM = 0x01,
CSSM_CERT_BUNDLE_PKCS7_SIGNED_DATA = 0x02,
CSSM_CERT_BUNDLE_PKCS7_SIGNED_ENVELOPED_DATA = 0x03,
CSSM_CERT_BUNDLE_PKCS12 = 0x04,
CSSM_CERT_BUNDLE_PFX = 0x05,
CSSM_CERT_BUNDLE_SPKI_SEQUENCE = 0x06,
CSSM_CERT_BUNDLE_PGP_KEYRING = 0x07,
CSSM_CERT_BUNDLE_LAST = 0x7FFF,
CSSM_CL_CUSTOM_CERT_BUNDLE_TYPE = 0x8000
};
typedef uint32 CSSM_CERT_BUNDLE_ENCODING;
enum {
CSSM_CERT_BUNDLE_ENCODING_UNKNOWN = 0x00,
CSSM_CERT_BUNDLE_ENCODING_CUSTOM = 0x01,
CSSM_CERT_BUNDLE_ENCODING_BER = 0x02,
CSSM_CERT_BUNDLE_ENCODING_DER = 0x03,
CSSM_CERT_BUNDLE_ENCODING_SEXPR = 0x04,
CSSM_CERT_BUNDLE_ENCODING_PGP = 0x05
};
typedef struct cssm_cert_bundle_header {
CSSM_CERT_BUNDLE_TYPE BundleType;
CSSM_CERT_BUNDLE_ENCODING BundleEncoding;
} CSSM_CERT_BUNDLE_HEADER __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_CERT_BUNDLE_HEADER_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_cert_bundle {
CSSM_CERT_BUNDLE_HEADER BundleHeader;
CSSM_DATA Bundle;
} CSSM_CERT_BUNDLE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_CERT_BUNDLE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
enum {
CSSM_FIELDVALUE_COMPLEX_DATA_TYPE = 0xFFFFFFFF
};
typedef uint32 CSSM_DB_ATTRIBUTE_NAME_FORMAT, *CSSM_DB_ATTRIBUTE_NAME_FORMAT_PTR;
enum {
CSSM_DB_ATTRIBUTE_NAME_AS_STRING = 0,
CSSM_DB_ATTRIBUTE_NAME_AS_OID = 1,
CSSM_DB_ATTRIBUTE_NAME_AS_INTEGER = 2
};
typedef uint32 CSSM_DB_ATTRIBUTE_FORMAT, *CSSM_DB_ATTRIBUTE_FORMAT_PTR;
enum {
CSSM_DB_ATTRIBUTE_FORMAT_STRING = 0,
CSSM_DB_ATTRIBUTE_FORMAT_SINT32 = 1,
CSSM_DB_ATTRIBUTE_FORMAT_UINT32 = 2,
CSSM_DB_ATTRIBUTE_FORMAT_BIG_NUM = 3,
CSSM_DB_ATTRIBUTE_FORMAT_REAL = 4,
CSSM_DB_ATTRIBUTE_FORMAT_TIME_DATE = 5,
CSSM_DB_ATTRIBUTE_FORMAT_BLOB = 6,
CSSM_DB_ATTRIBUTE_FORMAT_MULTI_UINT32 = 7,
CSSM_DB_ATTRIBUTE_FORMAT_COMPLEX = 8
};
typedef struct cssm_db_attribute_info {
CSSM_DB_ATTRIBUTE_NAME_FORMAT AttributeNameFormat;
union cssm_db_attribute_label {
char *AttributeName;
CSSM_OID AttributeOID;
uint32 AttributeID;
} Label;
CSSM_DB_ATTRIBUTE_FORMAT AttributeFormat;
} CSSM_DB_ATTRIBUTE_INFO, *CSSM_DB_ATTRIBUTE_INFO_PTR;
typedef struct cssm_db_attribute_data {
CSSM_DB_ATTRIBUTE_INFO Info;
uint32 NumberOfValues;
CSSM_DATA_PTR Value;
} CSSM_DB_ATTRIBUTE_DATA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DB_ATTRIBUTE_DATA_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_DB_RECORDTYPE;
enum {
CSSM_DB_RECORDTYPE_SCHEMA_START = 0x00000000,
CSSM_DB_RECORDTYPE_SCHEMA_END = CSSM_DB_RECORDTYPE_SCHEMA_START + 4,
CSSM_DB_RECORDTYPE_OPEN_GROUP_START = 0x0000000A,
CSSM_DB_RECORDTYPE_OPEN_GROUP_END = CSSM_DB_RECORDTYPE_OPEN_GROUP_START + 8,
CSSM_DB_RECORDTYPE_APP_DEFINED_START = 0x80000000,
CSSM_DB_RECORDTYPE_APP_DEFINED_END = 0xffffffff,
CSSM_DL_DB_SCHEMA_INFO = CSSM_DB_RECORDTYPE_SCHEMA_START + 0,
CSSM_DL_DB_SCHEMA_INDEXES = CSSM_DB_RECORDTYPE_SCHEMA_START + 1,
CSSM_DL_DB_SCHEMA_ATTRIBUTES = CSSM_DB_RECORDTYPE_SCHEMA_START + 2,
CSSM_DL_DB_SCHEMA_PARSING_MODULE = CSSM_DB_RECORDTYPE_SCHEMA_START + 3,
CSSM_DL_DB_RECORD_ANY = CSSM_DB_RECORDTYPE_OPEN_GROUP_START + 0,
CSSM_DL_DB_RECORD_CERT = CSSM_DB_RECORDTYPE_OPEN_GROUP_START + 1,
CSSM_DL_DB_RECORD_CRL = CSSM_DB_RECORDTYPE_OPEN_GROUP_START + 2,
CSSM_DL_DB_RECORD_POLICY = CSSM_DB_RECORDTYPE_OPEN_GROUP_START + 3,
CSSM_DL_DB_RECORD_GENERIC = CSSM_DB_RECORDTYPE_OPEN_GROUP_START + 4,
CSSM_DL_DB_RECORD_PUBLIC_KEY = CSSM_DB_RECORDTYPE_OPEN_GROUP_START + 5,
CSSM_DL_DB_RECORD_PRIVATE_KEY = CSSM_DB_RECORDTYPE_OPEN_GROUP_START + 6,
CSSM_DL_DB_RECORD_SYMMETRIC_KEY = CSSM_DB_RECORDTYPE_OPEN_GROUP_START + 7,
CSSM_DL_DB_RECORD_ALL_KEYS = CSSM_DB_RECORDTYPE_OPEN_GROUP_START + 8
};
enum {
CSSM_DB_CERT_USE_TRUSTED = 0x00000001,
CSSM_DB_CERT_USE_SYSTEM = 0x00000002,
CSSM_DB_CERT_USE_OWNER = 0x00000004,
CSSM_DB_CERT_USE_REVOKED = 0x00000008,
CSSM_DB_CERT_USE_SIGNING = 0x00000010,
CSSM_DB_CERT_USE_PRIVACY = 0x00000020
};
typedef struct cssm_db_record_attribute_info {
CSSM_DB_RECORDTYPE DataRecordType;
uint32 NumberOfAttributes;
CSSM_DB_ATTRIBUTE_INFO_PTR AttributeInfo;
} CSSM_DB_RECORD_ATTRIBUTE_INFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DB_RECORD_ATTRIBUTE_INFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_db_record_attribute_data {
CSSM_DB_RECORDTYPE DataRecordType;
uint32 SemanticInformation;
uint32 NumberOfAttributes;
CSSM_DB_ATTRIBUTE_DATA_PTR AttributeData;
} CSSM_DB_RECORD_ATTRIBUTE_DATA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DB_RECORD_ATTRIBUTE_DATA_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_db_parsing_module_info {
CSSM_DB_RECORDTYPE RecordType;
CSSM_SUBSERVICE_UID ModuleSubserviceUid;
} CSSM_DB_PARSING_MODULE_INFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DB_PARSING_MODULE_INFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_DB_INDEX_TYPE;
enum {
CSSM_DB_INDEX_UNIQUE = 0,
CSSM_DB_INDEX_NONUNIQUE = 1
};
typedef uint32 CSSM_DB_INDEXED_DATA_LOCATION;
enum {
CSSM_DB_INDEX_ON_UNKNOWN = 0,
CSSM_DB_INDEX_ON_ATTRIBUTE = 1,
CSSM_DB_INDEX_ON_RECORD = 2
};
typedef struct cssm_db_index_info {
CSSM_DB_INDEX_TYPE IndexType;
CSSM_DB_INDEXED_DATA_LOCATION IndexedDataLocation;
CSSM_DB_ATTRIBUTE_INFO Info;
} CSSM_DB_INDEX_INFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DB_INDEX_INFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_db_unique_record {
CSSM_DB_INDEX_INFO RecordLocator;
CSSM_DATA RecordIdentifier;
} CSSM_DB_UNIQUE_RECORD __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DB_UNIQUE_RECORD_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_db_record_index_info {
CSSM_DB_RECORDTYPE DataRecordType;
uint32 NumberOfIndexes;
CSSM_DB_INDEX_INFO_PTR IndexInfo;
} CSSM_DB_RECORD_INDEX_INFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DB_RECORD_INDEX_INFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_DB_ACCESS_TYPE, *CSSM_DB_ACCESS_TYPE_PTR;
enum {
CSSM_DB_ACCESS_READ = 0x00001,
CSSM_DB_ACCESS_WRITE = 0x00002,
CSSM_DB_ACCESS_PRIVILEGED = 0x00004
};
typedef uint32 CSSM_DB_MODIFY_MODE;
enum {
CSSM_DB_MODIFY_ATTRIBUTE_NONE = 0,
CSSM_DB_MODIFY_ATTRIBUTE_ADD = CSSM_DB_MODIFY_ATTRIBUTE_NONE + 1,
CSSM_DB_MODIFY_ATTRIBUTE_DELETE = CSSM_DB_MODIFY_ATTRIBUTE_NONE + 2,
CSSM_DB_MODIFY_ATTRIBUTE_REPLACE = CSSM_DB_MODIFY_ATTRIBUTE_NONE + 3
};
typedef struct cssm_dbinfo {
uint32 NumberOfRecordTypes;
CSSM_DB_PARSING_MODULE_INFO_PTR DefaultParsingModules;
CSSM_DB_RECORD_ATTRIBUTE_INFO_PTR RecordAttributeNames;
CSSM_DB_RECORD_INDEX_INFO_PTR RecordIndexes;
CSSM_BOOL IsLocal;
char *AccessPath;
void *Reserved;
} CSSM_DBINFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DBINFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_DB_OPERATOR, *CSSM_DB_OPERATOR_PTR;
enum {
CSSM_DB_EQUAL = 0,
CSSM_DB_NOT_EQUAL = 1,
CSSM_DB_LESS_THAN = 2,
CSSM_DB_GREATER_THAN = 3,
CSSM_DB_CONTAINS = 4,
CSSM_DB_CONTAINS_INITIAL_SUBSTRING = 5,
CSSM_DB_CONTAINS_FINAL_SUBSTRING = 6
};
typedef uint32 CSSM_DB_CONJUNCTIVE, *CSSM_DB_CONJUNCTIVE_PTR;
enum {
CSSM_DB_NONE = 0,
CSSM_DB_AND = 1,
CSSM_DB_OR = 2
};
typedef struct cssm_selection_predicate {
CSSM_DB_OPERATOR DbOperator;
CSSM_DB_ATTRIBUTE_DATA Attribute;
} CSSM_SELECTION_PREDICATE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_SELECTION_PREDICATE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
enum {
CSSM_QUERY_TIMELIMIT_NONE = 0
};
enum {
CSSM_QUERY_SIZELIMIT_NONE = 0
};
typedef struct cssm_query_limits {
uint32 TimeLimit;
uint32 SizeLimit;
} CSSM_QUERY_LIMITS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_QUERY_LIMITS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_QUERY_FLAGS;
enum {
CSSM_QUERY_RETURN_DATA = 0x01
};
typedef struct cssm_query {
CSSM_DB_RECORDTYPE RecordType;
CSSM_DB_CONJUNCTIVE Conjunctive;
uint32 NumSelectionPredicates;
CSSM_SELECTION_PREDICATE_PTR SelectionPredicate;
CSSM_QUERY_LIMITS QueryLimits;
CSSM_QUERY_FLAGS QueryFlags;
} CSSM_QUERY __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_QUERY_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_DLTYPE, *CSSM_DLTYPE_PTR;
enum {
CSSM_DL_UNKNOWN = 0,
CSSM_DL_CUSTOM = 1,
CSSM_DL_LDAP = 2,
CSSM_DL_ODBC = 3,
CSSM_DL_PKCS11 = 4,
CSSM_DL_FFS = 5,
CSSM_DL_MEMORY = 6,
CSSM_DL_REMOTEDIR = 7
};
typedef void *CSSM_DL_CUSTOM_ATTRIBUTES;
typedef void *CSSM_DL_LDAP_ATTRIBUTES;
typedef void *CSSM_DL_ODBC_ATTRIBUTES;
typedef void *CSSM_DL_FFS_ATTRIBUTES;
typedef struct cssm_dl_pkcs11_attributes {
uint32 DeviceAccessFlags;
} *CSSM_DL_PKCS11_ATTRIBUTE, *CSSM_DL_PKCS11_ATTRIBUTE_PTR;
enum {
CSSM_DB_DATASTORES_UNKNOWN = 0xFFFFFFFF
};
typedef struct cssm_name_list {
uint32 NumStrings;
char **String;
} CSSM_NAME_LIST __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_NAME_LIST_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CSSM_DB_RETRIEVAL_MODES;
enum {
CSSM_DB_TRANSACTIONAL_MODE = 0,
CSSM_DB_FILESYSTEMSCAN_MODE = 1
};
typedef struct cssm_db_schema_attribute_info {
uint32 AttributeId;
char *AttributeName;
CSSM_OID AttributeNameID;
CSSM_DB_ATTRIBUTE_FORMAT DataType;
} CSSM_DB_SCHEMA_ATTRIBUTE_INFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DB_SCHEMA_ATTRIBUTE_INFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_db_schema_index_info {
uint32 AttributeId;
uint32 IndexId;
CSSM_DB_INDEX_TYPE IndexType;
CSSM_DB_INDEXED_DATA_LOCATION IndexedDataLocation;
} CSSM_DB_SCHEMA_INDEX_INFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_DB_SCHEMA_INDEX_INFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
typedef uint8 CSSM_BER_TAG;
typedef struct cssm_x509_algorithm_identifier {
CSSM_OID algorithm;
CSSM_DATA parameters;
} CSSM_X509_ALGORITHM_IDENTIFIER __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_ALGORITHM_IDENTIFIER_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_type_value_pair {
CSSM_OID type;
CSSM_BER_TAG valueType;
CSSM_DATA value;
} CSSM_X509_TYPE_VALUE_PAIR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_TYPE_VALUE_PAIR_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_rdn {
uint32 numberOfPairs;
CSSM_X509_TYPE_VALUE_PAIR_PTR AttributeTypeAndValue;
} CSSM_X509_RDN __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_RDN_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_name {
uint32 numberOfRDNs;
CSSM_X509_RDN_PTR RelativeDistinguishedName;
} CSSM_X509_NAME __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_NAME_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_subject_public_key_info {
CSSM_X509_ALGORITHM_IDENTIFIER algorithm;
CSSM_DATA subjectPublicKey;
} CSSM_X509_SUBJECT_PUBLIC_KEY_INFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_SUBJECT_PUBLIC_KEY_INFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_time {
CSSM_BER_TAG timeType;
CSSM_DATA time;
} CSSM_X509_TIME __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_TIME_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct x509_validity {
CSSM_X509_TIME notBefore;
CSSM_X509_TIME notAfter;
} CSSM_X509_VALIDITY __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_VALIDITY_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef CSSM_BOOL CSSM_X509_OPTION;
typedef struct cssm_x509ext_basicConstraints {
CSSM_BOOL cA;
CSSM_X509_OPTION pathLenConstraintPresent;
uint32 pathLenConstraint;
} CSSM_X509EXT_BASICCONSTRAINTS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509EXT_BASICCONSTRAINTS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef enum extension_data_format {
CSSM_X509_DATAFORMAT_ENCODED = 0,
CSSM_X509_DATAFORMAT_PARSED,
CSSM_X509_DATAFORMAT_PAIR
} CSSM_X509EXT_DATA_FORMAT;
typedef struct cssm_x509_extensionTagAndValue {
CSSM_BER_TAG type;
CSSM_DATA value;
} CSSM_X509EXT_TAGandVALUE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509EXT_TAGandVALUE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509ext_pair {
CSSM_X509EXT_TAGandVALUE tagAndValue;
void *parsedValue;
} CSSM_X509EXT_PAIR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509EXT_PAIR_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_extension {
CSSM_OID extnId;
CSSM_BOOL critical;
CSSM_X509EXT_DATA_FORMAT format;
union cssm_x509ext_value {
CSSM_X509EXT_TAGandVALUE *tagAndValue;
void *parsedValue;
CSSM_X509EXT_PAIR *valuePair;
} value;
CSSM_DATA BERvalue;
} CSSM_X509_EXTENSION __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_EXTENSION_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_extensions {
uint32 numberOfExtensions;
CSSM_X509_EXTENSION_PTR extensions;
} CSSM_X509_EXTENSIONS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_EXTENSIONS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_tbs_certificate {
CSSM_DATA version;
CSSM_DATA serialNumber;
CSSM_X509_ALGORITHM_IDENTIFIER signature;
CSSM_X509_NAME issuer;
CSSM_X509_VALIDITY validity;
CSSM_X509_NAME subject;
CSSM_X509_SUBJECT_PUBLIC_KEY_INFO subjectPublicKeyInfo;
CSSM_DATA issuerUniqueIdentifier;
CSSM_DATA subjectUniqueIdentifier;
CSSM_X509_EXTENSIONS extensions;
} CSSM_X509_TBS_CERTIFICATE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_TBS_CERTIFICATE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_signature {
CSSM_X509_ALGORITHM_IDENTIFIER algorithmIdentifier;
CSSM_DATA encrypted;
} CSSM_X509_SIGNATURE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_SIGNATURE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_signed_certificate {
CSSM_X509_TBS_CERTIFICATE certificate;
CSSM_X509_SIGNATURE signature;
} CSSM_X509_SIGNED_CERTIFICATE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_SIGNED_CERTIFICATE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509ext_policyQualifierInfo {
CSSM_OID policyQualifierId;
CSSM_DATA value;
} CSSM_X509EXT_POLICYQUALIFIERINFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509EXT_POLICYQUALIFIERINFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509ext_policyQualifiers {
uint32 numberOfPolicyQualifiers;
CSSM_X509EXT_POLICYQUALIFIERINFO *policyQualifier;
} CSSM_X509EXT_POLICYQUALIFIERS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509EXT_POLICYQUALIFIERS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509ext_policyInfo {
CSSM_OID policyIdentifier;
CSSM_X509EXT_POLICYQUALIFIERS policyQualifiers;
} CSSM_X509EXT_POLICYINFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509EXT_POLICYINFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_revoked_cert_entry {
CSSM_DATA certificateSerialNumber;
CSSM_X509_TIME revocationDate;
CSSM_X509_EXTENSIONS extensions;
} CSSM_X509_REVOKED_CERT_ENTRY __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_REVOKED_CERT_ENTRY_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_revoked_cert_list {
uint32 numberOfRevokedCertEntries;
CSSM_X509_REVOKED_CERT_ENTRY_PTR revokedCertEntry;
} CSSM_X509_REVOKED_CERT_LIST __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_REVOKED_CERT_LIST_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_tbs_certlist {
CSSM_DATA version;
CSSM_X509_ALGORITHM_IDENTIFIER signature;
CSSM_X509_NAME issuer;
CSSM_X509_TIME thisUpdate;
CSSM_X509_TIME nextUpdate;
CSSM_X509_REVOKED_CERT_LIST_PTR revokedCertificates;
CSSM_X509_EXTENSIONS extensions;
} CSSM_X509_TBS_CERTLIST __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_TBS_CERTLIST_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_x509_signed_crl {
CSSM_X509_TBS_CERTLIST tbsCertList;
CSSM_X509_SIGNATURE signature;
} CSSM_X509_SIGNED_CRL __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_X509_SIGNED_CRL_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
typedef enum __CE_GeneralNameType {
GNT_OtherName = 0,
GNT_RFC822Name,
GNT_DNSName,
GNT_X400Address,
GNT_DirectoryName,
GNT_EdiPartyName,
GNT_URI,
GNT_IPAddress,
GNT_RegisteredID
} CE_GeneralNameType;
typedef struct __CE_OtherName {
CSSM_OID typeId;
CSSM_DATA value;
} CE_OtherName __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_GeneralName {
CE_GeneralNameType nameType;
CSSM_BOOL berEncoded;
CSSM_DATA name;
} CE_GeneralName __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_GeneralNames {
uint32 numNames;
CE_GeneralName *generalName;
} CE_GeneralNames __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_AuthorityKeyID {
CSSM_BOOL keyIdentifierPresent;
CSSM_DATA keyIdentifier;
CSSM_BOOL generalNamesPresent;
CE_GeneralNames *generalNames;
CSSM_BOOL serialNumberPresent;
CSSM_DATA serialNumber;
} CE_AuthorityKeyID __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef CSSM_DATA CE_SubjectKeyID __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint16 CE_KeyUsage __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CE_CrlReason __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_ExtendedKeyUsage {
uint32 numPurposes;
CSSM_OID_PTR purposes;
} CE_ExtendedKeyUsage;
typedef struct __CE_BasicConstraints {
CSSM_BOOL cA;
CSSM_BOOL pathLenConstraintPresent;
uint32 pathLenConstraint;
} CE_BasicConstraints __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_PolicyQualifierInfo {
CSSM_OID policyQualifierId;
CSSM_DATA qualifier;
} CE_PolicyQualifierInfo __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_PolicyInformation {
CSSM_OID certPolicyId;
uint32 numPolicyQualifiers;
CE_PolicyQualifierInfo *policyQualifiers;
} CE_PolicyInformation __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_CertPolicies {
uint32 numPolicies;
CE_PolicyInformation *policies;
} CE_CertPolicies __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint16 CE_NetscapeCertType __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint8 CE_CrlDistReasonFlags __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef enum __CE_CrlDistributionPointNameType {
CE_CDNT_FullName,
CE_CDNT_NameRelativeToCrlIssuer
} CE_CrlDistributionPointNameType __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_DistributionPointName {
CE_CrlDistributionPointNameType nameType;
union {
CE_GeneralNames *fullName;
CSSM_X509_RDN_PTR rdn;
} dpn;
} CE_DistributionPointName __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_CRLDistributionPoint {
CE_DistributionPointName *distPointName;
CSSM_BOOL reasonsPresent;
CE_CrlDistReasonFlags reasons;
CE_GeneralNames *crlIssuer;
} CE_CRLDistributionPoint __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_CRLDistPointsSyntax {
uint32 numDistPoints;
CE_CRLDistributionPoint *distPoints;
} CE_CRLDistPointsSyntax __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_AccessDescription {
CSSM_OID accessMethod;
CE_GeneralName accessLocation;
} CE_AccessDescription __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_AuthorityInfoAccess {
uint32 numAccessDescriptions;
CE_AccessDescription *accessDescriptions;
} CE_AuthorityInfoAccess __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef CE_GeneralNames CE_NameRegistrationAuthorities __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_SemanticsInformation {
CSSM_OID *semanticsIdentifier;
CE_NameRegistrationAuthorities *nameRegistrationAuthorities;
} CE_SemanticsInformation __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_QC_Statement {
CSSM_OID statementId;
CE_SemanticsInformation *semanticsInfo;
CSSM_DATA *otherInfo;
} CE_QC_Statement __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_QC_Statements {
uint32 numQCStatements;
CE_QC_Statement *qcStatements;
} CE_QC_Statements __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CE_CrlNumber;
typedef uint32 CE_DeltaCrl;
typedef struct __CE_IssuingDistributionPoint {
CE_DistributionPointName *distPointName;
CSSM_BOOL onlyUserCertsPresent;
CSSM_BOOL onlyUserCerts;
CSSM_BOOL onlyCACertsPresent;
CSSM_BOOL onlyCACerts;
CSSM_BOOL onlySomeReasonsPresent;
CE_CrlDistReasonFlags onlySomeReasons;
CSSM_BOOL indirectCrlPresent;
CSSM_BOOL indirectCrl;
} CE_IssuingDistributionPoint __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_GeneralSubtree {
CE_GeneralNames *base;
uint32 minimum;
CSSM_BOOL maximumPresent;
uint32 maximum;
} CE_GeneralSubtree __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_GeneralSubtrees {
uint32 numSubtrees;
CE_GeneralSubtree *subtrees;
} CE_GeneralSubtrees __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_NameConstraints {
CE_GeneralSubtrees *permitted;
CE_GeneralSubtrees *excluded;
} CE_NameConstraints __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_PolicyMapping {
CSSM_OID issuerDomainPolicy;
CSSM_OID subjectDomainPolicy;
} CE_PolicyMapping __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_PolicyMappings {
uint32 numPolicyMappings;
CE_PolicyMapping *policyMappings;
} CE_PolicyMappings __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_PolicyConstraints {
CSSM_BOOL requireExplicitPolicyPresent;
uint32 requireExplicitPolicy;
CSSM_BOOL inhibitPolicyMappingPresent;
uint32 inhibitPolicyMapping;
} CE_PolicyConstraints __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef uint32 CE_InhibitAnyPolicy __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef enum __CE_DataType {
DT_AuthorityKeyID,
DT_SubjectKeyID,
DT_KeyUsage,
DT_SubjectAltName,
DT_IssuerAltName,
DT_ExtendedKeyUsage,
DT_BasicConstraints,
DT_CertPolicies,
DT_NetscapeCertType,
DT_CrlNumber,
DT_DeltaCrl,
DT_CrlReason,
DT_CrlDistributionPoints,
DT_IssuingDistributionPoint,
DT_AuthorityInfoAccess,
DT_Other,
DT_QC_Statements,
DT_NameConstraints,
DT_PolicyMappings,
DT_PolicyConstraints,
DT_InhibitAnyPolicy
} CE_DataType;
typedef union {
CE_AuthorityKeyID authorityKeyID;
CE_SubjectKeyID subjectKeyID;
CE_KeyUsage keyUsage;
CE_GeneralNames subjectAltName;
CE_GeneralNames issuerAltName;
CE_ExtendedKeyUsage extendedKeyUsage;
CE_BasicConstraints basicConstraints;
CE_CertPolicies certPolicies;
CE_NetscapeCertType netscapeCertType;
CE_CrlNumber crlNumber;
CE_DeltaCrl deltaCrl;
CE_CrlReason crlReason;
CE_CRLDistPointsSyntax crlDistPoints;
CE_IssuingDistributionPoint issuingDistPoint;
CE_AuthorityInfoAccess authorityInfoAccess;
CE_QC_Statements qualifiedCertStatements;
CE_NameConstraints nameConstraints;
CE_PolicyMappings policyMappings;
CE_PolicyConstraints policyConstraints;
CE_InhibitAnyPolicy inhibitAnyPolicy;
CSSM_DATA rawData;
} CE_Data __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct __CE_DataAndType {
CE_DataType type;
CE_Data extension;
CSSM_BOOL critical;
} CE_DataAndType __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
extern "C" {
extern const CSSM_GUID gGuidCssm;
extern const CSSM_GUID gGuidAppleFileDL;
extern const CSSM_GUID gGuidAppleCSP;
extern const CSSM_GUID gGuidAppleCSPDL;
extern const CSSM_GUID gGuidAppleX509CL;
extern const CSSM_GUID gGuidAppleX509TP;
extern const CSSM_GUID gGuidAppleLDAPDL;
extern const CSSM_GUID gGuidAppleDotMacTP;
extern const CSSM_GUID gGuidAppleSdCSPDL;
extern const CSSM_GUID gGuidAppleDotMacDL;
enum
{
CSSM_WORDID_KEYCHAIN_PROMPT = CSSM_WORDID_VENDOR_START,
CSSM_WORDID_KEYCHAIN_LOCK,
CSSM_WORDID_KEYCHAIN_CHANGE_LOCK,
CSSM_WORDID_PROCESS,
CSSM_WORDID__RESERVED_1,
CSSM_WORDID_SYMMETRIC_KEY,
CSSM_WORDID_SYSTEM,
CSSM_WORDID_KEY,
CSSM_WORDID_PIN,
CSSM_WORDID_PREAUTH,
CSSM_WORDID_PREAUTH_SOURCE,
CSSM_WORDID_ASYMMETRIC_KEY,
CSSM_WORDID__FIRST_UNUSED
};
enum
{
CSSM_ACL_SUBJECT_TYPE_KEYCHAIN_PROMPT = CSSM_WORDID_KEYCHAIN_PROMPT,
CSSM_ACL_SUBJECT_TYPE_PROCESS = CSSM_WORDID_PROCESS,
CSSM_ACL_SUBJECT_TYPE_CODE_SIGNATURE = CSSM_WORDID_SIGNATURE,
CSSM_ACL_SUBJECT_TYPE_COMMENT = CSSM_WORDID_COMMENT,
CSSM_ACL_SUBJECT_TYPE_SYMMETRIC_KEY = CSSM_WORDID_SYMMETRIC_KEY,
CSSM_ACL_SUBJECT_TYPE_PREAUTH = CSSM_WORDID_PREAUTH,
CSSM_ACL_SUBJECT_TYPE_PREAUTH_SOURCE = CSSM_WORDID_PREAUTH_SOURCE,
CSSM_ACL_SUBJECT_TYPE_ASYMMETRIC_KEY = CSSM_WORDID_ASYMMETRIC_KEY
};
enum
{
CSSM_SAMPLE_TYPE_KEYCHAIN_PROMPT = CSSM_WORDID_KEYCHAIN_PROMPT,
CSSM_SAMPLE_TYPE_KEYCHAIN_LOCK = CSSM_WORDID_KEYCHAIN_LOCK,
CSSM_SAMPLE_TYPE_KEYCHAIN_CHANGE_LOCK = CSSM_WORDID_KEYCHAIN_CHANGE_LOCK,
CSSM_SAMPLE_TYPE_PROCESS = CSSM_WORDID_PROCESS,
CSSM_SAMPLE_TYPE_COMMENT = CSSM_WORDID_COMMENT,
CSSM_SAMPLE_TYPE_RETRY_ID = CSSM_WORDID_PROPAGATE,
CSSM_SAMPLE_TYPE_SYMMETRIC_KEY = CSSM_WORDID_SYMMETRIC_KEY,
CSSM_SAMPLE_TYPE_PREAUTH = CSSM_WORDID_PREAUTH,
CSSM_SAMPLE_TYPE_ASYMMETRIC_KEY = CSSM_WORDID_ASYMMETRIC_KEY
};
enum {
CSSM_ACL_AUTHORIZATION_CHANGE_ACL = CSSM_ACL_AUTHORIZATION_TAG_VENDOR_DEFINED_START,
CSSM_ACL_AUTHORIZATION_CHANGE_OWNER,
CSSM_ACL_AUTHORIZATION_PREAUTH_BASE =
CSSM_ACL_AUTHORIZATION_TAG_VENDOR_DEFINED_START + 0x1000000,
CSSM_ACL_AUTHORIZATION_PREAUTH_END = CSSM_ACL_AUTHORIZATION_PREAUTH_BASE + 0x10000
};
enum {
CSSM_ACL_CODE_SIGNATURE_INVALID = 0,
CSSM_ACL_CODE_SIGNATURE_OSX = 1
};
enum {
CSSM_ACL_MATCH_UID = 0x01,
CSSM_ACL_MATCH_GID = 0x02,
CSSM_ACL_MATCH_HONOR_ROOT = 0x100,
CSSM_ACL_MATCH_BITS = CSSM_ACL_MATCH_UID | CSSM_ACL_MATCH_GID
};
enum {
CSSM_ACL_PROCESS_SELECTOR_CURRENT_VERSION = 0x101
};
typedef struct cssm_acl_process_subject_selector {
uint16 version;
uint16 mask;
uint32 uid;
uint32 gid;
} CSSM_ACL_PROCESS_SUBJECT_SELECTOR;
enum {
CSSM_ACL_KEYCHAIN_PROMPT_CURRENT_VERSION = 0x101
};
enum {
CSSM_ACL_KEYCHAIN_PROMPT_REQUIRE_PASSPHRASE = 0x0001,
CSSM_ACL_KEYCHAIN_PROMPT_UNSIGNED = 0x0010,
CSSM_ACL_KEYCHAIN_PROMPT_UNSIGNED_ACT = 0x0020,
CSSM_ACL_KEYCHAIN_PROMPT_INVALID = 0x0040,
CSSM_ACL_KEYCHAIN_PROMPT_INVALID_ACT = 0x0080,
};
typedef struct cssm_acl_keychain_prompt_selector {
uint16 version;
uint16 flags;
} CSSM_ACL_KEYCHAIN_PROMPT_SELECTOR;
typedef uint32 CSSM_ACL_PREAUTH_TRACKING_STATE;
enum {
CSSM_ACL_PREAUTH_TRACKING_COUNT_MASK = 0xff,
CSSM_ACL_PREAUTH_TRACKING_BLOCKED = 0,
CSSM_ACL_PREAUTH_TRACKING_UNKNOWN = 0x40000000,
CSSM_ACL_PREAUTH_TRACKING_AUTHORIZED = 0x80000000
};
enum {
CSSM_DB_ACCESS_RESET = 0x10000
};
enum
{
CSSM_ALGID_APPLE_YARROW = CSSM_ALGID_VENDOR_DEFINED,
CSSM_ALGID_AES,
CSSM_ALGID_FEE,
CSSM_ALGID_FEE_MD5,
CSSM_ALGID_FEE_SHA1,
CSSM_ALGID_FEED,
CSSM_ALGID_FEEDEXP,
CSSM_ALGID_ASC,
CSSM_ALGID_SHA1HMAC_LEGACY,
CSSM_ALGID_KEYCHAIN_KEY,
CSSM_ALGID_PKCS12_PBE_ENCR,
CSSM_ALGID_PKCS12_PBE_MAC,
CSSM_ALGID_SECURE_PASSPHRASE,
CSSM_ALGID_PBE_OPENSSL_MD5,
CSSM_ALGID_SHA256,
CSSM_ALGID_SHA384,
CSSM_ALGID_SHA512,
CSSM_ALGID_ENTROPY_DEFAULT,
CSSM_ALGID_SHA224,
CSSM_ALGID_SHA224WithRSA,
CSSM_ALGID_SHA256WithRSA,
CSSM_ALGID_SHA384WithRSA,
CSSM_ALGID_SHA512WithRSA,
CSSM_ALGID_OPENSSH1,
CSSM_ALGID_SHA224WithECDSA,
CSSM_ALGID_SHA256WithECDSA,
CSSM_ALGID_SHA384WithECDSA,
CSSM_ALGID_SHA512WithECDSA,
CSSM_ALGID_ECDSA_SPECIFIED,
CSSM_ALGID_ECDH_X963_KDF,
CSSM_ALGID__FIRST_UNUSED
};
enum
{
CSSM_PADDING_APPLE_SSLv2 = CSSM_PADDING_VENDOR_DEFINED
};
enum {
CSSM_KEYBLOB_RAW_FORMAT_VENDOR_DEFINED = 0x80000000
};
enum {
CSSM_KEYBLOB_RAW_FORMAT_X509 = CSSM_KEYBLOB_RAW_FORMAT_VENDOR_DEFINED,
CSSM_KEYBLOB_RAW_FORMAT_OPENSSH,
CSSM_KEYBLOB_RAW_FORMAT_OPENSSL,
CSSM_KEYBLOB_RAW_FORMAT_OPENSSH2
};
enum
{
CSSM_CUSTOM_COMMON_ERROR_EXTENT = 0x00e0,
CSSM_ERRCODE_NO_USER_INTERACTION = 0x00e0,
CSSM_ERRCODE_USER_CANCELED = 0x00e1,
CSSM_ERRCODE_SERVICE_NOT_AVAILABLE = 0x00e2,
CSSM_ERRCODE_INSUFFICIENT_CLIENT_IDENTIFICATION = 0x00e3,
CSSM_ERRCODE_DEVICE_RESET = 0x00e4,
CSSM_ERRCODE_DEVICE_FAILED = 0x00e5,
CSSM_ERRCODE_IN_DARK_WAKE = 0x00e6
};
enum {
CSSMERR_CSSM_NO_USER_INTERACTION = CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_NO_USER_INTERACTION,
CSSMERR_AC_NO_USER_INTERACTION = CSSM_AC_BASE_ERROR + CSSM_ERRCODE_NO_USER_INTERACTION,
CSSMERR_CSP_NO_USER_INTERACTION = CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_NO_USER_INTERACTION,
CSSMERR_CL_NO_USER_INTERACTION = CSSM_CL_BASE_ERROR + CSSM_ERRCODE_NO_USER_INTERACTION,
CSSMERR_DL_NO_USER_INTERACTION = CSSM_DL_BASE_ERROR + CSSM_ERRCODE_NO_USER_INTERACTION,
CSSMERR_TP_NO_USER_INTERACTION = CSSM_TP_BASE_ERROR + CSSM_ERRCODE_NO_USER_INTERACTION,
CSSMERR_CSSM_USER_CANCELED = CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_USER_CANCELED,
CSSMERR_AC_USER_CANCELED = CSSM_AC_BASE_ERROR + CSSM_ERRCODE_USER_CANCELED,
CSSMERR_CSP_USER_CANCELED = CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_USER_CANCELED,
CSSMERR_CL_USER_CANCELED = CSSM_CL_BASE_ERROR + CSSM_ERRCODE_USER_CANCELED,
CSSMERR_DL_USER_CANCELED = CSSM_DL_BASE_ERROR + CSSM_ERRCODE_USER_CANCELED,
CSSMERR_TP_USER_CANCELED = CSSM_TP_BASE_ERROR + CSSM_ERRCODE_USER_CANCELED,
CSSMERR_CSSM_SERVICE_NOT_AVAILABLE = CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_SERVICE_NOT_AVAILABLE,
CSSMERR_AC_SERVICE_NOT_AVAILABLE = CSSM_AC_BASE_ERROR + CSSM_ERRCODE_SERVICE_NOT_AVAILABLE,
CSSMERR_CSP_SERVICE_NOT_AVAILABLE = CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_SERVICE_NOT_AVAILABLE,
CSSMERR_CL_SERVICE_NOT_AVAILABLE = CSSM_CL_BASE_ERROR + CSSM_ERRCODE_SERVICE_NOT_AVAILABLE,
CSSMERR_DL_SERVICE_NOT_AVAILABLE = CSSM_DL_BASE_ERROR + CSSM_ERRCODE_SERVICE_NOT_AVAILABLE,
CSSMERR_TP_SERVICE_NOT_AVAILABLE = CSSM_TP_BASE_ERROR + CSSM_ERRCODE_SERVICE_NOT_AVAILABLE,
CSSMERR_CSSM_INSUFFICIENT_CLIENT_IDENTIFICATION = CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_INSUFFICIENT_CLIENT_IDENTIFICATION,
CSSMERR_AC_INSUFFICIENT_CLIENT_IDENTIFICATION = CSSM_AC_BASE_ERROR + CSSM_ERRCODE_INSUFFICIENT_CLIENT_IDENTIFICATION,
CSSMERR_CSP_INSUFFICIENT_CLIENT_IDENTIFICATION = CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_INSUFFICIENT_CLIENT_IDENTIFICATION,
CSSMERR_CL_INSUFFICIENT_CLIENT_IDENTIFICATION = CSSM_CL_BASE_ERROR + CSSM_ERRCODE_INSUFFICIENT_CLIENT_IDENTIFICATION,
CSSMERR_DL_INSUFFICIENT_CLIENT_IDENTIFICATION = CSSM_DL_BASE_ERROR + CSSM_ERRCODE_INSUFFICIENT_CLIENT_IDENTIFICATION,
CSSMERR_TP_INSUFFICIENT_CLIENT_IDENTIFICATION = CSSM_TP_BASE_ERROR + CSSM_ERRCODE_INSUFFICIENT_CLIENT_IDENTIFICATION,
CSSMERR_CSSM_DEVICE_RESET = CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_DEVICE_RESET,
CSSMERR_AC_DEVICE_RESET = CSSM_AC_BASE_ERROR + CSSM_ERRCODE_DEVICE_RESET,
CSSMERR_CSP_DEVICE_RESET = CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_DEVICE_RESET,
CSSMERR_CL_DEVICE_RESET = CSSM_CL_BASE_ERROR + CSSM_ERRCODE_DEVICE_RESET,
CSSMERR_DL_DEVICE_RESET = CSSM_DL_BASE_ERROR + CSSM_ERRCODE_DEVICE_RESET,
CSSMERR_TP_DEVICE_RESET = CSSM_TP_BASE_ERROR + CSSM_ERRCODE_DEVICE_RESET,
CSSMERR_CSSM_DEVICE_FAILED = CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_DEVICE_FAILED,
CSSMERR_AC_DEVICE_FAILED = CSSM_AC_BASE_ERROR + CSSM_ERRCODE_DEVICE_FAILED,
CSSMERR_CSP_DEVICE_FAILED = CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_DEVICE_FAILED,
CSSMERR_CL_DEVICE_FAILED = CSSM_CL_BASE_ERROR + CSSM_ERRCODE_DEVICE_FAILED,
CSSMERR_DL_DEVICE_FAILED = CSSM_DL_BASE_ERROR + CSSM_ERRCODE_DEVICE_FAILED,
CSSMERR_TP_DEVICE_FAILED = CSSM_TP_BASE_ERROR + CSSM_ERRCODE_DEVICE_FAILED,
CSSMERR_CSSM_IN_DARK_WAKE = CSSM_CSSM_BASE_ERROR + CSSM_ERRCODE_IN_DARK_WAKE,
CSSMERR_AC_IN_DARK_WAKE = CSSM_AC_BASE_ERROR + CSSM_ERRCODE_IN_DARK_WAKE,
CSSMERR_CSP_IN_DARK_WAKE = CSSM_CSP_BASE_ERROR + CSSM_ERRCODE_IN_DARK_WAKE,
CSSMERR_CL_IN_DARK_WAKE = CSSM_CL_BASE_ERROR + CSSM_ERRCODE_IN_DARK_WAKE,
CSSMERR_DL_IN_DARK_WAKE = CSSM_DL_BASE_ERROR + CSSM_ERRCODE_IN_DARK_WAKE,
CSSMERR_TP_IN_DARK_WAKE = CSSM_TP_BASE_ERROR + CSSM_ERRCODE_IN_DARK_WAKE
};
enum {
CSSMERR_CSP_APPLE_ADD_APPLICATION_ACL_SUBJECT = CSSM_CSP_PRIVATE_ERROR + 0,
CSSMERR_CSP_APPLE_PUBLIC_KEY_INCOMPLETE = CSSM_CSP_PRIVATE_ERROR + 1,
CSSMERR_CSP_APPLE_SIGNATURE_MISMATCH = CSSM_CSP_PRIVATE_ERROR + 2,
CSSMERR_CSP_APPLE_INVALID_KEY_START_DATE = CSSM_CSP_PRIVATE_ERROR + 3,
CSSMERR_CSP_APPLE_INVALID_KEY_END_DATE = CSSM_CSP_PRIVATE_ERROR + 4,
CSSMERR_CSPDL_APPLE_DL_CONVERSION_ERROR = CSSM_CSP_PRIVATE_ERROR + 5,
CSSMERR_CSP_APPLE_SSLv2_ROLLBACK = CSSM_CSP_PRIVATE_ERROR + 6
};
enum
{
CSSM_DL_DB_RECORD_GENERIC_PASSWORD = CSSM_DB_RECORDTYPE_APP_DEFINED_START + 0,
CSSM_DL_DB_RECORD_INTERNET_PASSWORD = CSSM_DB_RECORDTYPE_APP_DEFINED_START + 1,
CSSM_DL_DB_RECORD_APPLESHARE_PASSWORD = CSSM_DB_RECORDTYPE_APP_DEFINED_START + 2,
CSSM_DL_DB_RECORD_X509_CERTIFICATE = CSSM_DB_RECORDTYPE_APP_DEFINED_START + 0x1000,
CSSM_DL_DB_RECORD_USER_TRUST,
CSSM_DL_DB_RECORD_X509_CRL,
CSSM_DL_DB_RECORD_UNLOCK_REFERRAL,
CSSM_DL_DB_RECORD_EXTENDED_ATTRIBUTE,
CSSM_DL_DB_RECORD_METADATA = CSSM_DB_RECORDTYPE_APP_DEFINED_START + 0x8000
};
enum {
CSSM_APPLEFILEDL_TOGGLE_AUTOCOMMIT,
CSSM_APPLEFILEDL_COMMIT,
CSSM_APPLEFILEDL_ROLLBACK
};
enum {
CSSM_APPLE_UNLOCK_TYPE_KEY_DIRECT = 1,
CSSM_APPLE_UNLOCK_TYPE_WRAPPED_PRIVATE = 2
};
enum
{
CSSMERR_APPLEDL_INVALID_OPEN_PARAMETERS = CSSM_DL_PRIVATE_ERROR + 0,
CSSMERR_APPLEDL_DISK_FULL = CSSM_DL_PRIVATE_ERROR + 1,
CSSMERR_APPLEDL_QUOTA_EXCEEDED = CSSM_DL_PRIVATE_ERROR + 2,
CSSMERR_APPLEDL_FILE_TOO_BIG = CSSM_DL_PRIVATE_ERROR + 3,
CSSMERR_APPLEDL_INVALID_DATABASE_BLOB = CSSM_DL_PRIVATE_ERROR + 4,
CSSMERR_APPLEDL_INVALID_KEY_BLOB = CSSM_DL_PRIVATE_ERROR + 5,
CSSMERR_APPLEDL_INCOMPATIBLE_DATABASE_BLOB = CSSM_DL_PRIVATE_ERROR + 6,
CSSMERR_APPLEDL_INCOMPATIBLE_KEY_BLOB = CSSM_DL_PRIVATE_ERROR + 7,
};
enum
{
CSSMERR_APPLETP_HOSTNAME_MISMATCH = CSSM_TP_PRIVATE_ERROR + 0,
CSSMERR_APPLETP_UNKNOWN_CRITICAL_EXTEN = CSSM_TP_PRIVATE_ERROR + 1,
CSSMERR_APPLETP_NO_BASIC_CONSTRAINTS = CSSM_TP_PRIVATE_ERROR + 2,
CSSMERR_APPLETP_INVALID_CA = CSSM_TP_PRIVATE_ERROR + 3,
CSSMERR_APPLETP_INVALID_AUTHORITY_ID = CSSM_TP_PRIVATE_ERROR + 4,
CSSMERR_APPLETP_INVALID_SUBJECT_ID = CSSM_TP_PRIVATE_ERROR + 5,
CSSMERR_APPLETP_INVALID_KEY_USAGE = CSSM_TP_PRIVATE_ERROR + 6,
CSSMERR_APPLETP_INVALID_EXTENDED_KEY_USAGE = CSSM_TP_PRIVATE_ERROR + 7,
CSSMERR_APPLETP_INVALID_ID_LINKAGE = CSSM_TP_PRIVATE_ERROR + 8,
CSSMERR_APPLETP_PATH_LEN_CONSTRAINT = CSSM_TP_PRIVATE_ERROR + 9,
CSSMERR_APPLETP_INVALID_ROOT = CSSM_TP_PRIVATE_ERROR + 10,
CSSMERR_APPLETP_CRL_EXPIRED = CSSM_TP_PRIVATE_ERROR + 11,
CSSMERR_APPLETP_CRL_NOT_VALID_YET = CSSM_TP_PRIVATE_ERROR + 12,
CSSMERR_APPLETP_CRL_NOT_FOUND = CSSM_TP_PRIVATE_ERROR + 13,
CSSMERR_APPLETP_CRL_SERVER_DOWN = CSSM_TP_PRIVATE_ERROR + 14,
CSSMERR_APPLETP_CRL_BAD_URI = CSSM_TP_PRIVATE_ERROR + 15,
CSSMERR_APPLETP_UNKNOWN_CERT_EXTEN = CSSM_TP_PRIVATE_ERROR + 16,
CSSMERR_APPLETP_UNKNOWN_CRL_EXTEN = CSSM_TP_PRIVATE_ERROR + 17,
CSSMERR_APPLETP_CRL_NOT_TRUSTED = CSSM_TP_PRIVATE_ERROR + 18,
CSSMERR_APPLETP_CRL_INVALID_ANCHOR_CERT = CSSM_TP_PRIVATE_ERROR + 19,
CSSMERR_APPLETP_CRL_POLICY_FAIL = CSSM_TP_PRIVATE_ERROR + 20,
CSSMERR_APPLETP_IDP_FAIL = CSSM_TP_PRIVATE_ERROR + 21,
CSSMERR_APPLETP_CERT_NOT_FOUND_FROM_ISSUER = CSSM_TP_PRIVATE_ERROR + 22,
CSSMERR_APPLETP_BAD_CERT_FROM_ISSUER = CSSM_TP_PRIVATE_ERROR + 23,
CSSMERR_APPLETP_SMIME_EMAIL_ADDRS_NOT_FOUND = CSSM_TP_PRIVATE_ERROR + 24,
CSSMERR_APPLETP_SMIME_BAD_EXT_KEY_USE = CSSM_TP_PRIVATE_ERROR + 25,
CSSMERR_APPLETP_SMIME_BAD_KEY_USE = CSSM_TP_PRIVATE_ERROR + 26,
CSSMERR_APPLETP_SMIME_KEYUSAGE_NOT_CRITICAL = CSSM_TP_PRIVATE_ERROR + 27,
CSSMERR_APPLETP_SMIME_NO_EMAIL_ADDRS = CSSM_TP_PRIVATE_ERROR + 28,
CSSMERR_APPLETP_SMIME_SUBJ_ALT_NAME_NOT_CRIT = CSSM_TP_PRIVATE_ERROR + 29,
CSSMERR_APPLETP_SSL_BAD_EXT_KEY_USE = CSSM_TP_PRIVATE_ERROR + 30,
CSSMERR_APPLETP_OCSP_BAD_RESPONSE = CSSM_TP_PRIVATE_ERROR + 31,
CSSMERR_APPLETP_OCSP_BAD_REQUEST = CSSM_TP_PRIVATE_ERROR + 32,
CSSMERR_APPLETP_OCSP_UNAVAILABLE = CSSM_TP_PRIVATE_ERROR + 33,
CSSMERR_APPLETP_OCSP_STATUS_UNRECOGNIZED = CSSM_TP_PRIVATE_ERROR + 34,
CSSMERR_APPLETP_INCOMPLETE_REVOCATION_CHECK = CSSM_TP_PRIVATE_ERROR + 35,
CSSMERR_APPLETP_NETWORK_FAILURE = CSSM_TP_PRIVATE_ERROR + 36,
CSSMERR_APPLETP_OCSP_NOT_TRUSTED = CSSM_TP_PRIVATE_ERROR + 37,
CSSMERR_APPLETP_OCSP_INVALID_ANCHOR_CERT = CSSM_TP_PRIVATE_ERROR + 38,
CSSMERR_APPLETP_OCSP_SIG_ERROR = CSSM_TP_PRIVATE_ERROR + 39,
CSSMERR_APPLETP_OCSP_NO_SIGNER = CSSM_TP_PRIVATE_ERROR + 40,
CSSMERR_APPLETP_OCSP_RESP_MALFORMED_REQ = CSSM_TP_PRIVATE_ERROR + 41,
CSSMERR_APPLETP_OCSP_RESP_INTERNAL_ERR = CSSM_TP_PRIVATE_ERROR + 42,
CSSMERR_APPLETP_OCSP_RESP_TRY_LATER = CSSM_TP_PRIVATE_ERROR + 43,
CSSMERR_APPLETP_OCSP_RESP_SIG_REQUIRED = CSSM_TP_PRIVATE_ERROR + 44,
CSSMERR_APPLETP_OCSP_RESP_UNAUTHORIZED = CSSM_TP_PRIVATE_ERROR + 45,
CSSMERR_APPLETP_OCSP_NONCE_MISMATCH = CSSM_TP_PRIVATE_ERROR + 46,
CSSMERR_APPLETP_CS_BAD_CERT_CHAIN_LENGTH = CSSM_TP_PRIVATE_ERROR + 47,
CSSMERR_APPLETP_CS_NO_BASIC_CONSTRAINTS = CSSM_TP_PRIVATE_ERROR + 48,
CSSMERR_APPLETP_CS_BAD_PATH_LENGTH = CSSM_TP_PRIVATE_ERROR + 49,
CSSMERR_APPLETP_CS_NO_EXTENDED_KEY_USAGE = CSSM_TP_PRIVATE_ERROR + 50,
CSSMERR_APPLETP_CODE_SIGN_DEVELOPMENT = CSSM_TP_PRIVATE_ERROR + 51,
CSSMERR_APPLETP_RS_BAD_CERT_CHAIN_LENGTH = CSSM_TP_PRIVATE_ERROR + 52,
CSSMERR_APPLETP_RS_BAD_EXTENDED_KEY_USAGE = CSSM_TP_PRIVATE_ERROR + 53,
CSSMERR_APPLETP_TRUST_SETTING_DENY = CSSM_TP_PRIVATE_ERROR + 54,
CSSMERR_APPLETP_INVALID_EMPTY_SUBJECT = CSSM_TP_PRIVATE_ERROR + 55,
CSSMERR_APPLETP_UNKNOWN_QUAL_CERT_STATEMENT = CSSM_TP_PRIVATE_ERROR + 56,
CSSMERR_APPLETP_MISSING_REQUIRED_EXTENSION = CSSM_TP_PRIVATE_ERROR + 57,
CSSMERR_APPLETP_EXT_KEYUSAGE_NOT_CRITICAL = CSSM_TP_PRIVATE_ERROR + 58,
CSSMERR_APPLETP_IDENTIFIER_MISSING = CSSM_TP_PRIVATE_ERROR + 59,
CSSMERR_APPLETP_CA_PIN_MISMATCH = CSSM_TP_PRIVATE_ERROR + 60
};
enum
{
CSSMERR_APPLE_DOTMAC_REQ_QUEUED = CSSM_TP_PRIVATE_ERROR + 100,
CSSMERR_APPLE_DOTMAC_REQ_REDIRECT = CSSM_TP_PRIVATE_ERROR + 101,
CSSMERR_APPLE_DOTMAC_REQ_SERVER_ERR = CSSM_TP_PRIVATE_ERROR + 102,
CSSMERR_APPLE_DOTMAC_REQ_SERVER_PARAM = CSSM_TP_PRIVATE_ERROR + 103,
CSSMERR_APPLE_DOTMAC_REQ_SERVER_AUTH = CSSM_TP_PRIVATE_ERROR + 104,
CSSMERR_APPLE_DOTMAC_REQ_SERVER_UNIMPL = CSSM_TP_PRIVATE_ERROR + 105,
CSSMERR_APPLE_DOTMAC_REQ_SERVER_NOT_AVAIL = CSSM_TP_PRIVATE_ERROR + 106,
CSSMERR_APPLE_DOTMAC_REQ_SERVER_ALREADY_EXIST = CSSM_TP_PRIVATE_ERROR + 107,
CSSMERR_APPLE_DOTMAC_REQ_SERVER_SERVICE_ERROR = CSSM_TP_PRIVATE_ERROR + 108,
CSSMERR_APPLE_DOTMAC_REQ_IS_PENDING = CSSM_TP_PRIVATE_ERROR + 109,
CSSMERR_APPLE_DOTMAC_NO_REQ_PENDING = CSSM_TP_PRIVATE_ERROR + 110,
CSSMERR_APPLE_DOTMAC_CSR_VERIFY_FAIL = CSSM_TP_PRIVATE_ERROR + 111,
CSSMERR_APPLE_DOTMAC_FAILED_CONSISTENCY_CHECK = CSSM_TP_PRIVATE_ERROR + 112
};
enum
{
CSSM_APPLEDL_OPEN_PARAMETERS_VERSION = 1
};
enum cssm_appledl_open_parameters_mask
{
kCSSM_APPLEDL_MASK_MODE = (1 << 0)
};
typedef struct cssm_appledl_open_parameters
{
uint32 length;
uint32 version;
CSSM_BOOL autoCommit;
uint32 mask;
mode_t mode;
} CSSM_APPLEDL_OPEN_PARAMETERS, *CSSM_APPLEDL_OPEN_PARAMETERS_PTR;
enum
{
CSSM_APPLECSPDL_DB_LOCK = 0,
CSSM_APPLECSPDL_DB_UNLOCK = 1,
CSSM_APPLECSPDL_DB_GET_SETTINGS = 2,
CSSM_APPLECSPDL_DB_SET_SETTINGS = 3,
CSSM_APPLECSPDL_DB_IS_LOCKED = 4,
CSSM_APPLECSPDL_DB_CHANGE_PASSWORD =5,
CSSM_APPLECSPDL_DB_GET_HANDLE = 6,
CSSM_APPLESCPDL_CSP_GET_KEYHANDLE = 7,
CSSM_APPLE_PRIVATE_CSPDL_CODE_8 = 8,
CSSM_APPLE_PRIVATE_CSPDL_CODE_9 = 9,
CSSM_APPLE_PRIVATE_CSPDL_CODE_10 = 10,
CSSM_APPLE_PRIVATE_CSPDL_CODE_11 = 11,
CSSM_APPLE_PRIVATE_CSPDL_CODE_12 = 12,
CSSM_APPLE_PRIVATE_CSPDL_CODE_13 = 13,
CSSM_APPLE_PRIVATE_CSPDL_CODE_14 = 14,
CSSM_APPLE_PRIVATE_CSPDL_CODE_15 = 15,
CSSM_APPLE_PRIVATE_CSPDL_CODE_16 = 16,
CSSM_APPLE_PRIVATE_CSPDL_CODE_17 = 17,
CSSM_APPLE_PRIVATE_CSPDL_CODE_18 = 18,
CSSM_APPLECSP_KEYDIGEST = 0x100
};
typedef struct cssm_applecspdl_db_settings_parameters
{
uint32 idleTimeout;
uint8 lockOnSleep;
} CSSM_APPLECSPDL_DB_SETTINGS_PARAMETERS, *CSSM_APPLECSPDL_DB_SETTINGS_PARAMETERS_PTR;
typedef struct cssm_applecspdl_db_is_locked_parameters
{
uint8 isLocked;
} CSSM_APPLECSPDL_DB_IS_LOCKED_PARAMETERS, *CSSM_APPLECSPDL_DB_IS_LOCKED_PARAMETERS_PTR;
typedef struct cssm_applecspdl_db_change_password_parameters
{
CSSM_ACCESS_CREDENTIALS *accessCredentials;
} CSSM_APPLECSPDL_DB_CHANGE_PASSWORD_PARAMETERS, *CSSM_APPLECSPDL_DB_CHANGE_PASSWORD_PARAMETERS_PTR;
enum {
CSSM_KEYBLOB_WRAPPED_FORMAT_APPLE_CUSTOM = 100,
CSSM_KEYBLOB_WRAPPED_FORMAT_OPENSSL,
CSSM_KEYBLOB_WRAPPED_FORMAT_OPENSSH1
};
enum {
CSSM_ATTRIBUTE_VENDOR_DEFINED = 0x800000
};
enum {
CSSM_ATTRIBUTE_PUBLIC_KEY =
(CSSM_ATTRIBUTE_DATA_KEY | (CSSM_ATTRIBUTE_VENDOR_DEFINED + 0)),
CSSM_ATTRIBUTE_FEE_PRIME_TYPE =
(CSSM_ATTRIBUTE_DATA_UINT32 | (CSSM_ATTRIBUTE_VENDOR_DEFINED + 1)),
CSSM_ATTRIBUTE_FEE_CURVE_TYPE =
(CSSM_ATTRIBUTE_DATA_UINT32 | (CSSM_ATTRIBUTE_VENDOR_DEFINED + 2)),
CSSM_ATTRIBUTE_ASC_OPTIMIZATION =
(CSSM_ATTRIBUTE_DATA_UINT32 | (CSSM_ATTRIBUTE_VENDOR_DEFINED + 3)),
CSSM_ATTRIBUTE_RSA_BLINDING =
(CSSM_ATTRIBUTE_DATA_UINT32 | (CSSM_ATTRIBUTE_VENDOR_DEFINED + 4)),
CSSM_ATTRIBUTE_PARAM_KEY =
(CSSM_ATTRIBUTE_DATA_KEY | (CSSM_ATTRIBUTE_VENDOR_DEFINED + 5)),
CSSM_ATTRIBUTE_PROMPT =
(CSSM_ATTRIBUTE_DATA_CSSM_DATA | (CSSM_ATTRIBUTE_VENDOR_DEFINED + 6)),
CSSM_ATTRIBUTE_ALERT_TITLE =
(CSSM_ATTRIBUTE_DATA_CSSM_DATA | (CSSM_ATTRIBUTE_VENDOR_DEFINED + 7)),
CSSM_ATTRIBUTE_VERIFY_PASSPHRASE =
(CSSM_ATTRIBUTE_DATA_UINT32 | (CSSM_ATTRIBUTE_VENDOR_DEFINED + 8))
};
enum {
CSSM_FEE_PRIME_TYPE_DEFAULT = 0,
CSSM_FEE_PRIME_TYPE_MERSENNE,
CSSM_FEE_PRIME_TYPE_FEE,
CSSM_FEE_PRIME_TYPE_GENERAL
};
enum {
CSSM_FEE_CURVE_TYPE_DEFAULT = 0,
CSSM_FEE_CURVE_TYPE_MONTGOMERY,
CSSM_FEE_CURVE_TYPE_WEIERSTRASS,
CSSM_FEE_CURVE_TYPE_ANSI_X9_62
};
enum {
CSSM_ASC_OPTIMIZE_DEFAULT = 0,
CSSM_ASC_OPTIMIZE_SIZE,
CSSM_ASC_OPTIMIZE_SECURITY,
CSSM_ASC_OPTIMIZE_TIME,
CSSM_ASC_OPTIMIZE_TIME_SIZE,
CSSM_ASC_OPTIMIZE_ASCII,
};
enum {
CSSM_KEYATTR_PARTIAL = 0x00010000,
CSSM_KEYATTR_PUBLIC_KEY_ENCRYPT = 0x00020000
};
typedef struct {
const char *string;
const CSSM_OID *oid;
} CSSM_APPLE_TP_NAME_OID;
typedef struct {
CSSM_CSP_HANDLE cspHand;
CSSM_CL_HANDLE clHand;
uint32 serialNumber;
uint32 numSubjectNames;
CSSM_APPLE_TP_NAME_OID *subjectNames;
uint32 numIssuerNames;
CSSM_APPLE_TP_NAME_OID *issuerNames;
CSSM_X509_NAME_PTR issuerNameX509;
const CSSM_KEY *certPublicKey;
const CSSM_KEY *issuerPrivateKey;
CSSM_ALGORITHMS signatureAlg;
CSSM_OID signatureOid;
uint32 notBefore;
uint32 notAfter;
uint32 numExtensions;
CE_DataAndType *extensions;
const char *challengeString;
} CSSM_APPLE_TP_CERT_REQUEST;
typedef struct {
uint32 Version;
uint32 ServerNameLen;
const char *ServerName;
uint32 Flags;
} CSSM_APPLE_TP_SSL_OPTIONS;
typedef uint32 CSSM_APPLE_TP_CRL_OPT_FLAGS;
enum {
CSSM_TP_ACTION_REQUIRE_CRL_PER_CERT = 0x00000001,
CSSM_TP_ACTION_FETCH_CRL_FROM_NET = 0x00000002,
CSSM_TP_ACTION_CRL_SUFFICIENT = 0x00000004,
CSSM_TP_ACTION_REQUIRE_CRL_IF_PRESENT = 0x00000008
};
typedef struct {
uint32 Version;
CSSM_APPLE_TP_CRL_OPT_FLAGS CrlFlags;
CSSM_DL_DB_HANDLE_PTR crlStore;
} CSSM_APPLE_TP_CRL_OPTIONS;
typedef struct {
uint32 Version;
CE_KeyUsage IntendedUsage;
uint32 SenderEmailLen;
const char *SenderEmail;
} CSSM_APPLE_TP_SMIME_OPTIONS;
typedef uint32 CSSM_APPLE_TP_ACTION_FLAGS;
enum {
CSSM_TP_ACTION_ALLOW_EXPIRED = 0x00000001,
CSSM_TP_ACTION_LEAF_IS_CA = 0x00000002,
CSSM_TP_ACTION_FETCH_CERT_FROM_NET = 0x00000004,
CSSM_TP_ACTION_ALLOW_EXPIRED_ROOT = 0x00000008,
CSSM_TP_ACTION_REQUIRE_REV_PER_CERT = 0x00000010,
CSSM_TP_ACTION_TRUST_SETTINGS = 0x00000020,
CSSM_TP_ACTION_IMPLICIT_ANCHORS = 0x00000040
};
typedef struct {
uint32 Version;
CSSM_APPLE_TP_ACTION_FLAGS ActionFlags;
} CSSM_APPLE_TP_ACTION_DATA;
typedef uint32 CSSM_TP_APPLE_CERT_STATUS;
enum
{
CSSM_CERT_STATUS_EXPIRED = 0x00000001,
CSSM_CERT_STATUS_NOT_VALID_YET = 0x00000002,
CSSM_CERT_STATUS_IS_IN_INPUT_CERTS = 0x00000004,
CSSM_CERT_STATUS_IS_IN_ANCHORS = 0x00000008,
CSSM_CERT_STATUS_IS_ROOT = 0x00000010,
CSSM_CERT_STATUS_IS_FROM_NET = 0x00000020,
CSSM_CERT_STATUS_TRUST_SETTINGS_FOUND_USER = 0x00000040,
CSSM_CERT_STATUS_TRUST_SETTINGS_FOUND_ADMIN = 0x00000080,
CSSM_CERT_STATUS_TRUST_SETTINGS_FOUND_SYSTEM = 0x00000100,
CSSM_CERT_STATUS_TRUST_SETTINGS_TRUST = 0x00000200,
CSSM_CERT_STATUS_TRUST_SETTINGS_DENY = 0x00000400,
CSSM_CERT_STATUS_TRUST_SETTINGS_IGNORED_ERROR = 0x00000800
};
typedef struct {
CSSM_TP_APPLE_CERT_STATUS StatusBits;
uint32 NumStatusCodes;
CSSM_RETURN *StatusCodes;
uint32 Index;
CSSM_DL_DB_HANDLE DlDbHandle;
CSSM_DB_UNIQUE_RECORD_PTR UniqueRecord;
} CSSM_TP_APPLE_EVIDENCE_INFO;
typedef struct
{
uint32 Version;
} CSSM_TP_APPLE_EVIDENCE_HEADER;
enum
{
CSSM_EVIDENCE_FORM_APPLE_HEADER = 0x80000000 + 0,
CSSM_EVIDENCE_FORM_APPLE_CERTGROUP = 0x80000000 + 1,
CSSM_EVIDENCE_FORM_APPLE_CERT_INFO = 0x80000000 + 2
};
enum {
CSSM_APPLEX509CL_OBTAIN_CSR,
CSSM_APPLEX509CL_VERIFY_CSR
};
typedef struct {
CSSM_X509_NAME_PTR subjectNameX509;
CSSM_ALGORITHMS signatureAlg;
CSSM_OID signatureOid;
CSSM_CSP_HANDLE cspHand;
const CSSM_KEY *subjectPublicKey;
const CSSM_KEY *subjectPrivateKey;
const char *challengeString;
} CSSM_APPLE_CL_CSR_REQUEST;
void cssmPerror(const char *how, CSSM_RETURN error);
bool cssmOidToAlg(const CSSM_OID *oid, CSSM_ALGORITHMS *alg);
const CSSM_OID *cssmAlgToOid(CSSM_ALGORITHMS algId);
}
extern "C" {
typedef uint32 CSSM_MANAGER_EVENT_TYPES;
typedef struct cssm_manager_event_notification {
CSSM_SERVICE_MASK DestinationModuleManagerType;
CSSM_SERVICE_MASK SourceModuleManagerType;
CSSM_MANAGER_EVENT_TYPES Event;
uint32 EventId;
CSSM_DATA EventData;
} CSSM_MANAGER_EVENT_NOTIFICATION __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_MANAGER_EVENT_NOTIFICATION_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
CSSM_RETURN
CSSM_Init (const CSSM_VERSION *Version,
CSSM_PRIVILEGE_SCOPE Scope,
const CSSM_GUID *CallerGuid,
CSSM_KEY_HIERARCHY KeyHierarchy,
CSSM_PVC_MODE *PvcPolicy,
const void *Reserved)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_Terminate (void)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_ModuleLoad (const CSSM_GUID *ModuleGuid,
CSSM_KEY_HIERARCHY KeyHierarchy,
CSSM_API_ModuleEventHandler AppNotifyCallback,
void *AppNotifyCallbackCtx)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_ModuleUnload (const CSSM_GUID *ModuleGuid,
CSSM_API_ModuleEventHandler AppNotifyCallback,
void *AppNotifyCallbackCtx)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_Introduce (const CSSM_GUID *ModuleID,
CSSM_KEY_HIERARCHY KeyHierarchy)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_Unintroduce (const CSSM_GUID *ModuleID)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_ModuleAttach (const CSSM_GUID *ModuleGuid,
const CSSM_VERSION *Version,
const CSSM_API_MEMORY_FUNCS *MemoryFuncs,
uint32 SubserviceID,
CSSM_SERVICE_TYPE SubServiceType,
CSSM_ATTACH_FLAGS AttachFlags,
CSSM_KEY_HIERARCHY KeyHierarchy,
CSSM_FUNC_NAME_ADDR *FunctionTable,
uint32 NumFunctionTable,
const void *Reserved,
CSSM_MODULE_HANDLE_PTR NewModuleHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_ModuleDetach (CSSM_MODULE_HANDLE ModuleHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_SetPrivilege (CSSM_PRIVILEGE Privilege)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GetPrivilege (CSSM_PRIVILEGE *Privilege)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GetModuleGUIDFromHandle (CSSM_MODULE_HANDLE ModuleHandle,
CSSM_GUID_PTR ModuleGUID)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GetSubserviceUIDFromHandle (CSSM_MODULE_HANDLE ModuleHandle,
CSSM_SUBSERVICE_UID_PTR SubserviceUID)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_ListAttachedModuleManagers (uint32 *NumberOfModuleManagers,
CSSM_GUID_PTR ModuleManagerGuids)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GetAPIMemoryFunctions (CSSM_MODULE_HANDLE AddInHandle,
CSSM_API_MEMORY_FUNCS_PTR AppMemoryFuncs)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_CreateSignatureContext (CSSM_CSP_HANDLE CSPHandle,
CSSM_ALGORITHMS AlgorithmID,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_KEY *Key,
CSSM_CC_HANDLE *NewContextHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_CreateSymmetricContext (CSSM_CSP_HANDLE CSPHandle,
CSSM_ALGORITHMS AlgorithmID,
CSSM_ENCRYPT_MODE Mode,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_KEY *Key,
const CSSM_DATA *InitVector,
CSSM_PADDING Padding,
void *Reserved,
CSSM_CC_HANDLE *NewContextHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_CreateDigestContext (CSSM_CSP_HANDLE CSPHandle,
CSSM_ALGORITHMS AlgorithmID,
CSSM_CC_HANDLE *NewContextHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_CreateMacContext (CSSM_CSP_HANDLE CSPHandle,
CSSM_ALGORITHMS AlgorithmID,
const CSSM_KEY *Key,
CSSM_CC_HANDLE *NewContextHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_CreateRandomGenContext (CSSM_CSP_HANDLE CSPHandle,
CSSM_ALGORITHMS AlgorithmID,
const CSSM_CRYPTO_DATA *Seed,
CSSM_SIZE Length,
CSSM_CC_HANDLE *NewContextHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_CreateAsymmetricContext (CSSM_CSP_HANDLE CSPHandle,
CSSM_ALGORITHMS AlgorithmID,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_KEY *Key,
CSSM_PADDING Padding,
CSSM_CC_HANDLE *NewContextHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_CreateDeriveKeyContext (CSSM_CSP_HANDLE CSPHandle,
CSSM_ALGORITHMS AlgorithmID,
CSSM_KEY_TYPE DeriveKeyType,
uint32 DeriveKeyLengthInBits,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_KEY *BaseKey,
uint32 IterationCount,
const CSSM_DATA *Salt,
const CSSM_CRYPTO_DATA *Seed,
CSSM_CC_HANDLE *NewContextHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_CreateKeyGenContext (CSSM_CSP_HANDLE CSPHandle,
CSSM_ALGORITHMS AlgorithmID,
uint32 KeySizeInBits,
const CSSM_CRYPTO_DATA *Seed,
const CSSM_DATA *Salt,
const CSSM_DATE *StartDate,
const CSSM_DATE *EndDate,
const CSSM_DATA *Params,
CSSM_CC_HANDLE *NewContextHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_CreatePassThroughContext (CSSM_CSP_HANDLE CSPHandle,
const CSSM_KEY *Key,
CSSM_CC_HANDLE *NewContextHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GetContext (CSSM_CC_HANDLE CCHandle,
CSSM_CONTEXT_PTR *Context)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_FreeContext (CSSM_CONTEXT_PTR Context)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_SetContext (CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DeleteContext (CSSM_CC_HANDLE CCHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GetContextAttribute (const CSSM_CONTEXT *Context,
uint32 AttributeType,
CSSM_CONTEXT_ATTRIBUTE_PTR *ContextAttribute)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_UpdateContextAttributes (CSSM_CC_HANDLE CCHandle,
uint32 NumberOfAttributes,
const CSSM_CONTEXT_ATTRIBUTE *ContextAttributes)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DeleteContextAttributes (CSSM_CC_HANDLE CCHandle,
uint32 NumberOfAttributes,
const CSSM_CONTEXT_ATTRIBUTE *ContextAttributes)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_Login (CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_DATA *LoginName,
const void *Reserved)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_Logout (CSSM_CSP_HANDLE CSPHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_GetLoginAcl (CSSM_CSP_HANDLE CSPHandle,
const CSSM_STRING *SelectionTag,
uint32 *NumberOfAclInfos,
CSSM_ACL_ENTRY_INFO_PTR *AclInfos)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_ChangeLoginAcl (CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_ACL_EDIT *AclEdit)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GetKeyAcl (CSSM_CSP_HANDLE CSPHandle,
const CSSM_KEY *Key,
const CSSM_STRING *SelectionTag,
uint32 *NumberOfAclInfos,
CSSM_ACL_ENTRY_INFO_PTR *AclInfos)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_ChangeKeyAcl (CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_ACL_EDIT *AclEdit,
const CSSM_KEY *Key)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GetKeyOwner (CSSM_CSP_HANDLE CSPHandle,
const CSSM_KEY *Key,
CSSM_ACL_OWNER_PROTOTYPE_PTR Owner)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_ChangeKeyOwner (CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_KEY *Key,
const CSSM_ACL_OWNER_PROTOTYPE *NewOwner)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_GetLoginOwner (CSSM_CSP_HANDLE CSPHandle,
CSSM_ACL_OWNER_PROTOTYPE_PTR Owner)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_ChangeLoginOwner (CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_ACL_OWNER_PROTOTYPE *NewOwner)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_SignData (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount,
CSSM_ALGORITHMS DigestAlgorithm,
CSSM_DATA_PTR Signature)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_SignDataInit (CSSM_CC_HANDLE CCHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_SignDataUpdate (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_SignDataFinal (CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR Signature)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_VerifyData (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount,
CSSM_ALGORITHMS DigestAlgorithm,
const CSSM_DATA *Signature)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_VerifyDataInit (CSSM_CC_HANDLE CCHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_VerifyDataUpdate (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_VerifyDataFinal (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *Signature)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DigestData (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount,
CSSM_DATA_PTR Digest)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DigestDataInit (CSSM_CC_HANDLE CCHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DigestDataUpdate (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DigestDataClone (CSSM_CC_HANDLE CCHandle,
CSSM_CC_HANDLE *ClonednewCCHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DigestDataFinal (CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR Digest)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GenerateMac (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount,
CSSM_DATA_PTR Mac)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GenerateMacInit (CSSM_CC_HANDLE CCHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GenerateMacUpdate (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GenerateMacFinal (CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR Mac)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_VerifyMac (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount,
const CSSM_DATA *Mac)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_VerifyMacInit (CSSM_CC_HANDLE CCHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_VerifyMacUpdate (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_VerifyMacFinal (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *Mac)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_QuerySize (CSSM_CC_HANDLE CCHandle,
CSSM_BOOL Encrypt,
uint32 QuerySizeCount,
CSSM_QUERY_SIZE_DATA_PTR DataBlockSizes)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_EncryptData (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *ClearBufs,
uint32 ClearBufCount,
CSSM_DATA_PTR CipherBufs,
uint32 CipherBufCount,
CSSM_SIZE *bytesEncrypted,
CSSM_DATA_PTR RemData)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_EncryptDataP (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *ClearBufs,
uint32 ClearBufCount,
CSSM_DATA_PTR CipherBufs,
uint32 CipherBufCount,
CSSM_SIZE *bytesEncrypted,
CSSM_DATA_PTR RemData,
CSSM_PRIVILEGE Privilege)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_EncryptDataInit (CSSM_CC_HANDLE CCHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_EncryptDataInitP (CSSM_CC_HANDLE CCHandle,
CSSM_PRIVILEGE Privilege)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_EncryptDataUpdate (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *ClearBufs,
uint32 ClearBufCount,
CSSM_DATA_PTR CipherBufs,
uint32 CipherBufCount,
CSSM_SIZE *bytesEncrypted)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_EncryptDataFinal (CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR RemData)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DecryptData (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CipherBufs,
uint32 CipherBufCount,
CSSM_DATA_PTR ClearBufs,
uint32 ClearBufCount,
CSSM_SIZE *bytesDecrypted,
CSSM_DATA_PTR RemData)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DecryptDataP (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CipherBufs,
uint32 CipherBufCount,
CSSM_DATA_PTR ClearBufs,
uint32 ClearBufCount,
CSSM_SIZE *bytesDecrypted,
CSSM_DATA_PTR RemData,
CSSM_PRIVILEGE Privilege)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DecryptDataInit (CSSM_CC_HANDLE CCHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DecryptDataInitP (CSSM_CC_HANDLE CCHandle,
CSSM_PRIVILEGE Privilege)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DecryptDataUpdate (CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CipherBufs,
uint32 CipherBufCount,
CSSM_DATA_PTR ClearBufs,
uint32 ClearBufCount,
CSSM_SIZE *bytesDecrypted)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DecryptDataFinal (CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR RemData)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_QueryKeySizeInBits (CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_KEY *Key,
CSSM_KEY_SIZE_PTR KeySize)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GenerateKey (CSSM_CC_HANDLE CCHandle,
uint32 KeyUsage,
uint32 KeyAttr,
const CSSM_DATA *KeyLabel,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
CSSM_KEY_PTR Key)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GenerateKeyP (CSSM_CC_HANDLE CCHandle,
uint32 KeyUsage,
uint32 KeyAttr,
const CSSM_DATA *KeyLabel,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
CSSM_KEY_PTR Key,
CSSM_PRIVILEGE Privilege)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GenerateKeyPair (CSSM_CC_HANDLE CCHandle,
uint32 PublicKeyUsage,
uint32 PublicKeyAttr,
const CSSM_DATA *PublicKeyLabel,
CSSM_KEY_PTR PublicKey,
uint32 PrivateKeyUsage,
uint32 PrivateKeyAttr,
const CSSM_DATA *PrivateKeyLabel,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
CSSM_KEY_PTR PrivateKey)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GenerateKeyPairP (CSSM_CC_HANDLE CCHandle,
uint32 PublicKeyUsage,
uint32 PublicKeyAttr,
const CSSM_DATA *PublicKeyLabel,
CSSM_KEY_PTR PublicKey,
uint32 PrivateKeyUsage,
uint32 PrivateKeyAttr,
const CSSM_DATA *PrivateKeyLabel,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
CSSM_KEY_PTR PrivateKey,
CSSM_PRIVILEGE Privilege)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GenerateRandom (CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR RandomNumber)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_ObtainPrivateKeyFromPublicKey (CSSM_CSP_HANDLE CSPHandle,
const CSSM_KEY *PublicKey,
CSSM_KEY_PTR PrivateKey)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_WrapKey (CSSM_CC_HANDLE CCHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_KEY *Key,
const CSSM_DATA *DescriptiveData,
CSSM_WRAP_KEY_PTR WrappedKey)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_UnwrapKey (CSSM_CC_HANDLE CCHandle,
const CSSM_KEY *PublicKey,
const CSSM_WRAP_KEY *WrappedKey,
uint32 KeyUsage,
uint32 KeyAttr,
const CSSM_DATA *KeyLabel,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
CSSM_KEY_PTR UnwrappedKey,
CSSM_DATA_PTR DescriptiveData)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_WrapKeyP (CSSM_CC_HANDLE CCHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_KEY *Key,
const CSSM_DATA *DescriptiveData,
CSSM_WRAP_KEY_PTR WrappedKey,
CSSM_PRIVILEGE Privilege)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_UnwrapKeyP (CSSM_CC_HANDLE CCHandle,
const CSSM_KEY *PublicKey,
const CSSM_WRAP_KEY *WrappedKey,
uint32 KeyUsage,
uint32 KeyAttr,
const CSSM_DATA *KeyLabel,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
CSSM_KEY_PTR UnwrappedKey,
CSSM_DATA_PTR DescriptiveData,
CSSM_PRIVILEGE Privilege)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DeriveKey (CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR Param,
uint32 KeyUsage,
uint32 KeyAttr,
const CSSM_DATA *KeyLabel,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
CSSM_KEY_PTR DerivedKey)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_FreeKey (CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
CSSM_KEY_PTR KeyPtr,
CSSM_BOOL Delete)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GenerateAlgorithmParams (CSSM_CC_HANDLE CCHandle,
uint32 ParamBits,
CSSM_DATA_PTR Param)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_GetOperationalStatistics (CSSM_CSP_HANDLE CSPHandle,
CSSM_CSP_OPERATIONAL_STATISTICS *Statistics)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_GetTimeValue (CSSM_CSP_HANDLE CSPHandle,
CSSM_ALGORITHMS TimeAlgorithm,
CSSM_DATA *TimeData)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_RetrieveUniqueId (CSSM_CSP_HANDLE CSPHandle,
CSSM_DATA_PTR UniqueID)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_RetrieveCounter (CSSM_CSP_HANDLE CSPHandle,
CSSM_DATA_PTR Counter)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_VerifyDevice (CSSM_CSP_HANDLE CSPHandle,
const CSSM_DATA *DeviceCert)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CSP_PassThrough (CSSM_CC_HANDLE CCHandle,
uint32 PassThroughId,
const void *InData,
void **OutData)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_SubmitCredRequest (CSSM_TP_HANDLE TPHandle,
const CSSM_TP_AUTHORITY_ID *PreferredAuthority,
CSSM_TP_AUTHORITY_REQUEST_TYPE RequestType,
const CSSM_TP_REQUEST_SET *RequestInput,
const CSSM_TP_CALLERAUTH_CONTEXT *CallerAuthContext,
sint32 *EstimatedTime,
CSSM_DATA_PTR ReferenceIdentifier)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_RetrieveCredResult (CSSM_TP_HANDLE TPHandle,
const CSSM_DATA *ReferenceIdentifier,
const CSSM_TP_CALLERAUTH_CONTEXT *CallerAuthCredentials,
sint32 *EstimatedTime,
CSSM_BOOL *ConfirmationRequired,
CSSM_TP_RESULT_SET_PTR *RetrieveOutput)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_ConfirmCredResult (CSSM_TP_HANDLE TPHandle,
const CSSM_DATA *ReferenceIdentifier,
const CSSM_TP_CALLERAUTH_CONTEXT *CallerAuthCredentials,
const CSSM_TP_CONFIRM_RESPONSE *Responses,
const CSSM_TP_AUTHORITY_ID *PreferredAuthority)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_ReceiveConfirmation (CSSM_TP_HANDLE TPHandle,
const CSSM_DATA *ReferenceIdentifier,
CSSM_TP_CONFIRM_RESPONSE_PTR *Responses,
sint32 *ElapsedTime)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CertReclaimKey (CSSM_TP_HANDLE TPHandle,
const CSSM_CERTGROUP *CertGroup,
uint32 CertIndex,
CSSM_LONG_HANDLE KeyCacheHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CertReclaimAbort (CSSM_TP_HANDLE TPHandle,
CSSM_LONG_HANDLE KeyCacheHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_FormRequest (CSSM_TP_HANDLE TPHandle,
const CSSM_TP_AUTHORITY_ID *PreferredAuthority,
CSSM_TP_FORM_TYPE FormType,
CSSM_DATA_PTR BlankForm)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_FormSubmit (CSSM_TP_HANDLE TPHandle,
CSSM_TP_FORM_TYPE FormType,
const CSSM_DATA *Form,
const CSSM_TP_AUTHORITY_ID *ClearanceAuthority,
const CSSM_TP_AUTHORITY_ID *RepresentedAuthority,
CSSM_ACCESS_CREDENTIALS_PTR Credentials)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CertGroupVerify (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_CERTGROUP *CertGroupToBeVerified,
const CSSM_TP_VERIFY_CONTEXT *VerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR VerifyContextResult)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CertCreateTemplate (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
const CSSM_FIELD *CertFields,
CSSM_DATA_PTR CertTemplate)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CertGetAllTemplateFields (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *CertTemplate,
uint32 *NumberOfFields,
CSSM_FIELD_PTR *CertFields)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CertSign (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CertTemplateToBeSigned,
const CSSM_CERTGROUP *SignerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *SignerVerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR SignerVerifyResult,
CSSM_DATA_PTR SignedCert)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CrlVerify (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_ENCODED_CRL *CrlToBeVerified,
const CSSM_CERTGROUP *SignerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *VerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR RevokerVerifyResult)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CrlCreateTemplate (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
const CSSM_FIELD *CrlFields,
CSSM_DATA_PTR NewCrlTemplate)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CertRevoke (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_DATA *OldCrlTemplate,
const CSSM_CERTGROUP *CertGroupToBeRevoked,
const CSSM_CERTGROUP *RevokerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *RevokerVerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR RevokerVerifyResult,
CSSM_TP_CERTCHANGE_REASON Reason,
CSSM_DATA_PTR NewCrlTemplate)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CertRemoveFromCrlTemplate (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_DATA *OldCrlTemplate,
const CSSM_CERTGROUP *CertGroupToBeRemoved,
const CSSM_CERTGROUP *RevokerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *RevokerVerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR RevokerVerifyResult,
CSSM_DATA_PTR NewCrlTemplate)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CrlSign (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_ENCODED_CRL *CrlToBeSigned,
const CSSM_CERTGROUP *SignerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *SignerVerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR SignerVerifyResult,
CSSM_DATA_PTR SignedCrl)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_ApplyCrlToDb (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_ENCODED_CRL *CrlToBeApplied,
const CSSM_CERTGROUP *SignerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *ApplyCrlVerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR ApplyCrlVerifyResult)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CertGroupConstruct (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_DL_DB_LIST *DBList,
const void *ConstructParams,
const CSSM_CERTGROUP *CertGroupFrag,
CSSM_CERTGROUP_PTR *CertGroup)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CertGroupPrune (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
const CSSM_DL_DB_LIST *DBList,
const CSSM_CERTGROUP *OrderedCertGroup,
CSSM_CERTGROUP_PTR *PrunedCertGroup)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_CertGroupToTupleGroup (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
const CSSM_CERTGROUP *CertGroup,
CSSM_TUPLEGROUP_PTR *TupleGroup)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_TupleGroupToCertGroup (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
const CSSM_TUPLEGROUP *TupleGroup,
CSSM_CERTGROUP_PTR *CertTemplates)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_TP_PassThrough (CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DL_DB_LIST *DBList,
uint32 PassThroughId,
const void *InputParams,
void **OutputParams)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_AC_AuthCompute (CSSM_AC_HANDLE ACHandle,
const CSSM_TUPLEGROUP *BaseAuthorizations,
const CSSM_TUPLEGROUP *Credentials,
uint32 NumberOfRequestors,
const CSSM_LIST *Requestors,
const CSSM_LIST *RequestedAuthorizationPeriod,
const CSSM_LIST *RequestedAuthorization,
CSSM_TUPLEGROUP_PTR AuthorizationResult)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_AC_PassThrough (CSSM_AC_HANDLE ACHandle,
CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DL_DB_LIST *DBList,
uint32 PassThroughId,
const void *InputParams,
void **OutputParams)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertCreateTemplate (CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
const CSSM_FIELD *CertFields,
CSSM_DATA_PTR CertTemplate)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertGetAllTemplateFields (CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *CertTemplate,
uint32 *NumberOfFields,
CSSM_FIELD_PTR *CertFields)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertSign (CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CertTemplate,
const CSSM_FIELD *SignScope,
uint32 ScopeSize,
CSSM_DATA_PTR SignedCert)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertVerify (CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CertToBeVerified,
const CSSM_DATA *SignerCert,
const CSSM_FIELD *VerifyScope,
uint32 ScopeSize)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertVerifyWithKey (CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CertToBeVerified)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertGetFirstFieldValue (CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
const CSSM_OID *CertField,
CSSM_HANDLE_PTR ResultsHandle,
uint32 *NumberOfMatchedFields,
CSSM_DATA_PTR *Value)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertGetNextFieldValue (CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle,
CSSM_DATA_PTR *Value)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertAbortQuery (CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertGetKeyInfo (CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
CSSM_KEY_PTR *Key)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertGetAllFields (CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
uint32 *NumberOfFields,
CSSM_FIELD_PTR *CertFields)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_FreeFields (CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
CSSM_FIELD_PTR *Fields)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_FreeFieldValue (CSSM_CL_HANDLE CLHandle,
const CSSM_OID *CertOrCrlOid,
CSSM_DATA_PTR Value)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertCache (CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
CSSM_HANDLE_PTR CertHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertGetFirstCachedFieldValue (CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE CertHandle,
const CSSM_OID *CertField,
CSSM_HANDLE_PTR ResultsHandle,
uint32 *NumberOfMatchedFields,
CSSM_DATA_PTR *Value)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertGetNextCachedFieldValue (CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle,
CSSM_DATA_PTR *Value)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertAbortCache (CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE CertHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertGroupToSignedBundle (CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CERTGROUP *CertGroupToBundle,
const CSSM_CERT_BUNDLE_HEADER *BundleInfo,
CSSM_DATA_PTR SignedBundle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertGroupFromVerifiedBundle (CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CERT_BUNDLE *CertBundle,
const CSSM_DATA *SignerCert,
CSSM_CERTGROUP_PTR *CertGroup)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CertDescribeFormat (CSSM_CL_HANDLE CLHandle,
uint32 *NumberOfFields,
CSSM_OID_PTR *OidList)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlCreateTemplate (CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
const CSSM_FIELD *CrlTemplate,
CSSM_DATA_PTR NewCrl)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlSetFields (CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
const CSSM_FIELD *CrlTemplate,
const CSSM_DATA *OldCrl,
CSSM_DATA_PTR ModifiedCrl)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlAddCert (CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *Cert,
uint32 NumberOfFields,
const CSSM_FIELD *CrlEntryFields,
const CSSM_DATA *OldCrl,
CSSM_DATA_PTR NewCrl)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlRemoveCert (CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
const CSSM_DATA *OldCrl,
CSSM_DATA_PTR NewCrl)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlSign (CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *UnsignedCrl,
const CSSM_FIELD *SignScope,
uint32 ScopeSize,
CSSM_DATA_PTR SignedCrl)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlVerify (CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CrlToBeVerified,
const CSSM_DATA *SignerCert,
const CSSM_FIELD *VerifyScope,
uint32 ScopeSize)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlVerifyWithKey (CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CrlToBeVerified)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_IsCertInCrl (CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
const CSSM_DATA *Crl,
CSSM_BOOL *CertFound)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlGetFirstFieldValue (CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Crl,
const CSSM_OID *CrlField,
CSSM_HANDLE_PTR ResultsHandle,
uint32 *NumberOfMatchedFields,
CSSM_DATA_PTR *Value)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlGetNextFieldValue (CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle,
CSSM_DATA_PTR *Value)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlAbortQuery (CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlGetAllFields (CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Crl,
uint32 *NumberOfCrlFields,
CSSM_FIELD_PTR *CrlFields)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlCache (CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Crl,
CSSM_HANDLE_PTR CrlHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_IsCertInCachedCrl (CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
CSSM_HANDLE CrlHandle,
CSSM_BOOL *CertFound,
CSSM_DATA_PTR CrlRecordIndex)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlGetFirstCachedFieldValue (CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE CrlHandle,
const CSSM_DATA *CrlRecordIndex,
const CSSM_OID *CrlField,
CSSM_HANDLE_PTR ResultsHandle,
uint32 *NumberOfMatchedFields,
CSSM_DATA_PTR *Value)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlGetNextCachedFieldValue (CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle,
CSSM_DATA_PTR *Value)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlGetAllCachedRecordFields (CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE CrlHandle,
const CSSM_DATA *CrlRecordIndex,
uint32 *NumberOfFields,
CSSM_FIELD_PTR *CrlFields)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlAbortCache (CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE CrlHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_CrlDescribeFormat (CSSM_CL_HANDLE CLHandle,
uint32 *NumberOfFields,
CSSM_OID_PTR *OidList)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_CL_PassThrough (CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
uint32 PassThroughId,
const void *InputParams,
void **OutputParams)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DbOpen (CSSM_DL_HANDLE DLHandle,
const char *DbName,
const CSSM_NET_ADDRESS *DbLocation,
CSSM_DB_ACCESS_TYPE AccessRequest,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const void *OpenParameters,
CSSM_DB_HANDLE *DbHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DbClose (CSSM_DL_DB_HANDLE DLDBHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DbCreate (CSSM_DL_HANDLE DLHandle,
const char *DbName,
const CSSM_NET_ADDRESS *DbLocation,
const CSSM_DBINFO *DBInfo,
CSSM_DB_ACCESS_TYPE AccessRequest,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
const void *OpenParameters,
CSSM_DB_HANDLE *DbHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DbDelete (CSSM_DL_HANDLE DLHandle,
const char *DbName,
const CSSM_NET_ADDRESS *DbLocation,
const CSSM_ACCESS_CREDENTIALS *AccessCred)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_CreateRelation (CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_RECORDTYPE RelationID,
const char *RelationName,
uint32 NumberOfAttributes,
const CSSM_DB_SCHEMA_ATTRIBUTE_INFO *pAttributeInfo,
uint32 NumberOfIndexes,
const CSSM_DB_SCHEMA_INDEX_INFO *pIndexInfo)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DestroyRelation (CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_RECORDTYPE RelationID)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_Authenticate (CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_ACCESS_TYPE AccessRequest,
const CSSM_ACCESS_CREDENTIALS *AccessCred)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_GetDbAcl (CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_STRING *SelectionTag,
uint32 *NumberOfAclInfos,
CSSM_ACL_ENTRY_INFO_PTR *AclInfos)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_ChangeDbAcl (CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_ACL_EDIT *AclEdit)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_GetDbOwner (CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_ACL_OWNER_PROTOTYPE_PTR Owner)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_ChangeDbOwner (CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_ACL_OWNER_PROTOTYPE *NewOwner)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_GetDbNames (CSSM_DL_HANDLE DLHandle,
CSSM_NAME_LIST_PTR *NameList)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_GetDbNameFromHandle (CSSM_DL_DB_HANDLE DLDBHandle,
char **DbName)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_FreeNameList (CSSM_DL_HANDLE DLHandle,
CSSM_NAME_LIST_PTR NameList)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DataInsert (CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_RECORDTYPE RecordType,
const CSSM_DB_RECORD_ATTRIBUTE_DATA *Attributes,
const CSSM_DATA *Data,
CSSM_DB_UNIQUE_RECORD_PTR *UniqueId)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DataDelete (CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_DB_UNIQUE_RECORD *UniqueRecordIdentifier)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DataModify (CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_RECORDTYPE RecordType,
CSSM_DB_UNIQUE_RECORD_PTR UniqueRecordIdentifier,
const CSSM_DB_RECORD_ATTRIBUTE_DATA *AttributesToBeModified,
const CSSM_DATA *DataToBeModified,
CSSM_DB_MODIFY_MODE ModifyMode)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DataGetFirst (CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_QUERY *Query,
CSSM_HANDLE_PTR ResultsHandle,
CSSM_DB_RECORD_ATTRIBUTE_DATA_PTR Attributes,
CSSM_DATA_PTR Data,
CSSM_DB_UNIQUE_RECORD_PTR *UniqueId)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DataGetNext (CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_HANDLE ResultsHandle,
CSSM_DB_RECORD_ATTRIBUTE_DATA_PTR Attributes,
CSSM_DATA_PTR Data,
CSSM_DB_UNIQUE_RECORD_PTR *UniqueId)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DataAbortQuery (CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_HANDLE ResultsHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_DataGetFromUniqueRecordId (CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_DB_UNIQUE_RECORD *UniqueRecord,
CSSM_DB_RECORD_ATTRIBUTE_DATA_PTR Attributes,
CSSM_DATA_PTR Data)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_FreeUniqueRecord (CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_UNIQUE_RECORD_PTR UniqueRecord)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_DL_PassThrough (CSSM_DL_DB_HANDLE DLDBHandle,
uint32 PassThroughId,
const void *InputParams,
void **OutputParams)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
typedef struct cssm_spi_ac_funcs {
CSSM_RETURN ( *AuthCompute)
(CSSM_AC_HANDLE ACHandle,
const CSSM_TUPLEGROUP *BaseAuthorizations,
const CSSM_TUPLEGROUP *Credentials,
uint32 NumberOfRequestors,
const CSSM_LIST *Requestors,
const CSSM_LIST *RequestedAuthorizationPeriod,
const CSSM_LIST *RequestedAuthorization,
CSSM_TUPLEGROUP_PTR AuthorizationResult);
CSSM_RETURN ( *PassThrough)
(CSSM_AC_HANDLE ACHandle,
CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DL_DB_LIST *DBList,
uint32 PassThroughId,
const void *InputParams,
void **OutputParams);
} CSSM_SPI_AC_FUNCS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_SPI_AC_FUNCS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
typedef struct cssm_spi_cl_funcs {
CSSM_RETURN ( *CertCreateTemplate)
(CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
const CSSM_FIELD *CertFields,
CSSM_DATA_PTR CertTemplate);
CSSM_RETURN ( *CertGetAllTemplateFields)
(CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *CertTemplate,
uint32 *NumberOfFields,
CSSM_FIELD_PTR *CertFields);
CSSM_RETURN ( *CertSign)
(CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CertTemplate,
const CSSM_FIELD *SignScope,
uint32 ScopeSize,
CSSM_DATA_PTR SignedCert);
CSSM_RETURN ( *CertVerify)
(CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CertToBeVerified,
const CSSM_DATA *SignerCert,
const CSSM_FIELD *VerifyScope,
uint32 ScopeSize);
CSSM_RETURN ( *CertVerifyWithKey)
(CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CertToBeVerified);
CSSM_RETURN ( *CertGetFirstFieldValue)
(CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
const CSSM_OID *CertField,
CSSM_HANDLE_PTR ResultsHandle,
uint32 *NumberOfMatchedFields,
CSSM_DATA_PTR *Value);
CSSM_RETURN ( *CertGetNextFieldValue)
(CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle,
CSSM_DATA_PTR *Value);
CSSM_RETURN ( *CertAbortQuery)
(CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle);
CSSM_RETURN ( *CertGetKeyInfo)
(CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
CSSM_KEY_PTR *Key);
CSSM_RETURN ( *CertGetAllFields)
(CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
uint32 *NumberOfFields,
CSSM_FIELD_PTR *CertFields);
CSSM_RETURN ( *FreeFields)
(CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
CSSM_FIELD_PTR *FieldArray);
CSSM_RETURN ( *FreeFieldValue)
(CSSM_CL_HANDLE CLHandle,
const CSSM_OID *CertOrCrlOid,
CSSM_DATA_PTR Value);
CSSM_RETURN ( *CertCache)
(CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
CSSM_HANDLE_PTR CertHandle);
CSSM_RETURN ( *CertGetFirstCachedFieldValue)
(CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE CertHandle,
const CSSM_OID *CertField,
CSSM_HANDLE_PTR ResultsHandle,
uint32 *NumberOfMatchedFields,
CSSM_DATA_PTR *Value);
CSSM_RETURN ( *CertGetNextCachedFieldValue)
(CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle,
CSSM_DATA_PTR *Value);
CSSM_RETURN ( *CertAbortCache)
(CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE CertHandle);
CSSM_RETURN ( *CertGroupToSignedBundle)
(CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CERTGROUP *CertGroupToBundle,
const CSSM_CERT_BUNDLE_HEADER *BundleInfo,
CSSM_DATA_PTR SignedBundle);
CSSM_RETURN ( *CertGroupFromVerifiedBundle)
(CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CERT_BUNDLE *CertBundle,
const CSSM_DATA *SignerCert,
CSSM_CERTGROUP_PTR *CertGroup);
CSSM_RETURN ( *CertDescribeFormat)
(CSSM_CL_HANDLE CLHandle,
uint32 *NumberOfFields,
CSSM_OID_PTR *OidList);
CSSM_RETURN ( *CrlCreateTemplate)
(CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
const CSSM_FIELD *CrlTemplate,
CSSM_DATA_PTR NewCrl);
CSSM_RETURN ( *CrlSetFields)
(CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
const CSSM_FIELD *CrlTemplate,
const CSSM_DATA *OldCrl,
CSSM_DATA_PTR ModifiedCrl);
CSSM_RETURN ( *CrlAddCert)
(CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *Cert,
uint32 NumberOfFields,
const CSSM_FIELD *CrlEntryFields,
const CSSM_DATA *OldCrl,
CSSM_DATA_PTR NewCrl);
CSSM_RETURN ( *CrlRemoveCert)
(CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
const CSSM_DATA *OldCrl,
CSSM_DATA_PTR NewCrl);
CSSM_RETURN ( *CrlSign)
(CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *UnsignedCrl,
const CSSM_FIELD *SignScope,
uint32 ScopeSize,
CSSM_DATA_PTR SignedCrl);
CSSM_RETURN ( *CrlVerify)
(CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CrlToBeVerified,
const CSSM_DATA *SignerCert,
const CSSM_FIELD *VerifyScope,
uint32 ScopeSize);
CSSM_RETURN ( *CrlVerifyWithKey)
(CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CrlToBeVerified);
CSSM_RETURN ( *IsCertInCrl)
(CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
const CSSM_DATA *Crl,
CSSM_BOOL *CertFound);
CSSM_RETURN ( *CrlGetFirstFieldValue)
(CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Crl,
const CSSM_OID *CrlField,
CSSM_HANDLE_PTR ResultsHandle,
uint32 *NumberOfMatchedFields,
CSSM_DATA_PTR *Value);
CSSM_RETURN ( *CrlGetNextFieldValue)
(CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle,
CSSM_DATA_PTR *Value);
CSSM_RETURN ( *CrlAbortQuery)
(CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle);
CSSM_RETURN ( *CrlGetAllFields)
(CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Crl,
uint32 *NumberOfCrlFields,
CSSM_FIELD_PTR *CrlFields);
CSSM_RETURN ( *CrlCache)
(CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Crl,
CSSM_HANDLE_PTR CrlHandle);
CSSM_RETURN ( *IsCertInCachedCrl)
(CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *Cert,
CSSM_HANDLE CrlHandle,
CSSM_BOOL *CertFound,
CSSM_DATA_PTR CrlRecordIndex);
CSSM_RETURN ( *CrlGetFirstCachedFieldValue)
(CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE CrlHandle,
const CSSM_DATA *CrlRecordIndex,
const CSSM_OID *CrlField,
CSSM_HANDLE_PTR ResultsHandle,
uint32 *NumberOfMatchedFields,
CSSM_DATA_PTR *Value);
CSSM_RETURN ( *CrlGetNextCachedFieldValue)
(CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE ResultsHandle,
CSSM_DATA_PTR *Value);
CSSM_RETURN ( *CrlGetAllCachedRecordFields)
(CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE CrlHandle,
const CSSM_DATA *CrlRecordIndex,
uint32 *NumberOfFields,
CSSM_FIELD_PTR *CrlFields);
CSSM_RETURN ( *CrlAbortCache)
(CSSM_CL_HANDLE CLHandle,
CSSM_HANDLE CrlHandle);
CSSM_RETURN ( *CrlDescribeFormat)
(CSSM_CL_HANDLE CLHandle,
uint32 *NumberOfFields,
CSSM_OID_PTR *OidList);
CSSM_RETURN ( *PassThrough)
(CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
uint32 PassThroughId,
const void *InputParams,
void **OutputParams);
} CSSM_SPI_CL_FUNCS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_SPI_CL_FUNCS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
typedef CSSM_RETURN ( *CSSM_SPI_ModuleEventHandler)
(const CSSM_GUID *ModuleGuid,
void *CssmNotifyCallbackCtx,
uint32 SubserviceId,
CSSM_SERVICE_TYPE ServiceType,
CSSM_MODULE_EVENT EventType);
typedef uint32 CSSM_CONTEXT_EVENT;
enum {
CSSM_CONTEXT_EVENT_CREATE = 1,
CSSM_CONTEXT_EVENT_DELETE = 2,
CSSM_CONTEXT_EVENT_UPDATE = 3
};
typedef struct cssm_module_funcs {
CSSM_SERVICE_TYPE ServiceType;
uint32 NumberOfServiceFuncs;
const CSSM_PROC_ADDR *ServiceFuncs;
} CSSM_MODULE_FUNCS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_MODULE_FUNCS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef void *( *CSSM_UPCALLS_MALLOC)
(CSSM_HANDLE AddInHandle,
size_t size) __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef void ( *CSSM_UPCALLS_FREE)
(CSSM_HANDLE AddInHandle,
void *memblock) __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef void *( *CSSM_UPCALLS_REALLOC)
(CSSM_HANDLE AddInHandle,
void *memblock,
size_t size) __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef void *( *CSSM_UPCALLS_CALLOC)
(CSSM_HANDLE AddInHandle,
size_t num,
size_t size) __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_upcalls {
CSSM_UPCALLS_MALLOC malloc_func;
CSSM_UPCALLS_FREE free_func;
CSSM_UPCALLS_REALLOC realloc_func;
CSSM_UPCALLS_CALLOC calloc_func;
CSSM_RETURN ( *CcToHandle_func)
(CSSM_CC_HANDLE Cc,
CSSM_MODULE_HANDLE_PTR ModuleHandle);
CSSM_RETURN ( *GetModuleInfo_func)
(CSSM_MODULE_HANDLE Module,
CSSM_GUID_PTR Guid,
CSSM_VERSION_PTR Version,
uint32 *SubServiceId,
CSSM_SERVICE_TYPE *SubServiceType,
CSSM_ATTACH_FLAGS *AttachFlags,
CSSM_KEY_HIERARCHY *KeyHierarchy,
CSSM_API_MEMORY_FUNCS_PTR AttachedMemFuncs,
CSSM_FUNC_NAME_ADDR_PTR FunctionTable,
uint32 NumFunctions);
} CSSM_UPCALLS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_UPCALLS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_SPI_ModuleLoad (const CSSM_GUID *CssmGuid,
const CSSM_GUID *ModuleGuid,
CSSM_SPI_ModuleEventHandler CssmNotifyCallback,
void *CssmNotifyCallbackCtx)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_SPI_ModuleUnload (const CSSM_GUID *CssmGuid,
const CSSM_GUID *ModuleGuid,
CSSM_SPI_ModuleEventHandler CssmNotifyCallback,
void *CssmNotifyCallbackCtx)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_SPI_ModuleAttach (const CSSM_GUID *ModuleGuid,
const CSSM_VERSION *Version,
uint32 SubserviceID,
CSSM_SERVICE_TYPE SubServiceType,
CSSM_ATTACH_FLAGS AttachFlags,
CSSM_MODULE_HANDLE ModuleHandle,
CSSM_KEY_HIERARCHY KeyHierarchy,
const CSSM_GUID *CssmGuid,
const CSSM_GUID *ModuleManagerGuid,
const CSSM_GUID *CallerGuid,
const CSSM_UPCALLS *Upcalls,
CSSM_MODULE_FUNCS_PTR *FuncTbl)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_SPI_ModuleDetach (CSSM_MODULE_HANDLE ModuleHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
typedef struct cssm_spi_csp_funcs {
CSSM_RETURN ( *EventNotify)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CONTEXT_EVENT Event,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context);
CSSM_RETURN ( *QuerySize)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
CSSM_BOOL Encrypt,
uint32 QuerySizeCount,
CSSM_QUERY_SIZE_DATA_PTR DataBlock);
CSSM_RETURN ( *SignData)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
const CSSM_DATA *DataBufs,
uint32 DataBufCount,
CSSM_ALGORITHMS DigestAlgorithm,
CSSM_DATA_PTR Signature);
CSSM_RETURN ( *SignDataInit)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context);
CSSM_RETURN ( *SignDataUpdate)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount);
CSSM_RETURN ( *SignDataFinal)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR Signature);
CSSM_RETURN ( *VerifyData)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
const CSSM_DATA *DataBufs,
uint32 DataBufCount,
CSSM_ALGORITHMS DigestAlgorithm,
const CSSM_DATA *Signature);
CSSM_RETURN ( *VerifyDataInit)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context);
CSSM_RETURN ( *VerifyDataUpdate)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount);
CSSM_RETURN ( *VerifyDataFinal)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *Signature);
CSSM_RETURN ( *DigestData)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
const CSSM_DATA *DataBufs,
uint32 DataBufCount,
CSSM_DATA_PTR Digest);
CSSM_RETURN ( *DigestDataInit)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context);
CSSM_RETURN ( *DigestDataUpdate)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount);
CSSM_RETURN ( *DigestDataClone)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
CSSM_CC_HANDLE ClonedCCHandle);
CSSM_RETURN ( *DigestDataFinal)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR Digest);
CSSM_RETURN ( *GenerateMac)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
const CSSM_DATA *DataBufs,
uint32 DataBufCount,
CSSM_DATA_PTR Mac);
CSSM_RETURN ( *GenerateMacInit)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context);
CSSM_RETURN ( *GenerateMacUpdate)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount);
CSSM_RETURN ( *GenerateMacFinal)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR Mac);
CSSM_RETURN ( *VerifyMac)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
const CSSM_DATA *DataBufs,
uint32 DataBufCount,
const CSSM_DATA *Mac);
CSSM_RETURN ( *VerifyMacInit)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context);
CSSM_RETURN ( *VerifyMacUpdate)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *DataBufs,
uint32 DataBufCount);
CSSM_RETURN ( *VerifyMacFinal)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *Mac);
CSSM_RETURN ( *EncryptData)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
const CSSM_DATA *ClearBufs,
uint32 ClearBufCount,
CSSM_DATA_PTR CipherBufs,
uint32 CipherBufCount,
CSSM_SIZE *bytesEncrypted,
CSSM_DATA_PTR RemData,
CSSM_PRIVILEGE Privilege);
CSSM_RETURN ( *EncryptDataInit)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
CSSM_PRIVILEGE Privilege);
CSSM_RETURN ( *EncryptDataUpdate)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *ClearBufs,
uint32 ClearBufCount,
CSSM_DATA_PTR CipherBufs,
uint32 CipherBufCount,
CSSM_SIZE *bytesEncrypted);
CSSM_RETURN ( *EncryptDataFinal)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR RemData);
CSSM_RETURN ( *DecryptData)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
const CSSM_DATA *CipherBufs,
uint32 CipherBufCount,
CSSM_DATA_PTR ClearBufs,
uint32 ClearBufCount,
CSSM_SIZE *bytesDecrypted,
CSSM_DATA_PTR RemData,
CSSM_PRIVILEGE Privilege);
CSSM_RETURN ( *DecryptDataInit)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
CSSM_PRIVILEGE Privilege);
CSSM_RETURN ( *DecryptDataUpdate)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CipherBufs,
uint32 CipherBufCount,
CSSM_DATA_PTR ClearBufs,
uint32 ClearBufCount,
CSSM_SIZE *bytesDecrypted);
CSSM_RETURN ( *DecryptDataFinal)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
CSSM_DATA_PTR RemData);
CSSM_RETURN ( *QueryKeySizeInBits)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
const CSSM_KEY *Key,
CSSM_KEY_SIZE_PTR KeySize);
CSSM_RETURN ( *GenerateKey)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
uint32 KeyUsage,
uint32 KeyAttr,
const CSSM_DATA *KeyLabel,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
CSSM_KEY_PTR Key,
CSSM_PRIVILEGE Privilege);
CSSM_RETURN ( *GenerateKeyPair)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
uint32 PublicKeyUsage,
uint32 PublicKeyAttr,
const CSSM_DATA *PublicKeyLabel,
CSSM_KEY_PTR PublicKey,
uint32 PrivateKeyUsage,
uint32 PrivateKeyAttr,
const CSSM_DATA *PrivateKeyLabel,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
CSSM_KEY_PTR PrivateKey,
CSSM_PRIVILEGE Privilege);
CSSM_RETURN ( *GenerateRandom)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
CSSM_DATA_PTR RandomNumber);
CSSM_RETURN ( *GenerateAlgorithmParams)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
uint32 ParamBits,
CSSM_DATA_PTR Param,
uint32 *NumberOfUpdatedAttibutes,
CSSM_CONTEXT_ATTRIBUTE_PTR *UpdatedAttributes);
CSSM_RETURN ( *WrapKey)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_KEY *Key,
const CSSM_DATA *DescriptiveData,
CSSM_WRAP_KEY_PTR WrappedKey,
CSSM_PRIVILEGE Privilege);
CSSM_RETURN ( *UnwrapKey)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
const CSSM_KEY *PublicKey,
const CSSM_WRAP_KEY *WrappedKey,
uint32 KeyUsage,
uint32 KeyAttr,
const CSSM_DATA *KeyLabel,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
CSSM_KEY_PTR UnwrappedKey,
CSSM_DATA_PTR DescriptiveData,
CSSM_PRIVILEGE Privilege);
CSSM_RETURN ( *DeriveKey)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
CSSM_DATA_PTR Param,
uint32 KeyUsage,
uint32 KeyAttr,
const CSSM_DATA *KeyLabel,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
CSSM_KEY_PTR DerivedKey);
CSSM_RETURN ( *FreeKey)
(CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
CSSM_KEY_PTR KeyPtr,
CSSM_BOOL Delete);
CSSM_RETURN ( *PassThrough)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_CONTEXT *Context,
uint32 PassThroughId,
const void *InData,
void **OutData);
CSSM_RETURN ( *Login)
(CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_DATA *LoginName,
const void *Reserved);
CSSM_RETURN ( *Logout)
(CSSM_CSP_HANDLE CSPHandle);
CSSM_RETURN ( *ChangeLoginAcl)
(CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_ACL_EDIT *AclEdit);
CSSM_RETURN ( *ObtainPrivateKeyFromPublicKey)
(CSSM_CSP_HANDLE CSPHandle,
const CSSM_KEY *PublicKey,
CSSM_KEY_PTR PrivateKey);
CSSM_RETURN ( *RetrieveUniqueId)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_DATA_PTR UniqueID);
CSSM_RETURN ( *RetrieveCounter)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_DATA_PTR Counter);
CSSM_RETURN ( *VerifyDevice)
(CSSM_CSP_HANDLE CSPHandle,
const CSSM_DATA *DeviceCert);
CSSM_RETURN ( *GetTimeValue)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_ALGORITHMS TimeAlgorithm,
CSSM_DATA *TimeData);
CSSM_RETURN ( *GetOperationalStatistics)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_CSP_OPERATIONAL_STATISTICS *Statistics);
CSSM_RETURN ( *GetLoginAcl)
(CSSM_CSP_HANDLE CSPHandle,
const CSSM_STRING *SelectionTag,
uint32 *NumberOfAclInfos,
CSSM_ACL_ENTRY_INFO_PTR *AclInfos);
CSSM_RETURN ( *GetKeyAcl)
(CSSM_CSP_HANDLE CSPHandle,
const CSSM_KEY *Key,
const CSSM_STRING *SelectionTag,
uint32 *NumberOfAclInfos,
CSSM_ACL_ENTRY_INFO_PTR *AclInfos);
CSSM_RETURN ( *ChangeKeyAcl)
(CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_ACL_EDIT *AclEdit,
const CSSM_KEY *Key);
CSSM_RETURN ( *GetKeyOwner)
(CSSM_CSP_HANDLE CSPHandle,
const CSSM_KEY *Key,
CSSM_ACL_OWNER_PROTOTYPE_PTR Owner);
CSSM_RETURN ( *ChangeKeyOwner)
(CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_KEY *Key,
const CSSM_ACL_OWNER_PROTOTYPE *NewOwner);
CSSM_RETURN ( *GetLoginOwner)
(CSSM_CSP_HANDLE CSPHandle,
CSSM_ACL_OWNER_PROTOTYPE_PTR Owner);
CSSM_RETURN ( *ChangeLoginOwner)
(CSSM_CSP_HANDLE CSPHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_ACL_OWNER_PROTOTYPE *NewOwner);
} CSSM_SPI_CSP_FUNCS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_SPI_CSP_FUNCS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
typedef struct cssm_spi_dl_funcs {
CSSM_RETURN ( *DbOpen)
(CSSM_DL_HANDLE DLHandle,
const char *DbName,
const CSSM_NET_ADDRESS *DbLocation,
CSSM_DB_ACCESS_TYPE AccessRequest,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const void *OpenParameters,
CSSM_DB_HANDLE *DbHandle);
CSSM_RETURN ( *DbClose)
(CSSM_DL_DB_HANDLE DLDBHandle);
CSSM_RETURN ( *DbCreate)
(CSSM_DL_HANDLE DLHandle,
const char *DbName,
const CSSM_NET_ADDRESS *DbLocation,
const CSSM_DBINFO *DBInfo,
CSSM_DB_ACCESS_TYPE AccessRequest,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
const void *OpenParameters,
CSSM_DB_HANDLE *DbHandle);
CSSM_RETURN ( *DbDelete)
(CSSM_DL_HANDLE DLHandle,
const char *DbName,
const CSSM_NET_ADDRESS *DbLocation,
const CSSM_ACCESS_CREDENTIALS *AccessCred);
CSSM_RETURN ( *CreateRelation)
(CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_RECORDTYPE RelationID,
const char *RelationName,
uint32 NumberOfAttributes,
const CSSM_DB_SCHEMA_ATTRIBUTE_INFO *pAttributeInfo,
uint32 NumberOfIndexes,
const CSSM_DB_SCHEMA_INDEX_INFO *pIndexInfo);
CSSM_RETURN ( *DestroyRelation)
(CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_RECORDTYPE RelationID);
CSSM_RETURN ( *Authenticate)
(CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_ACCESS_TYPE AccessRequest,
const CSSM_ACCESS_CREDENTIALS *AccessCred);
CSSM_RETURN ( *GetDbAcl)
(CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_STRING *SelectionTag,
uint32 *NumberOfAclInfos,
CSSM_ACL_ENTRY_INFO_PTR *AclInfos);
CSSM_RETURN ( *ChangeDbAcl)
(CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_ACL_EDIT *AclEdit);
CSSM_RETURN ( *GetDbOwner)
(CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_ACL_OWNER_PROTOTYPE_PTR Owner);
CSSM_RETURN ( *ChangeDbOwner)
(CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const CSSM_ACL_OWNER_PROTOTYPE *NewOwner);
CSSM_RETURN ( *GetDbNames)
(CSSM_DL_HANDLE DLHandle,
CSSM_NAME_LIST_PTR *NameList);
CSSM_RETURN ( *GetDbNameFromHandle)
(CSSM_DL_DB_HANDLE DLDBHandle,
char **DbName);
CSSM_RETURN ( *FreeNameList)
(CSSM_DL_HANDLE DLHandle,
CSSM_NAME_LIST_PTR NameList);
CSSM_RETURN ( *DataInsert)
(CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_RECORDTYPE RecordType,
const CSSM_DB_RECORD_ATTRIBUTE_DATA *Attributes,
const CSSM_DATA *Data,
CSSM_DB_UNIQUE_RECORD_PTR *UniqueId);
CSSM_RETURN ( *DataDelete)
(CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_DB_UNIQUE_RECORD *UniqueRecordIdentifier);
CSSM_RETURN ( *DataModify)
(CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_RECORDTYPE RecordType,
CSSM_DB_UNIQUE_RECORD_PTR UniqueRecordIdentifier,
const CSSM_DB_RECORD_ATTRIBUTE_DATA *AttributesToBeModified,
const CSSM_DATA *DataToBeModified,
CSSM_DB_MODIFY_MODE ModifyMode);
CSSM_RETURN ( *DataGetFirst)
(CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_QUERY *Query,
CSSM_HANDLE_PTR ResultsHandle,
CSSM_DB_RECORD_ATTRIBUTE_DATA_PTR Attributes,
CSSM_DATA_PTR Data,
CSSM_DB_UNIQUE_RECORD_PTR *UniqueId);
CSSM_RETURN ( *DataGetNext)
(CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_HANDLE ResultsHandle,
CSSM_DB_RECORD_ATTRIBUTE_DATA_PTR Attributes,
CSSM_DATA_PTR Data,
CSSM_DB_UNIQUE_RECORD_PTR *UniqueId);
CSSM_RETURN ( *DataAbortQuery)
(CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_HANDLE ResultsHandle);
CSSM_RETURN ( *DataGetFromUniqueRecordId)
(CSSM_DL_DB_HANDLE DLDBHandle,
const CSSM_DB_UNIQUE_RECORD *UniqueRecord,
CSSM_DB_RECORD_ATTRIBUTE_DATA_PTR Attributes,
CSSM_DATA_PTR Data);
CSSM_RETURN ( *FreeUniqueRecord)
(CSSM_DL_DB_HANDLE DLDBHandle,
CSSM_DB_UNIQUE_RECORD_PTR UniqueRecord);
CSSM_RETURN ( *PassThrough)
(CSSM_DL_DB_HANDLE DLDBHandle,
uint32 PassThroughId,
const void *InputParams,
void **OutputParams);
} CSSM_SPI_DL_FUNCS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_SPI_DL_FUNCS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
typedef uint32 CSSM_KRSP_HANDLE;
typedef struct cssm_kr_name {
uint8 Type;
uint8 Length;
char *Name;
} CSSM_KR_NAME __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_kr_profile {
CSSM_KR_NAME UserName;
CSSM_CERTGROUP_PTR UserCertificate;
CSSM_CERTGROUP_PTR KRSCertChain;
uint8 LE_KRANum;
CSSM_CERTGROUP_PTR LE_KRACertChainList;
uint8 ENT_KRANum;
CSSM_CERTGROUP_PTR ENT_KRACertChainList;
uint8 INDIV_KRANum;
CSSM_CERTGROUP_PTR INDIV_KRACertChainList;
CSSM_DATA_PTR INDIV_AuthenticationInfo;
uint32 KRSPFlags;
CSSM_DATA_PTR KRSPExtensions;
} CSSM_KR_PROFILE __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_KR_PROFILE_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_kr_wrappedproductinfo {
CSSM_VERSION StandardVersion;
CSSM_STRING StandardDescription;
CSSM_VERSION ProductVersion;
CSSM_STRING ProductDescription;
CSSM_STRING ProductVendor;
uint32 ProductFlags;
} CSSM_KR_WRAPPEDPRODUCT_INFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_KR_WRAPPEDPRODUCT_INFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_krsubservice {
uint32 SubServiceId;
char *Description;
CSSM_KR_WRAPPEDPRODUCT_INFO WrappedProduct;
} CSSM_KRSUBSERVICE, *CSSM_KRSUBSERVICE_PTR;
typedef uint32 CSSM_KR_POLICY_TYPE;
typedef uint32 CSSM_KR_POLICY_FLAGS;
typedef struct cssm_kr_policy_list_item {
struct kr_policy_list_item *next;
CSSM_ALGORITHMS AlgorithmId;
CSSM_ENCRYPT_MODE Mode;
uint32 MaxKeyLength;
uint32 MaxRounds;
uint8 WorkFactor;
CSSM_KR_POLICY_FLAGS PolicyFlags;
CSSM_CONTEXT_TYPE AlgClass;
} CSSM_KR_POLICY_LIST_ITEM __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_KR_POLICY_LIST_ITEM_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_kr_policy_info {
CSSM_BOOL krbNotAllowed;
uint32 numberOfEntries;
CSSM_KR_POLICY_LIST_ITEM *policyEntry;
} CSSM_KR_POLICY_INFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_KR_POLICY_INFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_SetEnterpriseRecoveryPolicy (const CSSM_DATA *RecoveryPolicyFileName,
const CSSM_ACCESS_CREDENTIALS *OldPassPhrase,
const CSSM_ACCESS_CREDENTIALS *NewPassPhrase)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_CreateRecoveryRegistrationContext (CSSM_KRSP_HANDLE KRSPHandle,
CSSM_CC_HANDLE *NewContext)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_CreateRecoveryEnablementContext (CSSM_KRSP_HANDLE KRSPHandle,
const CSSM_KR_PROFILE *LocalProfile,
const CSSM_KR_PROFILE *RemoteProfile,
CSSM_CC_HANDLE *NewContext)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_CreateRecoveryRequestContext (CSSM_KRSP_HANDLE KRSPHandle,
const CSSM_KR_PROFILE *LocalProfile,
CSSM_CC_HANDLE *NewContext)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_GetPolicyInfo (CSSM_CC_HANDLE CCHandle,
CSSM_KR_POLICY_FLAGS *EncryptionProhibited,
uint32 *WorkFactor)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_RegistrationRequest (CSSM_CC_HANDLE RecoveryRegistrationContext,
const CSSM_DATA *KRInData,
const CSSM_ACCESS_CREDENTIALS *AccessCredentials,
CSSM_KR_POLICY_FLAGS KRFlags,
sint32 *EstimatedTime,
CSSM_HANDLE_PTR ReferenceHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_RegistrationRetrieve (CSSM_KRSP_HANDLE KRSPHandle,
CSSM_HANDLE ReferenceHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCredentials,
sint32 *EstimatedTime,
CSSM_KR_PROFILE_PTR KRProfile)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_GenerateRecoveryFields (CSSM_CC_HANDLE KeyRecoveryContext,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *KRSPOptions,
CSSM_KR_POLICY_FLAGS KRFlags,
CSSM_DATA_PTR KRFields,
CSSM_CC_HANDLE *NewCCHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_ProcessRecoveryFields (CSSM_CC_HANDLE KeyRecoveryContext,
CSSM_CC_HANDLE CryptoContext,
const CSSM_DATA *KRSPOptions,
CSSM_KR_POLICY_FLAGS KRFlags,
const CSSM_DATA *KRFields,
CSSM_CC_HANDLE *NewCryptoContext)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_RecoveryRequest (CSSM_CC_HANDLE RecoveryRequestContext,
const CSSM_DATA *KRInData,
const CSSM_ACCESS_CREDENTIALS *AccessCredentials,
sint32 *EstimatedTime,
CSSM_HANDLE_PTR ReferenceHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_RecoveryRetrieve (CSSM_KRSP_HANDLE KRSPHandle,
CSSM_HANDLE ReferenceHandle,
const CSSM_ACCESS_CREDENTIALS *AccessCredentials,
sint32 *EstimatedTime,
CSSM_HANDLE_PTR CacheHandle,
uint32 *NumberOfRecoveredKeys)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_GetRecoveredObject (CSSM_KRSP_HANDLE KRSPHandle,
CSSM_HANDLE CacheHandle,
uint32 IndexInResults,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
uint32 Flags,
CSSM_KEY_PTR RecoveredKey,
CSSM_DATA_PTR OtherInfo)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_RecoveryRequestAbort (CSSM_KRSP_HANDLE KRSPHandle,
CSSM_HANDLE CacheHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_QueryPolicyInfo (CSSM_KRSP_HANDLE KRSPHandle,
CSSM_ALGORITHMS AlgorithmID,
CSSM_ENCRYPT_MODE Mode,
CSSM_CONTEXT_TYPE Class,
CSSM_KR_POLICY_INFO_PTR *PolicyInfoData)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
CSSM_KR_PassThrough (CSSM_KRSP_HANDLE KRSPHandle,
CSSM_CC_HANDLE KeyRecoveryContext,
CSSM_CC_HANDLE CryptoContext,
uint32 PassThroughId,
const void *InputParams,
void **OutputParams)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
typedef struct cssm_spi_kr_funcs {
CSSM_RETURN ( *RegistrationRequest)
(CSSM_KRSP_HANDLE KRSPHandle,
CSSM_CC_HANDLE KRRegistrationContextHandle,
const CSSM_CONTEXT *KRRegistrationContext,
const CSSM_DATA *KRInData,
const CSSM_ACCESS_CREDENTIALS *AccessCredentials,
CSSM_KR_POLICY_FLAGS KRFlags,
sint32 *EstimatedTime,
CSSM_HANDLE_PTR ReferenceHandle);
CSSM_RETURN ( *RegistrationRetrieve)
(CSSM_KRSP_HANDLE KRSPHandle,
CSSM_HANDLE ReferenceHandle,
sint32 *EstimatedTime,
CSSM_KR_PROFILE_PTR KRProfile);
CSSM_RETURN ( *GenerateRecoveryFields)
(CSSM_KRSP_HANDLE KRSPHandle,
CSSM_CC_HANDLE KREnablementContextHandle,
const CSSM_CONTEXT *KREnablementContext,
CSSM_CC_HANDLE CryptoContextHandle,
const CSSM_CONTEXT *CryptoContext,
const CSSM_DATA *KRSPOptions,
CSSM_KR_POLICY_FLAGS KRFlags,
CSSM_DATA_PTR KRFields);
CSSM_RETURN ( *ProcessRecoveryFields)
(CSSM_KRSP_HANDLE KRSPHandle,
CSSM_CC_HANDLE KREnablementContextHandle,
const CSSM_CONTEXT *KREnablementContext,
CSSM_CC_HANDLE CryptoContextHandle,
const CSSM_CONTEXT *CryptoContext,
const CSSM_DATA *KRSPOptions,
CSSM_KR_POLICY_FLAGS KRFlags,
const CSSM_DATA *KRFields);
CSSM_RETURN ( *RecoveryRequest)
(CSSM_KRSP_HANDLE KRSPHandle,
CSSM_CC_HANDLE KRRequestContextHandle,
const CSSM_CONTEXT *KRRequestContext,
const CSSM_DATA *KRInData,
const CSSM_ACCESS_CREDENTIALS *AccessCredentials,
sint32 *EstimatedTime,
CSSM_HANDLE_PTR ReferenceHandle);
CSSM_RETURN ( *RecoveryRetrieve)
(CSSM_KRSP_HANDLE KRSPHandle,
CSSM_HANDLE ReferenceHandle,
sint32 *EstimatedTime,
CSSM_HANDLE_PTR CacheHandle,
uint32 *NumberOfRecoveredKeys);
CSSM_RETURN ( *GetRecoveredObject)
(CSSM_KRSP_HANDLE KRSPHandle,
CSSM_HANDLE CacheHandle,
uint32 IndexInResults,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry,
uint32 Flags,
CSSM_KEY_PTR RecoveredKey,
CSSM_DATA_PTR OtherInfo);
CSSM_RETURN ( *RecoveryRequestAbort)
(CSSM_KRSP_HANDLE KRSPHandle,
CSSM_HANDLE ResultsHandle);
CSSM_RETURN ( *PassThrough)
(CSSM_KRSP_HANDLE KRSPHandle,
CSSM_CC_HANDLE KeyRecoveryContextHandle,
const CSSM_CONTEXT *KeyRecoveryContext,
CSSM_CC_HANDLE CryptoContextHandle,
const CSSM_CONTEXT *CryptoContext,
uint32 PassThroughId,
const void *InputParams,
void **OutputParams);
} CSSM_SPI_KR_FUNCS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_SPI_KR_FUNCS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
typedef struct cssm_spi_tp_funcs {
CSSM_RETURN ( *SubmitCredRequest)
(CSSM_TP_HANDLE TPHandle,
const CSSM_TP_AUTHORITY_ID *PreferredAuthority,
CSSM_TP_AUTHORITY_REQUEST_TYPE RequestType,
const CSSM_TP_REQUEST_SET *RequestInput,
const CSSM_TP_CALLERAUTH_CONTEXT *CallerAuthContext,
sint32 *EstimatedTime,
CSSM_DATA_PTR ReferenceIdentifier);
CSSM_RETURN ( *RetrieveCredResult)
(CSSM_TP_HANDLE TPHandle,
const CSSM_DATA *ReferenceIdentifier,
const CSSM_TP_CALLERAUTH_CONTEXT *CallerAuthCredentials,
sint32 *EstimatedTime,
CSSM_BOOL *ConfirmationRequired,
CSSM_TP_RESULT_SET_PTR *RetrieveOutput);
CSSM_RETURN ( *ConfirmCredResult)
(CSSM_TP_HANDLE TPHandle,
const CSSM_DATA *ReferenceIdentifier,
const CSSM_TP_CALLERAUTH_CONTEXT *CallerAuthCredentials,
const CSSM_TP_CONFIRM_RESPONSE *Responses,
const CSSM_TP_AUTHORITY_ID *PreferredAuthority);
CSSM_RETURN ( *ReceiveConfirmation)
(CSSM_TP_HANDLE TPHandle,
const CSSM_DATA *ReferenceIdentifier,
CSSM_TP_CONFIRM_RESPONSE_PTR *Responses,
sint32 *ElapsedTime);
CSSM_RETURN ( *CertReclaimKey)
(CSSM_TP_HANDLE TPHandle,
const CSSM_CERTGROUP *CertGroup,
uint32 CertIndex,
CSSM_LONG_HANDLE KeyCacheHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_RESOURCE_CONTROL_CONTEXT *CredAndAclEntry);
CSSM_RETURN ( *CertReclaimAbort)
(CSSM_TP_HANDLE TPHandle,
CSSM_LONG_HANDLE KeyCacheHandle);
CSSM_RETURN ( *FormRequest)
(CSSM_TP_HANDLE TPHandle,
const CSSM_TP_AUTHORITY_ID *PreferredAuthority,
CSSM_TP_FORM_TYPE FormType,
CSSM_DATA_PTR BlankForm);
CSSM_RETURN ( *FormSubmit)
(CSSM_TP_HANDLE TPHandle,
CSSM_TP_FORM_TYPE FormType,
const CSSM_DATA *Form,
const CSSM_TP_AUTHORITY_ID *ClearanceAuthority,
const CSSM_TP_AUTHORITY_ID *RepresentedAuthority,
CSSM_ACCESS_CREDENTIALS_PTR Credentials);
CSSM_RETURN ( *CertGroupVerify)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_CERTGROUP *CertGroupToBeVerified,
const CSSM_TP_VERIFY_CONTEXT *VerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR VerifyContextResult);
CSSM_RETURN ( *CertCreateTemplate)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
const CSSM_FIELD *CertFields,
CSSM_DATA_PTR CertTemplate);
CSSM_RETURN ( *CertGetAllTemplateFields)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
const CSSM_DATA *CertTemplate,
uint32 *NumberOfFields,
CSSM_FIELD_PTR *CertFields);
CSSM_RETURN ( *CertSign)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DATA *CertTemplateToBeSigned,
const CSSM_CERTGROUP *SignerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *SignerVerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR SignerVerifyResult,
CSSM_DATA_PTR SignedCert);
CSSM_RETURN ( *CrlVerify)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_ENCODED_CRL *CrlToBeVerified,
const CSSM_CERTGROUP *SignerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *VerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR RevokerVerifyResult);
CSSM_RETURN ( *CrlCreateTemplate)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
uint32 NumberOfFields,
const CSSM_FIELD *CrlFields,
CSSM_DATA_PTR NewCrlTemplate);
CSSM_RETURN ( *CertRevoke)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_DATA *OldCrlTemplate,
const CSSM_CERTGROUP *CertGroupToBeRevoked,
const CSSM_CERTGROUP *RevokerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *RevokerVerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR RevokerVerifyResult,
CSSM_TP_CERTCHANGE_REASON Reason,
CSSM_DATA_PTR NewCrlTemplate);
CSSM_RETURN ( *CertRemoveFromCrlTemplate)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_DATA *OldCrlTemplate,
const CSSM_CERTGROUP *CertGroupToBeRemoved,
const CSSM_CERTGROUP *RevokerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *RevokerVerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR RevokerVerifyResult,
CSSM_DATA_PTR NewCrlTemplate);
CSSM_RETURN ( *CrlSign)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_ENCODED_CRL *CrlToBeSigned,
const CSSM_CERTGROUP *SignerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *SignerVerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR SignerVerifyResult,
CSSM_DATA_PTR SignedCrl);
CSSM_RETURN ( *ApplyCrlToDb)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_ENCODED_CRL *CrlToBeApplied,
const CSSM_CERTGROUP *SignerCertGroup,
const CSSM_TP_VERIFY_CONTEXT *ApplyCrlVerifyContext,
CSSM_TP_VERIFY_CONTEXT_RESULT_PTR ApplyCrlVerifyResult);
CSSM_RETURN ( *CertGroupConstruct)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CSP_HANDLE CSPHandle,
const CSSM_DL_DB_LIST *DBList,
const void *ConstructParams,
const CSSM_CERTGROUP *CertGroupFrag,
CSSM_CERTGROUP_PTR *CertGroup);
CSSM_RETURN ( *CertGroupPrune)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
const CSSM_DL_DB_LIST *DBList,
const CSSM_CERTGROUP *OrderedCertGroup,
CSSM_CERTGROUP_PTR *PrunedCertGroup);
CSSM_RETURN ( *CertGroupToTupleGroup)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
const CSSM_CERTGROUP *CertGroup,
CSSM_TUPLEGROUP_PTR *TupleGroup);
CSSM_RETURN ( *TupleGroupToCertGroup)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
const CSSM_TUPLEGROUP *TupleGroup,
CSSM_CERTGROUP_PTR *CertTemplates);
CSSM_RETURN ( *PassThrough)
(CSSM_TP_HANDLE TPHandle,
CSSM_CL_HANDLE CLHandle,
CSSM_CC_HANDLE CCHandle,
const CSSM_DL_DB_LIST *DBList,
uint32 PassThroughId,
const void *InputParams,
void **OutputParams);
} CSSM_SPI_TP_FUNCS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_SPI_TP_FUNCS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
typedef struct cssm_state_funcs {
CSSM_RETURN ( *cssm_GetAttachFunctions)
(CSSM_MODULE_HANDLE hAddIn,
CSSM_SERVICE_MASK AddinType,
void **SPFunctions,
CSSM_GUID_PTR Guid,
CSSM_BOOL *Serialized);
CSSM_RETURN ( *cssm_ReleaseAttachFunctions)
(CSSM_MODULE_HANDLE hAddIn);
CSSM_RETURN ( *cssm_GetAppMemoryFunctions)
(CSSM_MODULE_HANDLE hAddIn,
CSSM_UPCALLS_PTR UpcallTable);
CSSM_RETURN ( *cssm_IsFuncCallValid)
(CSSM_MODULE_HANDLE hAddin,
CSSM_PROC_ADDR SrcAddress,
CSSM_PROC_ADDR DestAddress,
CSSM_PRIVILEGE InPriv,
CSSM_PRIVILEGE *OutPriv,
CSSM_BITMASK Hints,
CSSM_BOOL *IsOK);
CSSM_RETURN ( *cssm_DeregisterManagerServices)
(const CSSM_GUID *GUID);
CSSM_RETURN ( *cssm_DeliverModuleManagerEvent)
(const CSSM_MANAGER_EVENT_NOTIFICATION *EventDescription);
} CSSM_STATE_FUNCS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_STATE_FUNCS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
typedef struct cssm_manager_registration_info {
CSSM_RETURN ( *Initialize)
(uint32 VerMajor,
uint32 VerMinor);
CSSM_RETURN ( *Terminate) (void);
CSSM_RETURN ( *RegisterDispatchTable)
(CSSM_STATE_FUNCS_PTR CssmStateCallTable);
CSSM_RETURN ( *DeregisterDispatchTable) (void);
CSSM_RETURN ( *EventNotifyManager)
(const CSSM_MANAGER_EVENT_NOTIFICATION *EventDescription);
CSSM_RETURN ( *RefreshFunctionTable)
(CSSM_FUNC_NAME_ADDR_PTR FuncNameAddrPtr,
uint32 NumOfFuncNameAddr);
} CSSM_MANAGER_REGISTRATION_INFO __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *CSSM_MANAGER_REGISTRATION_INFO_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
enum {
CSSM_HINT_NONE = 0,
CSSM_HINT_ADDRESS_APP = 1 << 0,
CSSM_HINT_ADDRESS_SP = 1 << 1
};
CSSM_RETURN
ModuleManagerAuthenticate (CSSM_KEY_HIERARCHY KeyHierarchy,
const CSSM_GUID *CssmGuid,
const CSSM_GUID *AppGuid,
CSSM_MANAGER_REGISTRATION_INFO_PTR FunctionTable)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
typedef CSSM_DL_HANDLE MDS_HANDLE;
typedef CSSM_DL_DB_HANDLE MDS_DB_HANDLE;
typedef struct mds_funcs {
CSSM_RETURN ( *DbOpen)
(MDS_HANDLE MdsHandle,
const char *DbName,
const CSSM_NET_ADDRESS *DbLocation,
CSSM_DB_ACCESS_TYPE AccessRequest,
const CSSM_ACCESS_CREDENTIALS *AccessCred,
const void *OpenParameters,
CSSM_DB_HANDLE *hMds);
CSSM_RETURN ( *DbClose)
(MDS_DB_HANDLE MdsDbHandle);
CSSM_RETURN ( *GetDbNames)
(MDS_HANDLE MdsHandle,
CSSM_NAME_LIST_PTR *NameList);
CSSM_RETURN ( *GetDbNameFromHandle)
(MDS_DB_HANDLE MdsDbHandle,
char **DbName);
CSSM_RETURN ( *FreeNameList)
(MDS_HANDLE MdsHandle,
CSSM_NAME_LIST_PTR NameList);
CSSM_RETURN ( *DataInsert)
(MDS_DB_HANDLE MdsDbHandle,
CSSM_DB_RECORDTYPE RecordType,
const CSSM_DB_RECORD_ATTRIBUTE_DATA *Attributes,
const CSSM_DATA *Data,
CSSM_DB_UNIQUE_RECORD_PTR *UniqueId);
CSSM_RETURN ( *DataDelete)
(MDS_DB_HANDLE MdsDbHandle,
const CSSM_DB_UNIQUE_RECORD *UniqueRecordIdentifier);
CSSM_RETURN ( *DataModify)
(MDS_DB_HANDLE MdsDbHandle,
CSSM_DB_RECORDTYPE RecordType,
CSSM_DB_UNIQUE_RECORD_PTR UniqueRecordIdentifier,
const CSSM_DB_RECORD_ATTRIBUTE_DATA *AttributesToBeModified,
const CSSM_DATA *DataToBeModified,
CSSM_DB_MODIFY_MODE ModifyMode);
CSSM_RETURN ( *DataGetFirst)
(MDS_DB_HANDLE MdsDbHandle,
const CSSM_QUERY *Query,
CSSM_HANDLE_PTR ResultsHandle,
CSSM_DB_RECORD_ATTRIBUTE_DATA_PTR Attributes,
CSSM_DATA_PTR Data,
CSSM_DB_UNIQUE_RECORD_PTR *UniqueId);
CSSM_RETURN ( *DataGetNext)
(MDS_DB_HANDLE MdsDbHandle,
CSSM_HANDLE ResultsHandle,
CSSM_DB_RECORD_ATTRIBUTE_DATA_PTR Attributes,
CSSM_DATA_PTR Data,
CSSM_DB_UNIQUE_RECORD_PTR *UniqueId);
CSSM_RETURN ( *DataAbortQuery)
(MDS_DB_HANDLE MdsDbHandle,
CSSM_HANDLE ResultsHandle);
CSSM_RETURN ( *DataGetFromUniqueRecordId)
(MDS_DB_HANDLE MdsDbHandle,
const CSSM_DB_UNIQUE_RECORD *UniqueRecord,
CSSM_DB_RECORD_ATTRIBUTE_DATA_PTR Attributes,
CSSM_DATA_PTR Data);
CSSM_RETURN ( *FreeUniqueRecord)
(MDS_DB_HANDLE MdsDbHandle,
CSSM_DB_UNIQUE_RECORD_PTR UniqueRecord);
CSSM_RETURN ( *CreateRelation)
(MDS_DB_HANDLE MdsDbHandle,
CSSM_DB_RECORDTYPE RelationID,
const char *RelationName,
uint32 NumberOfAttributes,
const CSSM_DB_SCHEMA_ATTRIBUTE_INFO *pAttributeInfo,
uint32 NumberOfIndexes,
const CSSM_DB_SCHEMA_INDEX_INFO *pIndexInfo);
CSSM_RETURN ( *DestroyRelation)
(MDS_DB_HANDLE MdsDbHandle,
CSSM_DB_RECORDTYPE RelationID);
} MDS_FUNCS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))), *MDS_FUNCS_PTR __attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
MDS_Initialize (const CSSM_GUID *pCallerGuid,
const CSSM_MEMORY_FUNCS *pMemoryFunctions,
MDS_FUNCS_PTR pDlFunctions,
MDS_HANDLE *hMds)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
MDS_Terminate (MDS_HANDLE MdsHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
MDS_Install (MDS_HANDLE MdsHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
CSSM_RETURN
MDS_Uninstall (MDS_HANDLE MdsHandle)
__attribute__((availability(macosx,introduced=10.0,deprecated=10.7)));
}
extern "C" {
}
typedef CSSM_DATA SecAsn1Item;
typedef CSSM_OID SecAsn1Oid;
typedef CSSM_X509_ALGORITHM_IDENTIFIER SecAsn1AlgId;
typedef CSSM_X509_SUBJECT_PUBLIC_KEY_INFO SecAsn1PubKeyInfo;
typedef struct SecAsn1Template_struct {
uint32_t kind;
uint32_t offset;
const void *sub;
uint32_t size;
} SecAsn1Template;
typedef const SecAsn1Template * SecAsn1TemplateChooser(
void *arg,
Boolean enc,
const char *buf,
void *dest);
typedef SecAsn1TemplateChooser * SecAsn1TemplateChooserPtr;
extern "C" {
extern const SecAsn1Oid
CSSMOID_MD2 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_MD4 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_MD5 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_RSA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_MD2WithRSA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_MD4WithRSA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_MD5WithRSA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA1WithRSA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA224WithRSA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA256WithRSA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA384WithRSA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA512WithRSA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA1WithRSA_OIW __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_RSAWithOAEP __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_OAEP_MGF1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_OAEP_ID_PSPECIFIED __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_DES_CBC __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_PUB_NUMBER __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_STATIC __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_ONE_FLOW __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_EPHEM __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_HYBRID1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_HYBRID2 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_HYBRID_ONEFLOW __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_MQV1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_MQV2 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_STATIC_SHA1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_ONE_FLOW_SHA1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_EPHEM_SHA1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_HYBRID1_SHA1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_DH_HYBRID2_SHA1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_MQV1_SHA1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ANSI_MQV2_SHA1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_PKCS3 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_DH __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_DSA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_DSA_CMS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_DSA_JDK __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA1WithDSA __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA1WithDSA_CMS __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA1WithDSA_JDK __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA224 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA256 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA384 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_SHA512 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ecPublicKey __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ECDSA_WithSHA1 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ECDSA_WithSHA224 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ECDSA_WithSHA256 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ECDSA_WithSHA384 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ECDSA_WithSHA512 __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_ECDSA_WithSpecified __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_ISIGN __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_X509_BASIC __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_SSL __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_LOCAL_CERT_GEN __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_CSR_GEN __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_REVOCATION_CRL __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_REVOCATION_OCSP __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_SMIME __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_EAP __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_CODE_SIGN __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_SW_UPDATE_SIGNING __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_IP_SEC __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_ICHAT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_RESOURCE_SIGN __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_PKINIT_CLIENT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_PKINIT_SERVER __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_CODE_SIGNING __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_PACKAGE_SIGNING __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_MACAPPSTORE_RECEIPT __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_APPLEID_SHARING __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_TIMESTAMPING __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_REVOCATION __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_PASSBOOK_SIGNING __attribute__((availability(macosx,introduced=10.0,deprecated=10.7))),
CSSMOID_APPLE_TP_MOBILE_STORE __attribute__((availability(m
View raw

(Sorry about that, but we can’t show files that are this big right now.)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment