public CliFullTypeDictionary(IControlledCollection <ICliMetadataTypeDefinitionTableRow> typeDefinitions, __ICliTypeParent parent) { if (typeDefinitions is IArrayReadOnlyCollection <ICliMetadataTypeDefinitionTableRow> ) { var arrayTypeDefinitions = (IArrayReadOnlyCollection <ICliMetadataTypeDefinitionTableRow>)typeDefinitions; if (arrayTypeDefinitions.IsAggregate) { this.typeDefinitions = arrayTypeDefinitions.AggregateArrays.ConcatinateSeries(); } else { this.typeDefinitions = arrayTypeDefinitions.InternalArray; } } else if (typeDefinitions != null) { this.typeDefinitions = typeDefinitions.ToArray(); } else { this.typeDefinitions = new ICliMetadataTypeDefinitionTableRow[0]; } int len = this.typeDefinitions.Length; this.resultTypes = new IType[len]; this.resultKinds = new TypeKind[len]; this.resultKeys = new IGeneralTypeUniqueIdentifier[len]; this.parent = parent; }
/// <summary> /// Creates a new <see cref="CliTypeDictionary{TIdentifier, TType}"/> /// with the <paramref name="parent"/>, <paramref name="master"/> and <paramref name="filterKind"/> /// provided. /// </summary> /// <param name="parent">The <see cref="__ICliTypeParent"/> which contains the types.</param> /// <param name="master">The <see cref="CliFullTypeDictionary"/> /// which contains the full set of types to filter out.</param> /// <param name="filterKind">The <see cref="TypeKind"/> which denotes the /// type of elements filtered by the <see cref="CliTypeDictionary{TIdentifier, TType}"/>.</param> public CliTypeDictionary(__ICliTypeParent parent, CliFullTypeDictionary master, TypeKind filterKind) { this.master = master; /* * * Filter out the parent dictionary's types, * obtain the indices of the items from the parent dictionary, * as well as the identifiers that uniquely define each. * */ var filteredSet = master.ObtainSubset <TIdentifier, TType>(filterKind).SplitSet(); this.filteredIdentifiers = filteredSet.Item2; base.Initialize(filteredSet.Item1); this.parent = parent; this.filterKind = filterKind; }
public CliInterfaceTypeDictionary(__ICliTypeParent parent, CliFullTypeDictionary master) : base(parent, master, TypeKind.Interface) { }
public CliClassTypeDictionary(__ICliTypeParent parent, CliFullTypeDictionary master) : base(parent, master, TypeKind.Class) { }
public CliStructTypeDictionary(__ICliTypeParent parent, CliFullTypeDictionary master) : base(parent, master, TypeKind.Struct) { }
public CliDelegateTypeDictionary(__ICliTypeParent parent, CliFullTypeDictionary master) : base(parent, master, TypeKind.Delegate) { }
public CliEnumTypeDictionary(__ICliTypeParent parent, CliFullTypeDictionary master) : base(parent, master, TypeKind.Enumeration) { }