Skip navigation.
 
mlRe: Cocoa programming
FROM : Richard
DATE : Sat Nov 09 17:14:01 2002

The pointer notation in Obj-C for objects is equivalent to the same thing in Java.
Java objects are actually references which are equivalent in some respects to pointers.

The % notation is taken from c with some extensions.
%d means insert the characters representing a single precision integer in DECIMAL format.
%ld means insert the characters representing a long (32bit integer) in DECIMAL format.
%x means insert the characters representing a single precision integer in HEXADECIMAL format.
%s means insert the characters of a char*.
%f, %e, %E, %G ar for floating point,
So by extension  %@ means insert the NSString (a unicode string).

Look up the c docs on printf and sprintf to get a complete list




Related mailsAuthorDate
mlCocoa programming Joachim Haagen Bøe Nov 9, 05:14
mlRe: Cocoa programming Jon Johnson Nov 9, 05:40
mlRe: Cocoa programming Andreas Höschler Nov 9, 05:42
mlRe: Cocoa programming Fabien Roy Nov 9, 08:51
mlRe: Cocoa programming Sanjay Samani Nov 9, 09:32
mlRe: Cocoa programming Richard Nov 9, 17:14
mlRe: Cocoa programming Hasan Diwan Nov 9, 18:01
mlRe: Cocoa programming Joachim Haagen Bøe Nov 9, 18:13