OLD | NEW |
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 CONTENT_CHILD_DATABASE_UTIL_H_ | 5 #ifndef CONTENT_CHILD_DATABASE_UTIL_H_ |
6 #define CONTENT_CHILD_DATABASE_UTIL_H_ | 6 #define CONTENT_CHILD_DATABASE_UTIL_H_ |
7 | 7 |
| 8 #include <stdint.h> |
| 9 |
8 #include "content/child/blink_platform_impl.h" | 10 #include "content/child/blink_platform_impl.h" |
9 | 11 |
10 namespace IPC { | 12 namespace IPC { |
11 class SyncMessageFilter; | 13 class SyncMessageFilter; |
12 } | 14 } |
13 | 15 |
14 namespace content { | 16 namespace content { |
15 | 17 |
16 // A class of utility functions used by RendererBlinkPlatformImpl to handle | 18 // A class of utility functions used by RendererBlinkPlatformImpl to handle |
17 // database file accesses. | 19 // database file accesses. |
18 class DatabaseUtil { | 20 class DatabaseUtil { |
19 public: | 21 public: |
20 static blink::Platform::FileHandle DatabaseOpenFile( | 22 static blink::Platform::FileHandle DatabaseOpenFile( |
21 const blink::WebString& vfs_file_name, | 23 const blink::WebString& vfs_file_name, |
22 int desired_flags, | 24 int desired_flags, |
23 IPC::SyncMessageFilter* sync_message_filter); | 25 IPC::SyncMessageFilter* sync_message_filter); |
24 static int DatabaseDeleteFile( | 26 static int DatabaseDeleteFile( |
25 const blink::WebString& vfs_file_name, | 27 const blink::WebString& vfs_file_name, |
26 bool sync_dir, | 28 bool sync_dir, |
27 IPC::SyncMessageFilter* sync_message_filter); | 29 IPC::SyncMessageFilter* sync_message_filter); |
28 static long DatabaseGetFileAttributes( | 30 static long DatabaseGetFileAttributes( |
29 const blink::WebString& vfs_file_name, | 31 const blink::WebString& vfs_file_name, |
30 IPC::SyncMessageFilter* sync_message_filter); | 32 IPC::SyncMessageFilter* sync_message_filter); |
31 static long long DatabaseGetFileSize( | 33 static long long DatabaseGetFileSize( |
32 const blink::WebString& vfs_file_name, | 34 const blink::WebString& vfs_file_name, |
33 IPC::SyncMessageFilter* sync_message_filter); | 35 IPC::SyncMessageFilter* sync_message_filter); |
34 static long long DatabaseGetSpaceAvailable( | 36 static long long DatabaseGetSpaceAvailable( |
35 const blink::WebString& origin_identifier, | 37 const blink::WebString& origin_identifier, |
36 IPC::SyncMessageFilter* sync_message_filter); | 38 IPC::SyncMessageFilter* sync_message_filter); |
37 static bool DatabaseSetFileSize( | 39 static bool DatabaseSetFileSize(const blink::WebString& vfs_file_name, |
38 const blink::WebString& vfs_file_name, | 40 int64_t size, |
39 int64 size, | 41 IPC::SyncMessageFilter* sync_message_filter); |
40 IPC::SyncMessageFilter* sync_message_filter); | |
41 }; | 42 }; |
42 | 43 |
43 } // namespace content | 44 } // namespace content |
44 | 45 |
45 #endif // CONTENT_CHILD_DATABASE_UTIL_H_ | 46 #endif // CONTENT_CHILD_DATABASE_UTIL_H_ |
OLD | NEW |