Method ShallowSizeOfInstance
ShallowSizeOfInstance(Type)
Returns the shallow instance size in bytes an instance of the given class would occupy. This works with all conventional classes and primitive types, but not with arrays (the size then depends on the number of elements and varies from object to object).
Declaration
public static long ShallowSizeOfInstance(Type clazz)
Parameters
Type | Name | Description |
---|---|---|
Type | clazz |
Returns
Type | Description |
---|---|
System.Int64 |