public String getNextToken() {if( pos >= format.length() ) {return null;}int subStart = pos;final char curChar = format.charAt(pos);++pos;if( curChar == '\'' ) {while( ( pos < format.length() ) && ( format.charAt(pos) != '\'' ) ) {++pos;}if( pos < format.length() ) {++pos;}} else {while( ( pos < format.length() ) && ( format.charAt(pos) == curChar ) ) {++pos;}}return format.substring(subStart,pos);}
public string GetNextToken(){if (pos >= format.Length){return null;}int subStart = pos;char curChar = format[pos];++pos;if (curChar == '\''){while ((pos < format.Length) && ((curChar = format[pos]) != '\'')){++pos;}if (pos < format.Length){++pos;}}else{char activeChar = curChar;while ((pos < format.Length) && ((curChar = format[pos])) == activeChar){++pos;}}return format.Substring(subStart, pos - subStart);}