src/Misc/EFTools/XmlCore/Model/ModelManager.cs
/// <summary>
///     Remove the Artifact associated with the Uri from the cache.
///     Virtual for testing.
/// </summary>
Remove the Artifact associated with the Uri from the cache.
Virtual for testing.
Remove the Artifact associated with the Uri from the cache . Virtual for testing .
internal virtual void ClearArtifact(Uri uri)
        {
            lock (this)
            {
                EFArtifact artifact = null;
                if (_artifactsByUri.TryGetValue(uri, out artifact))
                {
                    if (artifact != null)
                    {
                        var artifactSet = GetArtifactSet(uri);
                        Debug.Assert(artifactSet != null);
                        artifact.Dispose();
                        _artifact2ArtifactSets.Remove(artifact);
                        _artifactsByUri.Remove(uri);
                        artifactSet.RemoveArtifact(artifact);
                    }
                }
            }
        }
internal virtual void ClearArtifact ( Uri uri ) { lock ( this ) { EFArtifact artifact = null ; if ( _artifactsByUri . TryGetValue ( uri , out artifact ) ) { if ( artifact != null ) { var artifactSet = GetArtifactSet ( uri ) ; Debug . Assert ( artifactSet != null ) ; artifact . Dispose ( ) ; _artifact2ArtifactSets . Remove ( artifact ) ; _artifactsByUri . Remove ( uri ) ; artifactSet . RemoveArtifact ( artifact ) ; } } } }
Remove the Artifact associated with the Uri from the cache.
Remove the Artifact associated with the Uri from the cache .
// need to dispose the artifact first, as it will try and access it's set // clean up the model manager's collections // remove this artifact from the set
uri
Uri