You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by ra...@apache.org on 2005/02/16 09:15:36 UTC
cvs commit: ws-axis/c/src/common AxisUtils.h AxisUtils.cpp
rangika 2005/02/16 00:15:36
Modified: c/src/common AxisUtils.h AxisUtils.cpp
Log:
Added the isStringOnlyWithSpaces() method to check strings with white spaces.
Revision Changes Path
1.23 +2 -0 ws-axis/c/src/common/AxisUtils.h
Index: AxisUtils.h
===================================================================
RCS file: /home/cvs/ws-axis/c/src/common/AxisUtils.h,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -r1.22 -r1.23
--- AxisUtils.h 19 Jan 2005 09:37:06 -0000 1.22
+++ AxisUtils.h 16 Feb 2005 08:15:36 -0000 1.23
@@ -49,6 +49,8 @@
friend class URIMapping;
public:
+ static bool isStringOnlyWithSpaces(const char* pchWord);
+
/**
* Decodes the given base64 string and returns it.
*/
1.25 +16 -1 ws-axis/c/src/common/AxisUtils.cpp
Index: AxisUtils.cpp
===================================================================
RCS file: /home/cvs/ws-axis/c/src/common/AxisUtils.cpp,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- AxisUtils.cpp 31 Jan 2005 13:17:46 -0000 1.24
+++ AxisUtils.cpp 16 Feb 2005 08:15:36 -0000 1.25
@@ -149,5 +149,20 @@
return value;
}
+bool AxisUtils::isStringOnlyWithSpaces(const char* pchWord)
+{
+ bool blnStatus = true;
-AXIS_CPP_NAMESPACE_END
+ int iLen = strlen(pchWord);
+
+ for (int i=0; i<iLen; i++) {
+ if (pchWord[i] != ' ') {
+ blnStatus = false;
+ break;
+ }
+ }
+
+ return blnStatus;
+}
+
+AXIS_CPP_NAMESPACE_END
\ No newline at end of file