Class CsContainerExtensions
Extension management class that manages models that implement CsContainer.
Inherited Members
Namespace: CodeFactory.WinVs.Models.CSharp
Assembly: CodeFactory.WinVs.dll
Syntax
public static class CsContainerExtensions
Methods
GetComparisonMembers(CsContainer, MemberComparisonType, List<MapNamespace>)
Loads all members from a target model that implements CsContainer and returns all members and the comparison hash code for each member.
Declaration
public static IReadOnlyList<KeyValuePair<int, CsMember>> GetComparisonMembers(this CsContainer source, MemberComparisonType comparisonType = MemberComparisonType.Base, List<MapNamespace> mappedNamespaces = null)
Parameters
Type | Name | Description |
---|---|---|
CsContainer | source | The target container to load members from. |
MemberComparisonType | comparisonType | The type of hash code to build for comparision. Default comparison type is set to the base comparison. |
List<MapNamespace> | mappedNamespaces | Optional parameter that provides namespaces to be mapped to. |
Returns
Type | Description |
---|---|
IReadOnlyList<KeyValuePair<int, CsMember>> | List of all the hash codes and the members for each hashcode. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException | Thrown if the source container is null. |
GetMissingInterfaceMembers(CsClass, List<MapNamespace>)
Creates a list of the interface members that are not implemented in the CsClass model.
Declaration
public static IReadOnlyList<CsMember> GetMissingInterfaceMembers(this CsClass source, List<MapNamespace> mappedNamespaces = null)
Parameters
Type | Name | Description |
---|---|---|
CsClass | source | The source model to check. |
List<MapNamespace> | mappedNamespaces | Optional parameter that provides namespaces to be mapped to. |
Returns
Type | Description |
---|---|
IReadOnlyList<CsMember> | List of models that are missing or an empty list if there are no missing members. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException | Throws an argument null exception if the model does not exist. |
GetMissingInterfaceMembers(CsStructure, List<MapNamespace>)
Creates a list of the interface members that are not implemented in the CsStructure model.
Declaration
public static IReadOnlyList<CsMember> GetMissingInterfaceMembers(this CsStructure source, List<MapNamespace> mappedNamespaces = null)
Parameters
Type | Name | Description |
---|---|---|
CsStructure | source | The source model to check. |
List<MapNamespace> | mappedNamespaces | Optional parameter that provides namespaces to be mapped to. |
Returns
Type | Description |
---|---|
IReadOnlyList<CsMember> | List of models that are missing or an empty list if there are no missing members. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException | Throws an argument null exception if the model does not exist. |