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

Unified Diff: base/process_util.h

Issue 10698149: Add minimal support for process_utils on iOS (Closed) Base URL: http://git.chromium.org/chromium/src.git@all-ios-tweak
Patch Set: Tweak include in gyp; eliminate patch bleed Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « base/base.gypi ('k') | base/process_util_ios.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/process_util.h
diff --git a/base/process_util.h b/base/process_util.h
index ae5c9945f8f35a5212048acec8fb17db84636ee3..eba109bf6bf90015d1251a433c71e09e2d70c60e 100644
--- a/base/process_util.h
+++ b/base/process_util.h
@@ -699,7 +699,7 @@ class BASE_EXPORT ProcessMetrics {
// Creates a ProcessMetrics for the specified process.
// The caller owns the returned object.
-#if !defined(OS_MACOSX)
+#if !defined(OS_MACOSX) || defined(OS_IOS)
static ProcessMetrics* CreateProcessMetrics(ProcessHandle process);
#else
class PortProvider {
@@ -716,7 +716,7 @@ class BASE_EXPORT ProcessMetrics {
// only returns valid metrics if |process| is the current process.
static ProcessMetrics* CreateProcessMetrics(ProcessHandle process,
PortProvider* port_provider);
-#endif // !defined(OS_MACOSX)
+#endif // !defined(OS_MACOSX) || defined(OS_IOS)
// Returns the current space allocated for the pagefile, in bytes (these pages
// may or may not be in memory). On Linux, this returns the total virtual
@@ -764,11 +764,11 @@ class BASE_EXPORT ProcessMetrics {
bool GetIOCounters(IoCounters* io_counters) const;
private:
-#if !defined(OS_MACOSX)
+#if !defined(OS_MACOSX) || defined(OS_IOS)
explicit ProcessMetrics(ProcessHandle process);
#else
ProcessMetrics(ProcessHandle process, PortProvider* port_provider);
-#endif // defined(OS_MACOSX)
+#endif // !defined(OS_MACOSX) || defined(OS_IOS)
ProcessHandle process_;
@@ -779,6 +779,7 @@ class BASE_EXPORT ProcessMetrics {
int64 last_time_;
int64 last_system_time_;
+#if !defined(OS_IOS)
#if defined(OS_MACOSX)
// Queries the port provider if it's set.
mach_port_t TaskForPid(ProcessHandle process) const;
@@ -788,6 +789,7 @@ class BASE_EXPORT ProcessMetrics {
// Jiffie count at the last_time_ we updated.
int last_cpu_;
#endif // defined(OS_POSIX)
+#endif // !defined(OS_IOS)
DISALLOW_COPY_AND_ASSIGN(ProcessMetrics);
};
« no previous file with comments | « base/base.gypi ('k') | base/process_util_ios.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698