About Store Forum Documentation Contact



Post Reply 
Str class
Author Message
Rofar Offline
Member

Post: #1
Str class
Unless I'm just missing something, it appears that the Str class has no comparison operator. I don't really see any way to easily compare strings. Am I overlooking something?
01-24-2010 08:30 PM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #2
RE: Str class
in string.h:
Code:
Int      Compare        (CChar8  *a  ,CChar8  *b    );                           // compare  text, returns -1,0,1
       Int      Compare        (CChar8  *a  ,CChar16 *b    );                           // compare  text, returns -1,0,1
       Int      Compare        (CChar16 *a  ,CChar8  *b    );                           // compare  text, returns -1,0,1
       Int      Compare        (CChar16 *a  ,CChar16 *b    );                           // compare  text, returns -1,0,1
       Int      ComparePath    (CChar8  *a  ,CChar8  *b    );                           // compare  path, returns -1,0,1 (treats '/'=='\')
       Int      ComparePath    (CChar8  *a  ,CChar16 *b    );                           // compare  path, returns -1,0,1 (treats '/'=='\')
       Int      ComparePath    (CChar16 *a  ,CChar8  *b    );                           // compare  path, returns -1,0,1 (treats '/'=='\')
       Int      ComparePath    (CChar16 *a  ,CChar16 *b    );                           // compare  path, returns -1,0,1 (treats '/'=='\')

you can directly put Str as arguments into these functions, without any manual casting
01-24-2010 08:43 PM
Find all posts by this user Quote this message in a reply
Rofar Offline
Member

Post: #3
RE: Str class
Ah, thanks. I just knew I had to have overlooked it.
01-24-2010 08:52 PM
Find all posts by this user Quote this message in a reply
menajev Offline
Member

Post: #4
RE: Str class
There is no function to get part of a string (e.g. str.getPart(2,4))?
06-07-2010 12:08 PM
Find all posts by this user Quote this message in a reply
Post Reply