You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@manifoldcf.apache.org by kw...@apache.org on 2013/02/10 10:26:22 UTC
svn commit: r1444520 -
/manifoldcf/branches/CONNECTORS-633/framework/core/src/main/java/org/apache/manifoldcf/core/fuzzyml/TagParseState.java
Author: kwright
Date: Sun Feb 10 09:26:22 2013
New Revision: 1444520
URL: http://svn.apache.org/r1444520
Log:
Debug
Modified:
manifoldcf/branches/CONNECTORS-633/framework/core/src/main/java/org/apache/manifoldcf/core/fuzzyml/TagParseState.java
Modified: manifoldcf/branches/CONNECTORS-633/framework/core/src/main/java/org/apache/manifoldcf/core/fuzzyml/TagParseState.java
URL: http://svn.apache.org/viewvc/manifoldcf/branches/CONNECTORS-633/framework/core/src/main/java/org/apache/manifoldcf/core/fuzzyml/TagParseState.java?rev=1444520&r1=1444519&r2=1444520&view=diff
==============================================================================
--- manifoldcf/branches/CONNECTORS-633/framework/core/src/main/java/org/apache/manifoldcf/core/fuzzyml/TagParseState.java (original)
+++ manifoldcf/branches/CONNECTORS-633/framework/core/src/main/java/org/apache/manifoldcf/core/fuzzyml/TagParseState.java Sun Feb 10 09:26:22 2013
@@ -500,6 +500,65 @@ public class TagParseState extends Singl
currentTagNameBuffer.append(thisChar);
break;
+ case TAGPARSESTATE_IN_QTAG_ATTR_NAME:
+ if (isWhitespace(thisChar))
+ {
+ if (currentAttrNameBuffer.length() > 0)
+ {
+ // Done with attr name!
+ currentAttrName = currentAttrNameBuffer.toString();
+ currentAttrNameBuffer = null;
+ currentState = TAGPARSESTATE_IN_QTAG_ATTR_LOOKING_FOR_VALUE;
+ }
+ }
+ else if (thisChar == '=')
+ {
+ if (currentAttrNameBuffer.length() > 0)
+ {
+ currentAttrName = currentAttrNameBuffer.toString();
+ currentAttrNameBuffer = null;
+ currentState = TAGPARSESTATE_IN_QTAG_ATTR_VALUE;
+ currentValueBuffer = new StringBuilder();
+ }
+ }
+ else if (thisChar == '?')
+ {
+ if (currentAttrNameBuffer.length() > 0)
+ {
+ currentAttrName = currentAttrNameBuffer.toString();
+ currentAttrNameBuffer = null;
+ }
+ if (currentAttrName != null)
+ {
+ currentAttrList.add(new AttrNameValue(currentAttrName,""));
+ currentAttrName = null;
+ }
+ if (noteQTag(currentTagName,currentAttrList))
+ return true;
+ currentState = TAGPARSESTATE_IN_QTAG_SAW_QUESTION;
+ }
+ else if (thisChar == '>')
+ {
+ if (currentAttrNameBuffer.length() > 0)
+ {
+ currentAttrName = currentAttrNameBuffer.toString();
+ currentAttrNameBuffer = null;
+ }
+ if (currentAttrName != null)
+ {
+ currentAttrList.add(new AttrNameValue(currentAttrName,""));
+ currentAttrName = null;
+ }
+ currentState = TAGPARSESTATE_NORMAL;
+ if (noteQTag(currentTagName,currentAttrList))
+ return true;
+ currentTagName = null;
+ currentAttrList = null;
+ }
+ else
+ currentAttrNameBuffer.append(thisChar);
+ break;
+
case TAGPARSESTATE_IN_ATTR_NAME:
if (isWhitespace(thisChar))
{