Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(922)

Unified Diff: chrome/browser/media_galleries/fileapi/itunes_xml_utils.h

Issue 16231016: Extract track information from iTunes library xml file. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix win test Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/media_galleries/fileapi/itunes_xml_utils.h
diff --git a/chrome/browser/media_galleries/fileapi/itunes_xml_utils.h b/chrome/browser/media_galleries/fileapi/itunes_xml_utils.h
new file mode 100644
index 0000000000000000000000000000000000000000..00bbb8284afe6c3bef00aa1a826ade34dd1b7bd3
--- /dev/null
+++ b/chrome/browser/media_galleries/fileapi/itunes_xml_utils.h
@@ -0,0 +1,28 @@
+// Copyright (c) 2013 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_ITUNES_XML_UTILS_H_
+#define CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_ITUNES_XML_UTILS_H_
+
+#include <string>
+
+class XmlReader;
+
+namespace itunes {
+
+// Like XmlReader::SkipToElement, but will advance to the next open tag if the
+// cursor is on a close tag.
+bool SkipToNextElement(XmlReader* reader);
+
+// Traverse |reader| looking for a node named |name| at the current depth
+// of |reader|.
+bool SeekToNodeAtCurrentDepth(XmlReader* reader, const std::string& name);
+
+// Search within a "dict" node for |key|. The cursor must be on the starting
+// "dict" node when entering this function.
+bool SeekInDict(XmlReader* reader, const std::string& key);
+
+} // namespace itunes
+
+#endif // CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_ITUNES_XML_UTILS_H_

Powered by Google App Engine
This is Rietveld 408576698