Added Memory Tracking Code
This commit is contained in:
@@ -77,7 +77,7 @@ namespace VEPROMS.CSLA.Library
|
||||
}
|
||||
}
|
||||
}
|
||||
private void BuildRefreshList()
|
||||
private void ClearRefreshList()
|
||||
{
|
||||
_RefreshContents = new List<Content>();
|
||||
_RefreshContentDetails = new List<ContentDetail>();
|
||||
@@ -85,6 +85,10 @@ namespace VEPROMS.CSLA.Library
|
||||
_RefreshContentParts = new List<ContentPart>();
|
||||
_RefreshContentRoUsages = new List<ContentRoUsage>();
|
||||
_RefreshContentTransitions = new List<ContentTransition>();
|
||||
}
|
||||
private void BuildRefreshList()
|
||||
{
|
||||
ClearRefreshList();
|
||||
AddToRefreshList(_RefreshContents, _RefreshContentDetails, _RefreshContentItems, _RefreshContentParts, _RefreshContentRoUsages, _RefreshContentTransitions);
|
||||
}
|
||||
private void ProcessRefreshList()
|
||||
@@ -114,6 +118,7 @@ namespace VEPROMS.CSLA.Library
|
||||
{
|
||||
TransitionInfo.Refresh(tmp);
|
||||
}
|
||||
ClearRefreshList();
|
||||
}
|
||||
#endregion
|
||||
#region Collection
|
||||
@@ -403,6 +408,12 @@ namespace VEPROMS.CSLA.Library
|
||||
return _MyEntry;
|
||||
}
|
||||
}
|
||||
[TypeConverter(typeof(EntryConverter))]
|
||||
public Entry LocalEntry
|
||||
{
|
||||
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
|
||||
get { return _MyEntry; }
|
||||
}
|
||||
private int _ContentGridCount = 0;
|
||||
/// <summary>
|
||||
/// Count of ContentGrids for this Content
|
||||
@@ -846,14 +857,32 @@ namespace VEPROMS.CSLA.Library
|
||||
AddToCache(this);
|
||||
}
|
||||
private bool _Disposed = false;
|
||||
|
||||
public bool Disposed
|
||||
{
|
||||
get { return _Disposed; }
|
||||
set { _Disposed = value; }
|
||||
}
|
||||
private static int _CountCreated = 0;
|
||||
private static int _CountDisposed = 0;
|
||||
private static int _CountFinalized = 0;
|
||||
private static int IncrementCountCreated
|
||||
{ get { return ++_CountCreated; } }
|
||||
private int _CountWhenCreated = IncrementCountCreated;
|
||||
public static int CountCreated
|
||||
{ get { return _CountCreated; } }
|
||||
public static int CountNotDisposed
|
||||
{ get { return _CountCreated - _CountDisposed; } }
|
||||
public static int CountNotFinalized
|
||||
{ get { return _CountCreated - _CountFinalized; } }
|
||||
~Content()
|
||||
{
|
||||
_CountFinalized++;
|
||||
}
|
||||
public void Dispose()
|
||||
{
|
||||
if (_Disposed) return;
|
||||
_CountDisposed++;
|
||||
_Disposed = true;
|
||||
if (_MyGrid != null)
|
||||
{
|
||||
_MyGrid.Dispose();
|
||||
|
Reference in New Issue
Block a user