- All Superinterfaces:
com.sun.jna.Library
public interface CoreFoundationExt
extends com.sun.jna.Library
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic classstatic classA CFError object encapsulates more rich and extensible error information than is possible using only an error code or error string.static classstatic final recordUnwrapped version of CFErrorRef without native referencesNested classes/interfaces inherited from interface com.sun.jna.Library
com.sun.jna.Library.Handler -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.sun.jna.platform.mac.CoreFoundation.CFTypeIDstatic final CoreFoundationExtstatic final com.sun.jna.platform.mac.CoreFoundation.CFBooleanRefBoolean false value.static final com.sun.jna.platform.mac.CoreFoundation.CFBooleanRefBoolean true value.static final StringMac OS 9/Carbon errorsFields inherited from interface com.sun.jna.Library
OPTION_ALLOW_OBJECTS, OPTION_CALLING_CONVENTION, OPTION_CLASSLOADER, OPTION_FUNCTION_MAPPER, OPTION_INVOCATION_MAPPER, OPTION_OPEN_FLAGS, OPTION_STRING_ENCODING, OPTION_STRUCTURE_ALIGNMENT, OPTION_SYMBOL_PROVIDER, OPTION_TYPE_MAPPER -
Method Summary
Modifier and TypeMethodDescriptioncom.sun.jna.platform.mac.CoreFoundation.CFArrayRefCFArrayCreate(com.sun.jna.platform.mac.CoreFoundation.CFAllocatorRef alloc, com.sun.jna.platform.mac.CoreFoundation.CFTypeRef[] values, com.sun.jna.platform.mac.CoreFoundation.CFIndex numValues, com.sun.jna.Pointer callBacks) Creates a new immutable array with the given values.com.sun.jna.platform.mac.CoreFoundation.CFDictionaryRefCFDictionaryCreate(com.sun.jna.platform.mac.CoreFoundation.CFAllocatorRef allocator, com.sun.jna.platform.mac.CoreFoundation.CFTypeRef[] keys, com.sun.jna.platform.mac.CoreFoundation.CFTypeRef[] values, com.sun.jna.platform.mac.CoreFoundation.CFIndex numValues, com.sun.jna.Pointer keyCallBacks, com.sun.jna.Pointer valueCallBacks) Creates an immutable dictionary containing the specified key-value pairs.com.sun.jna.platform.mac.CoreFoundation.CFIndexCFDictionaryGetCount(com.sun.jna.platform.mac.CoreFoundation.CFDictionaryRef theDict) Returns the number of key-value pairs in a dictionary.booleanCFEqual(com.sun.jna.platform.mac.CoreFoundation.CFTypeRef cf1, com.sun.jna.platform.mac.CoreFoundation.CFTypeRef cf2) Determines whether two Core Foundation objects are considered equal.com.sun.jna.platform.mac.CoreFoundation.CFStringRefReturns a human-presentable description for a given error.com.sun.jna.platform.mac.CoreFoundation.CFIndexReturns the error code for a given CFError.com.sun.jna.platform.mac.CoreFoundation.CFStringRefReturns the error domain for a given CFError.com.sun.jna.platform.mac.CoreFoundation.CFTypeID
-
Field Details
-
INSTANCE
-
ERROR_TYPE_ID
static final com.sun.jna.platform.mac.CoreFoundation.CFTypeID ERROR_TYPE_ID -
NSOSStatusErrorDomain
Mac OS 9/Carbon errors -
kCFBooleanFalse
static final com.sun.jna.platform.mac.CoreFoundation.CFBooleanRef kCFBooleanFalseBoolean false value. -
kCFBooleanTrue
static final com.sun.jna.platform.mac.CoreFoundation.CFBooleanRef kCFBooleanTrueBoolean true value.
-
-
Method Details
-
CFErrorGetTypeID
com.sun.jna.platform.mac.CoreFoundation.CFTypeID CFErrorGetTypeID() -
CFErrorGetDomain
@NotNull com.sun.jna.platform.mac.CoreFoundation.CFStringRef CFErrorGetDomain(CoreFoundationExt.CFErrorRef error) Returns the error domain for a given CFError.- Returns:
- The error domain for err. Ownership follows The Get Rule.
- See Also:
-
CFErrorCopyDescription
@NotNull com.sun.jna.platform.mac.CoreFoundation.CFStringRef CFErrorCopyDescription(CoreFoundationExt.CFErrorRef err) Returns a human-presentable description for a given error.- Returns:
- A localized, human-presentable description of err. This function never returns NULL.
- See Also:
-
CFErrorGetCode
Returns the error code for a given CFError.- Returns:
- The error code of err.
- See Also:
-
CFDictionaryGetCount
com.sun.jna.platform.mac.CoreFoundation.CFIndex CFDictionaryGetCount(com.sun.jna.platform.mac.CoreFoundation.CFDictionaryRef theDict) Returns the number of key-value pairs in a dictionary.- Parameters:
theDict- The dictionary to examine.- Returns:
- The number of key-value pairs in theDict.
- See Also:
-
CFDictionaryCreate
com.sun.jna.platform.mac.CoreFoundation.CFDictionaryRef CFDictionaryCreate(com.sun.jna.platform.mac.CoreFoundation.CFAllocatorRef allocator, com.sun.jna.platform.mac.CoreFoundation.CFTypeRef[] keys, com.sun.jna.platform.mac.CoreFoundation.CFTypeRef[] values, com.sun.jna.platform.mac.CoreFoundation.CFIndex numValues, com.sun.jna.Pointer keyCallBacks, com.sun.jna.Pointer valueCallBacks) Creates an immutable dictionary containing the specified key-value pairs.- Returns:
- A new dictionary, or NULL if there was a problem creating the object. Ownership follows the Create Rule.
- See Also:
-
CFArrayCreate
com.sun.jna.platform.mac.CoreFoundation.CFArrayRef CFArrayCreate(com.sun.jna.platform.mac.CoreFoundation.CFAllocatorRef alloc, com.sun.jna.platform.mac.CoreFoundation.CFTypeRef[] values, com.sun.jna.platform.mac.CoreFoundation.CFIndex numValues, com.sun.jna.Pointer callBacks) Creates a new immutable array with the given values.This reference must be released with
CoreFoundation.CFRelease(com.sun.jna.platform.mac.CoreFoundation.CFTypeRef)to avoid leaking references.This is like
CoreFoundation.CFArrayCreate(CoreFoundation.CFAllocatorRef, Pointer, CoreFoundation.CFIndex, Pointer)but it takes aPointer[]instead.- Parameters:
alloc- The allocator to use to allocate memory for the new array and its storage for values. PassnullorkCFAllocatorDefaultto use the current default allocator.values- A C array of the pointer-sized values to be in the new array. The values in the new array are ordered in the same order in which they appear in this C array. This value may benullifnumValuesis 0. This C array is not changed or freed by this function. Ifvaluesis not a valid pointer to a C array of at leastnumValueselements, the behavior is undefined.numValues- The number of values to copy from thevaluesC array into the new array. This number will be the count of the new array—it must not be negative or greater than the number of elements in values.callBacks- A pointer to aCFArrayCallBacksstructure initialized with the callbacks for the array to use on each value in the collection. The retain callback is used within this function, for example, to retain all of the new values from thevaluesC array. A copy of the contents of the callbacks structure is made so that a pointer to a structure on the stack can be passed in or can be reused for multiple collection creations.This value may be
null, which is treated as if a valid structure of version 0 with all fieldsnullhad been passed in.- Returns:
- A new immutable array containing
numValuesfromvalues, ornullif there was a problem creating the object. - See Also:
-
CFEqual
boolean CFEqual(com.sun.jna.platform.mac.CoreFoundation.CFTypeRef cf1, com.sun.jna.platform.mac.CoreFoundation.CFTypeRef cf2) Determines whether two Core Foundation objects are considered equal.- Parameters:
cf1- A CFType object to compare to cf2.cf2- A CFType object to compare to cf1.- Returns:
- true if cf1 and cf2 are of the same type and considered equal, otherwise false.
- See Also:
-