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

Side by Side Diff: chrome/browser/google_apis/time_util.h

Issue 13247007: chrome: Update the include paths of base/string_piece.h to its new location. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_GOOGLE_APIS_TIME_UTIL_H_ 5 #ifndef CHROME_BROWSER_GOOGLE_APIS_TIME_UTIL_H_
6 #define CHROME_BROWSER_GOOGLE_APIS_TIME_UTIL_H_ 6 #define CHROME_BROWSER_GOOGLE_APIS_TIME_UTIL_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/string_piece.h" 10 #include "base/strings/string_piece.h"
11 11
12 namespace base { 12 namespace base {
13 class Time; 13 class Time;
14 } // namespace base 14 } // namespace base
15 15
16 namespace google_apis { 16 namespace google_apis {
17 namespace util { 17 namespace util {
18 18
19 // Parses an RFC 3339 date/time into a base::Time, returning true on success. 19 // Parses an RFC 3339 date/time into a base::Time, returning true on success.
20 // The time string must be in the format "yyyy-mm-ddThh:mm:ss.dddTZ" (TZ is 20 // The time string must be in the format "yyyy-mm-ddThh:mm:ss.dddTZ" (TZ is
21 // either '+hh:mm', '-hh:mm', 'Z' (representing UTC), or an empty string). 21 // either '+hh:mm', '-hh:mm', 'Z' (representing UTC), or an empty string).
22 bool GetTimeFromString(const base::StringPiece& raw_value, base::Time* time); 22 bool GetTimeFromString(const base::StringPiece& raw_value, base::Time* time);
23 23
24 // Formats a base::Time as an RFC 3339 date/time (in UTC). 24 // Formats a base::Time as an RFC 3339 date/time (in UTC).
25 std::string FormatTimeAsString(const base::Time& time); 25 std::string FormatTimeAsString(const base::Time& time);
26 // Formats a base::Time as an RFC 3339 date/time (in localtime). 26 // Formats a base::Time as an RFC 3339 date/time (in localtime).
27 std::string FormatTimeAsStringLocaltime(const base::Time& time); 27 std::string FormatTimeAsStringLocaltime(const base::Time& time);
28 28
29 } // namespace util 29 } // namespace util
30 } // namespace google_apis 30 } // namespace google_apis
31 31
32 #endif // CHROME_BROWSER_GOOGLE_APIS_TIME_UTIL_H_ 32 #endif // CHROME_BROWSER_GOOGLE_APIS_TIME_UTIL_H_
OLDNEW
« no previous file with comments | « chrome/browser/google_apis/test_server/http_request.h ('k') | chrome/browser/password_manager/native_backend_gnome_x.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698