109 {
110 bool flag = false;
111 if (data[currentIndex] == '"')
112 {
113 flag = true;
114 currentIndex++;
115 }
117 {
119 return null;
120 }
122 while (currentIndex < data.Length && ((flag && data[currentIndex] != '"') || (!flag && data[currentIndex] != ',')))
123 {
125 currentIndex++;
126 if (currentIndex == data.Length || (!flag &&
CharIsSpaceOrTab(data[currentIndex])))
127 {
128 break;
129 }
130 if (flag && data[currentIndex] == '"' && data[currentIndex - 1] == '\\')
131 {
133 currentIndex++;
134 }
135 }
136 if (flag)
137 {
138 currentIndex++;
139 }
141 {
142 currentIndex++;
143 }
144 if (currentIndex == data.Length)
145 {
148 }
149 if (data[currentIndex++] != ',')
150 {
152 return null;
153 }
155 {
156 currentIndex++;
157 }
160 }
static bool CharIsSpaceOrTab(char ch)
static string GetStringAndRelease(StringBuilder sb)
static StringBuilder Acquire(int capacity=16)