NSString学习

  1. UTF8String   这个方法将NSString转为C语言中以'\0'结尾的字符串.

    Returns a null-terminated UTF8 representation of the receiver.

    - (const char *)UTF8String

    Return Value

    A null-terminated UTF8 representation of the receiver.

    Discussion

    The returned C string is automatically freed just as a returned object would be released; you should copy the C string if it needs to store it outside of the autorelease context in which the C string is created.

    

原文地址:https://www.cnblogs.com/woainilsr/p/2368048.html