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

Side by Side Diff: Source/platform/FileMetadata.h

Issue 400543004: Rename WebCore namespace to blink in Platform (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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
« no previous file with comments | « Source/platform/FileChooser.cpp ('k') | Source/platform/FileMetadata.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 19 matching lines...) Expand all
30 30
31 #ifndef FileMetadata_h 31 #ifndef FileMetadata_h
32 #define FileMetadata_h 32 #define FileMetadata_h
33 33
34 #include "platform/PlatformExport.h" 34 #include "platform/PlatformExport.h"
35 #include "platform/weborigin/KURL.h" 35 #include "platform/weborigin/KURL.h"
36 #include "wtf/MathExtras.h" 36 #include "wtf/MathExtras.h"
37 #include "wtf/text/WTFString.h" 37 #include "wtf/text/WTFString.h"
38 #include <time.h> 38 #include <time.h>
39 39
40 namespace WebCore { 40 namespace blink {
41 41
42 inline double invalidFileTime() { return std::numeric_limits<double>::quiet_NaN( ); } 42 inline double invalidFileTime() { return std::numeric_limits<double>::quiet_NaN( ); }
43 inline bool isValidFileTime(double time) { return std::isfinite(time); } 43 inline bool isValidFileTime(double time) { return std::isfinite(time); }
44 44
45 struct FileMetadata { 45 struct FileMetadata {
46 // The last modification time of the file, in seconds. 46 // The last modification time of the file, in seconds.
47 // The value 0.0 means that the time is not set. 47 // The value 0.0 means that the time is not set.
48 double modificationTime; 48 double modificationTime;
49 49
50 // The length of the file in bytes. 50 // The length of the file in bytes.
(...skipping 11 matching lines...) Expand all
62 62
63 FileMetadata() : modificationTime(invalidFileTime()), length(-1), type(TypeU nknown) { } 63 FileMetadata() : modificationTime(invalidFileTime()), length(-1), type(TypeU nknown) { }
64 }; 64 };
65 65
66 PLATFORM_EXPORT bool getFileSize(const String&, long long& result); 66 PLATFORM_EXPORT bool getFileSize(const String&, long long& result);
67 PLATFORM_EXPORT bool getFileModificationTime(const String&, time_t& result); 67 PLATFORM_EXPORT bool getFileModificationTime(const String&, time_t& result);
68 PLATFORM_EXPORT bool getFileMetadata(const String&, FileMetadata&); 68 PLATFORM_EXPORT bool getFileMetadata(const String&, FileMetadata&);
69 PLATFORM_EXPORT String directoryName(const String&); 69 PLATFORM_EXPORT String directoryName(const String&);
70 PLATFORM_EXPORT KURL filePathToURL(const String&); 70 PLATFORM_EXPORT KURL filePathToURL(const String&);
71 71
72 } // namespace WebCore 72 } // namespace blink
73 73
74 #endif // FileMetadata_h 74 #endif // FileMetadata_h
OLDNEW
« no previous file with comments | « Source/platform/FileChooser.cpp ('k') | Source/platform/FileMetadata.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698