OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2000 Peter Kelly (pmk@post.com) | 2 * Copyright (C) 2000 Peter Kelly (pmk@post.com) |
3 * Copyright (C) 2005, 2006, 2008, 2014 Apple Inc. All rights reserved. | 3 * Copyright (C) 2005, 2006, 2008, 2014 Apple Inc. All rights reserved. |
4 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 4 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
5 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org) | 5 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org) |
6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) | 6 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) |
7 * Copyright (C) 2008 Holger Hans Peter Freyther | 7 * Copyright (C) 2008 Holger Hans Peter Freyther |
8 * Copyright (C) 2008 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) | 8 * Copyright (C) 2008 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) |
9 * | 9 * |
10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
(...skipping 329 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
340 #endif | 340 #endif |
341 m_currentNodeStack.clear(); | 341 m_currentNodeStack.clear(); |
342 } | 342 } |
343 } | 343 } |
344 | 344 |
345 void XMLDocumentParser::insert(const SegmentedString&) | 345 void XMLDocumentParser::insert(const SegmentedString&) |
346 { | 346 { |
347 ASSERT_NOT_REACHED(); | 347 ASSERT_NOT_REACHED(); |
348 } | 348 } |
349 | 349 |
350 void XMLDocumentParser::append(PassRefPtr<StringImpl> inputSource) | 350 void XMLDocumentParser::append(const String& inputSource) |
351 { | 351 { |
352 SegmentedString source(inputSource); | 352 const SegmentedString source(inputSource); |
353 if (m_sawXSLTransform || !m_sawFirstElement) | 353 if (m_sawXSLTransform || !m_sawFirstElement) |
354 m_originalSourceForTransform.append(source); | 354 m_originalSourceForTransform.append(source); |
355 | 355 |
356 if (isStopped() || m_sawXSLTransform) | 356 if (isStopped() || m_sawXSLTransform) |
357 return; | 357 return; |
358 | 358 |
359 if (m_parserPaused) { | 359 if (m_parserPaused) { |
360 m_pendingSrc.append(source); | 360 m_pendingSrc.append(source); |
361 return; | 361 return; |
362 } | 362 } |
(...skipping 1277 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1640 sax.initialized = XML_SAX2_MAGIC; | 1640 sax.initialized = XML_SAX2_MAGIC; |
1641 RefPtr<XMLParserContext> parser = XMLParserContext::createStringParser(&sax,
&state); | 1641 RefPtr<XMLParserContext> parser = XMLParserContext::createStringParser(&sax,
&state); |
1642 String parseString = "<?xml version=\"1.0\"?><attrs " + string + " />"; | 1642 String parseString = "<?xml version=\"1.0\"?><attrs " + string + " />"; |
1643 parseChunk(parser->context(), parseString); | 1643 parseChunk(parser->context(), parseString); |
1644 finishParsing(parser->context()); | 1644 finishParsing(parser->context()); |
1645 attrsOK = state.gotAttributes; | 1645 attrsOK = state.gotAttributes; |
1646 return state.attributes; | 1646 return state.attributes; |
1647 } | 1647 } |
1648 | 1648 |
1649 } // namespace blink | 1649 } // namespace blink |
OLD | NEW |