📄 memoryusage.cs
字号:
using System;
namespace Perst
{
/// <summary>
/// Information about memory usage for the correspondent class.
/// Instances of this class are created by Storage.getMemoryDump method.
/// Size of internal database structures (object index,* memory allocation bitmap) is associated with
/// <code>Storage</code> class. Size of class descriptors - with <code>System.Type</code> class.
/// </summary>
public class MemoryUsage
{
/// <summary>
/// Class of persistent object or Storage for database internal data
/// </summary>
public Type type;
/// <summary>
/// Number of reachable instance of the particular class in the database.
/// </summary>
public int nInstances;
/// <summary>
/// Total size of all reachable instances
/// </summary>
public long totalSize;
/// <summary>
/// Real allocated size of all instances. Database allocates space for th objects using quantums,
/// for example object wilth size 25 bytes will use 32 bytes in the storage.
/// In item associated with Storage class this field contains size of all allocated
/// space in the database (marked as used in bitmap)
/// </summary>
public long allocatedSize;
/// <summary>
/// MemoryUsage constructor
/// </summary>
public MemoryUsage(Type type)
{
this.type = type;
}
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -