CFStringCreateWithFormatAndArguments(_:_:_:_:)
Creates an immutable string from a formatted string and a variable number of arguments (specified in a parameter of type va_list).
Declaration
func CFStringCreateWithFormatAndArguments(_ alloc: CFAllocator!, _ formatOptions: CFDictionary!, _ format: CFString!, _ arguments: CVaListPointer) -> CFString!Parameters
- alloc:
The allocator to use to allocate memory for the new string. Pass
NULLor Kcfallocatordefault to use the current default allocator. - formatOptions:
A CFDictionary object containing formatting options for the string (such as the thousand-separator character, which is dependent on locale). Currently, these options are an unimplemented feature.
- format:
The formatted string with
printf-style specifiers. For information on supported specifiers, see TP40004265. - arguments:
The variable argument list of values to be inserted into the formatted string contained in
format.
Return Value
An immutable string, or NULL if there was a problem creating the object. Ownership follows the The Create Rule.
Discussion
The programming interface for variable argument lists (va_list, va_start, va_end, and so forth) is declared in the standard C header file stdarg.h.
See Also
Creating a CFString
CFStringCreateArrayBySeparatingStrings(_:_:_:)CFStringCreateByCombiningStrings(_:_:_:)CFStringCreateCopy(_:_:)CFStringCreateFromExternalRepresentation(_:_:_:)CFStringCreateWithBytes(_:_:_:_:_:)CFStringCreateWithBytesNoCopy(_:_:_:_:_:_:)CFStringCreateWithCharacters(_:_:_:)CFStringCreateWithCharactersNoCopy(_:_:_:_:)CFStringCreateWithCString(_:_:_:)CFStringCreateWithCStringNoCopy(_:_:_:_:)CFStringCreateWithPascalString(_:_:_:)CFStringCreateWithPascalStringNoCopy(_:_:_:_:)CFStringCreateWithSubstring(_:_:_:)