ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/include/shstr.h
(Generate patch)

Comparing deliantra/server/include/shstr.h (file contents):
Revision 1.37 by root, Tue Nov 10 04:38:45 2009 UTC vs.
Revision 1.41 by root, Tue Jan 3 11:25:32 2012 UTC

1/* 1/*
2 * This file is part of Deliantra, the Roguelike Realtime MMORPG. 2 * This file is part of Deliantra, the Roguelike Realtime MMORPG.
3 * 3 *
4 * Copyright (©) 2005,2006,2007,2008,2009 Marc Alexander Lehmann / Robin Redeker / the Deliantra team 4 * Copyright (©) 2005,2006,2007,2008,2009,2010,2011,2012 Marc Alexander Lehmann / Robin Redeker / the Deliantra team
5 * 5 *
6 * Deliantra is free software: you can redistribute it and/or modify it under 6 * Deliantra is free software: you can redistribute it and/or modify it under
7 * the terms of the Affero GNU General Public License as published by the 7 * the terms of the Affero GNU General Public License as published by the
8 * Free Software Foundation, either version 3 of the License, or (at your 8 * Free Software Foundation, either version 3 of the License, or (at your
9 * option) any later version. 9 * option) any later version.
84 } 84 }
85 85
86 // returns true if the substring is contained in the shstr 86 // returns true if the substring is contained in the shstr
87 // if the shstr is 0, then this always returns false. 87 // if the shstr is 0, then this always returns false.
88 // the shstr is (theoretically) treated as a comma/colon/space etc. separated list. 88 // the shstr is (theoretically) treated as a comma/colon/space etc. separated list.
89 bool contains (const char *substring) const 89 bool contains (const char *substring) const;
90 {
91 return s != null () && strstr (s, substring);
92 }
93 90
94 //TODO: case sensitive should be eradicated 91 //TODO: case sensitive should be eradicated
95 bool eq_nc (const char *otherstring) const 92 bool eq_nc (const char *otherstring) const
96 { 93 {
97 return !strcasecmp (s, otherstring); 94 return !strcasecmp (s, otherstring);

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines