I have got below value(dynamic) from the server:
drwxr-xr-x 9 0 0 4096 Jan 10 05:30 California
Now i want to get valu like this.
drwxr-xr-x 9 0 0 4096 Jan 10 05:30 California
Please help me for this question
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
As others have mentioned, you can use
NSString'smember functioncomponentsSeparatedByString:orcomponentsSeparatedByCharactersInSet:As an alternative (for more powerful tokenizing), look into the Objective-C NSScanner class in the foundation framework of Mac OS X.
You could do something like this:
In order to obtain each token in string form, use
NSScanner'sscanUpToCharactersFromSet:intoString:member function.Subsequent calls to the above would return 9, 0, and so on.
Note: the code above has not been tested.