somPrintf
Appearance
This function prints a formatted string in the manner of the C printf function.
Syntax
string fmt; long rc; rc = somPrintf(fmt,· · ·);
The values to be substituted into the format string.
Parameters
- fmt (string)
- The format string to be output.
Return Code
- rc (long)
- Returns the number of characters written.
Remarks
This function prints a formatted string using function SOMOutCharRoutine, in the same manner as the C printf function. The implementation of SOMOutCharRoutine determines the destination of the output, while the C printf function is always directed to stdout. (The default output destination for SOMOutCharRoutine is stdout also, but this can be modified by the user.)
Example Code
#include <somcls.h> somPrintf("The class name is %s.\n", _somGetClassName(obj));
Related
- Functions