## @file\r
# preprocess source file\r
#\r
-# Copyright (c) 2007 - 2014, Intel Corporation. All rights reserved.<BR>\r
+# Copyright (c) 2007 - 2018, Intel Corporation. All rights reserved.<BR>\r
#\r
# This program and the accompanying materials\r
# are licensed and made available under the terms and conditions of the BSD License\r
self.__Token = ""\r
self.__SkippedChars = ""\r
\r
- ## __IsWhiteSpace() method\r
- #\r
- # Whether char at current FileBufferPos is whitespace\r
- #\r
- # @param self The object pointer\r
- # @param Char The char to test\r
- # @retval True The char is a kind of white space\r
- # @retval False The char is NOT a kind of white space\r
- #\r
- def __IsWhiteSpace(self, Char):\r
- if Char in (T_CHAR_NULL, T_CHAR_CR, T_CHAR_SPACE, T_CHAR_TAB, T_CHAR_LF):\r
- return True\r
- else:\r
- return False\r
-\r
- ## __SkipWhiteSpace() method\r
- #\r
- # Skip white spaces from current char, return number of chars skipped\r
- #\r
- # @param self The object pointer\r
- # @retval Count The number of chars skipped\r
- #\r
- def __SkipWhiteSpace(self):\r
- Count = 0\r
- while not self.__EndOfFile():\r
- Count += 1\r
- if self.__CurrentChar() in (T_CHAR_NULL, T_CHAR_CR, T_CHAR_LF, T_CHAR_SPACE, T_CHAR_TAB):\r
- self.__SkippedChars += str(self.__CurrentChar())\r
- self.__GetOneChar()\r
-\r
- else:\r
- Count = Count - 1\r
- return Count\r
-\r
## __EndOfFile() method\r
#\r
# Judge current buffer pos is at file end\r