UtilityEx.CheckDataIntegrity Method

Checks the data integrity between the Environment controls.

It compares item-by-item all the master collections of all the Environment instances, searching for objects used in more than one Environment.

Public Shared Function CheckDataIntegrity( _ 
ByRef log As String, _ 
ByRef sharedItems As Dictionary(Of String, Dictionary(Of Object, HashSet(Of String))) _ 
) As Boolean
This language is not supported or no code example is available.
public static bool CheckDataIntegrity( 
out string log
out Dictionary<string, Dictionary<object, HashSet<string>>> sharedItems 
)
This language is not supported or no code example is available.

Parameters

log
string

The log file containing details about shared items.

sharedItems
Dictionary<string, Dictionary<object, HashSet<string>>>

The dictionary containing the shared items.

Listed below are the element types you can find in it

- Layer: items that belong to the Environment.Layers collection.

- Block: items that belong to the Environment.Blocks collection.

- Material: items that belong to the Model.Materials collection.

- TextStyle: items that belong to the Environment.TextStyles collection.

- LineType: items that belong to the Environment.LineTypes collection.

- HatchPattern: items that belong to the Environment.HatchPatterns collection.

- Entity: items that belong to the Environment.Entities collection.

- BlockEntity: items that belong to the Block.Entities collection.

- BlockEntity+Entity: items that belong both to the Block.Entities and to the Environment.Entities collections.

Return Value

bool

True when no instances are shared between different Environment controls, otherwise false.

Remarks
 
You can't share objects (i.e. Entity, Block, Material, etc.) between different Environment controls, but you need to clone them before adding to another Environment control. If you get wrong display results or artifacts, you can use this method to check out shared elements.

.NET Framework

Supported in: 4.8

In this article

Definition