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

Side by Side Diff: net/ftp/ftp_directory_listing_parser_ls.h

Issue 465035: Split FTP LIST parsing code into individual files for each listing style. (Closed)
Patch Set: fix Created 11 years 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 unified diff | Download patch
« no previous file with comments | « net/ftp/ftp_directory_listing_parser.cc ('k') | net/ftp/ftp_directory_listing_parser_ls.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. Use of this
2 // source code is governed by a BSD-style license that can be found in the
3 // LICENSE file.
4
5 #ifndef NET_FTP_FTP_DIRECTORY_LISTING_PARSER_LS_H_
6 #define NET_FTP_FTP_DIRECTORY_LISTING_PARSER_LS_H_
7
8 #include <queue>
9
10 #include "net/ftp/ftp_directory_listing_parser.h"
11
12 namespace net {
13
14 // Parser for "ls -l"-style directory listing.
15 class FtpDirectoryListingParserLs : public FtpDirectoryListingParser {
16 public:
17 FtpDirectoryListingParserLs();
18
19 // FtpDirectoryListingParser methods:
20 virtual FtpServerType GetServerType() const { return SERVER_LS; }
21 virtual bool ConsumeLine(const string16& line);
22 virtual bool OnEndOfInput();
23 virtual bool EntryAvailable() const;
24 virtual FtpDirectoryListingEntry PopEntry();
25
26 private:
27 bool received_nonempty_line_;
28
29 std::queue<FtpDirectoryListingEntry> entries_;
30
31 DISALLOW_COPY_AND_ASSIGN(FtpDirectoryListingParserLs);
32 };
33
34 } // namespace net
35
36 #endif // NET_FTP_FTP_DIRECTORY_LISTING_PARSER_LS_H_
OLDNEW
« no previous file with comments | « net/ftp/ftp_directory_listing_parser.cc ('k') | net/ftp/ftp_directory_listing_parser_ls.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698