Parses an attribute name. The current position should be the first character of the name. Returns the parsed name string.
()
| 281 | /// </summary> |
| 282 | /// <returns>Returns the parsed name string.</returns> |
| 283 | private string ParseAttributeName() |
| 284 | { |
| 285 | int start = _pos; |
| 286 | while (!EOF) |
| 287 | { |
| 288 | var c = Peek(); |
| 289 | if (!char.IsLetterOrDigit(c) && c != '-') |
| 290 | break; |
| 291 | Move(); |
| 292 | } |
| 293 | return _html.Substring(start, _pos - start); |
| 294 | } |
| 295 | |
| 296 | /// <summary> |
| 297 | /// Parses an attribute value. The current position should be the first non-whitespace character following the equal sign. |