2 * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
4 * Licensed under the Apache License, Version 2.0 (the License);
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
8 * http://www.apache.org/licenses/LICENSE-2.0
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an AS IS BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
18 using System.Collections.Generic;
21 using System.Threading.Tasks;
23 namespace Tizen.System
26 /// Memory information.
28 public class SystemMemoryInformation
30 internal SystemMemoryInformation(Interop.RuntimeInfo.MemoryInfo info)
39 /// Total memory (KiB)
41 public int Total { get; internal set; }
45 public int Used { get; internal set; }
49 public int Free { get; internal set; }
51 /// Cache memory (KiB)
53 public int Cache { get; internal set; }
57 public int Swap { get; internal set; }
61 /// Memory information per processes
63 public class ProcessMemoryInformation
65 internal ProcessMemoryInformation(Interop.RuntimeInfo.ProcessMemoryInfo info)
67 PrivateClean = info.PrivateClean;
68 PrivateDirty = info.PrivateDirty;
71 SharedClean = info.SharedClean;
72 SharedDirty = info.SharedDirty;
76 /// Virtual memory size (KiB)
78 public int Vsz { get; internal set; }
80 /// Resident set size (KiB)
82 public int Rss { get; internal set; }
84 /// Proportional set size (KiB)
86 public int Pss { get; internal set; }
88 /// Not modified and mapped by other processes (KiB)
90 public int SharedClean { get; internal set; }
92 /// Modified and mapped by other processes (KiB)
94 public int SharedDirty { get; internal set; }
96 /// Not modified and available only to that process (KiB)
98 public int PrivateClean { get; internal set; }
100 /// Modified and available only to that process (KiB)
102 public int PrivateDirty { get; internal set; }