127 references to ElementType
System.Data.Entity (83)
System\Data\Common\CommandTrees\ExpressionBuilder\Internal\ArgumentValidation.cs (5)
1124return ValidateCreateRef(entitySet, entitySet.ElementType, keyValues, out keyConstructor); 1136if (!TypeSemantics.IsValidPolymorphicCast(entitySet.ElementType, entityType)) 1163return ValidateRefFromKey(entitySet, keyValues, entitySet.ElementType); 1176if (!TypeSemantics.IsValidPolymorphicCast(entitySet.ElementType, entityType)) 1192TypeUsage keyType = CreateResultType(TypeHelpers.CreateKeyRowType(entitySet.ElementType));
System\Data\Common\EntitySql\SemanticAnalyzer.cs (3)
1882RowType entityKeyRowType = TypeHelpers.CreateKeyRowType(entitySet.ElementType); 1913if (!TypeSemantics.IsValidPolymorphicCast(entitySet.ElementType, targetTypeUsage.EdmType)) 1917entitySet.ElementType.FullName,
System\Data\EntityKey.cs (9)
949Debug.Assert(entitySet != null && entitySet.ElementType.IsAssignableFrom(entityType), "Entity types do not match"); 1013throw EntityUtil.IncorrectNumberOfKeyValuePairs(argumentName, entitySet.ElementType.FullName, keyMembers.Count, 1); 1017throw EntityUtil.IncorrectNumberOfKeyValuePairsInvalidOperation(entitySet.ElementType.FullName, keyMembers.Count, 1); 1029throw EntityUtil.MissingKeyValue(argumentName, keyMembers[0].Name, entitySet.ElementType.FullName); 1033throw EntityUtil.MissingKeyValueInvalidOperation(keyMembers[0].Name, entitySet.ElementType.FullName); 1044throw EntityUtil.IncorrectNumberOfKeyValuePairs(argumentName, entitySet.ElementType.FullName, keyMembers.Count, _compositeKeyValues.Length); 1048throw EntityUtil.IncorrectNumberOfKeyValuePairsInvalidOperation(entitySet.ElementType.FullName, keyMembers.Count, _compositeKeyValues.Length); 1072throw EntityUtil.MissingKeyValue(argumentName, keyField.Name, entitySet.ElementType.FullName); 1076throw EntityUtil.MissingKeyValueInvalidOperation(keyField.Name, entitySet.ElementType.FullName);
System\Data\Mapping\BaseMetadataMappingVisitor.cs (1)
77Visit(entitySet.ElementType);
System\Data\Mapping\MetadataMappingHasherVisitor.cs (2)
264foreach (var entityType in MetadataHelper.GetTypeAndSubtypesOf(entitySet.ElementType, this.m_EdmItemCollection, false).Where(type => type != entitySet.ElementType))
System\Data\Mapping\StorageMappingItemCollection.ViewDictionary.cs (3)
300if (dependentSet.ElementType.IsBaseTypeOf(dependentType)) 327foreach (EdmMember keyMember in dependentSet.ElementType.KeyMembers) 337foreach (EdmMember keyMember in principalSet.ElementType.KeyMembers)
System\Data\Mapping\StorageMappingItemLoader.cs (5)
2659EntityType tableType = tableMember.ElementType; 2754tableType = tableMember.ElementType; 3959LoadParameterBindings(nav.Clone(), toEnd.EntitySet.ElementType, true /* restrictToKeyMembers */)) 3977LoadParameterBindings(nav.Clone(), end.EntitySet.ElementType, true /* restrictToKeyMembers */)) 4077constraint.ToProperties.All(p => m_entitySet.ElementType.KeyMembers.Contains(p)))
System\Data\Mapping\Update\Internal\ExtractorMetadata.cs (1)
201EntityType entityType = entityKey.GetEntitySet(m_translator.MetadataWorkspace).ElementType;
System\Data\Mapping\Update\Internal\Propagator.ExtentPlaceholderCreator.cs (2)
142ReadOnlyMetadataCollection<EdmProperty> members = entitySet.ElementType.Properties; 151PropagatorResult result = PropagatorResult.CreateStructuralValue(memberValues, entitySet.ElementType, false);
System\Data\Mapping\Update\Internal\TableChangeProcessor.cs (1)
85EntityType tableType = table.ElementType;
System\Data\Mapping\Update\Internal\UpdateCompiler.cs (3)
201for (int propertyOrdinal = 0; propertyOrdinal < processor.Table.ElementType.Properties.Count; propertyOrdinal++) 203EdmProperty property = processor.Table.ElementType.Properties[propertyOrdinal]; 369foreach (EdmProperty member in processor.Table.ElementType.Properties)
System\Data\Mapping\Update\Internal\UpdateTranslator.cs (1)
311if (entitySet.ElementType.KeyMembers.Contains(dependentProperty))
System\Data\Mapping\ViewGeneration\QueryRewriting\FragmentQueryKB.cs (2)
111if (Helpers.IsSetEqual(toProperties, toEntitySet.ElementType.KeyMembers, EqualityComparer<EdmMember>.Default)) 141if (Helpers.IsSetEqual(toProperties, toEntitySet.ElementType.KeyMembers, EqualityComparer<EdmMember>.Default))
System\Data\Mapping\ViewGeneration\Structures\LeafCellTreeNode.cs (1)
262IEnumerable<EdmMember> keyProperties = storeEntitySet.ElementType.KeyMembers;
System\Data\Mapping\ViewGeneration\Structures\MemberProjectedSlot.cs (1)
149List<ExtentKey> keys = ExtentKey.GetKeysForEntityType(prefix, entitySet.ElementType);
System\Data\Mapping\ViewGeneration\Structures\TypeConstant.cs (1)
185EntityType entityType = refScopeEntitySet.ElementType;
System\Data\Mapping\ViewGeneration\Validation\BasicCellRelation.cs (1)
108List<ExtentKey> keys = ExtentKey.GetKeysForEntityType(prefix, end.EntitySet.ElementType);
System\Data\Mapping\ViewGeneration\Validation\ForeignConstraint.cs (4)
264ExtentKey primaryKey = ExtentKey.GetPrimaryKeyForEntityType(prefix, ChildTable.ElementType); 552foreach (EdmProperty property in entitySet.ElementType.KeyMembers) 588ExtentKey primaryKey = ExtentKey.GetPrimaryKeyForEntityType(prefix, relationEnd.EntitySet.ElementType); 828foreach (EdmProperty keyMember in m_childTable.ElementType.KeyMembers)
System\Data\Mapping\ViewGeneration\ViewgenContext.cs (1)
135var entityTypes = m_cellWrappers.Select(it => it.RightExtent).OfType<EntitySet>().Select(it => it.ElementType);
System\Data\Metadata\Edm\EntitySet.cs (4)
143if (constraint.ToRole.GetEntityType().IsAssignableFrom(this.ElementType) || 144this.ElementType.IsAssignableFrom(constraint.ToRole.GetEntityType())) 149if (constraint.FromRole.GetEntityType().IsAssignableFrom(this.ElementType) || 150this.ElementType.IsAssignableFrom(constraint.FromRole.GetEntityType()))
System\Data\Objects\DataClasses\EntityCollection.cs (1)
200EntityType entitySetType = singleEntitySet.ElementType;
System\Data\Objects\DataClasses\EntityReference.cs (1)
489keyNames = principalEntitySet.ElementType.KeyMemberNames;
System\Data\Objects\DataClasses\RelatedEnd.cs (6)
398if (!targetEntitySet.ElementType.EdmEquals(targetEntityType) && 399!TypeSemantics.IsSubTypeOf(targetEntitySet.ElementType, targetEntityType)) 520AppendKeyParameterRow(sourceBuilder, key.GetEntitySet(ObjectContext.MetadataWorkspace).ElementType.KeyMembers); 540?? key.GetEntitySet(ObjectContext.MetadataWorkspace).ElementType.KeyMembers; 2351associationset.AssociationSetEnds[_navigation.From].EntitySet.ElementType == entitySet.ElementType)
System\Data\Objects\DataClasses\RelationshipManager.cs (2)
1464if (constraint.ToRole.TypeUsage.EdmType == entitySet.ElementType.GetReferenceType()) 1475if (constraint.FromRole.TypeUsage.EdmType == entitySet.ElementType.GetReferenceType())
System\Data\Objects\Internal\ForeignKeyFactory.cs (1)
114string[] keyNames = principalEntitySet.ElementType.KeyMemberNames;
System\Data\Objects\Internal\ObjectQueryExecutionPlan.cs (1)
127if (entitySet.ElementType.IsAssignableFrom(((CollectionType)treeResultType.EdmType).TypeUsage.EdmType))
System\Data\Objects\ObjectContext.cs (7)
1385if (entitySet.ElementType != entityEdmType) 1387throw EntityUtil.InvalidEntityTypeForObjectSet(entityCLRType.FullName, entitySet.ElementType.FullName, entitySetName, exceptionParameterName); 1906if (!entitySet.ElementType.IsAssignableFrom(entityTypeUsage.EdmType)) 1945MetadataWorkspace.ImplicitLoadFromEntityType(entitySet.ElementType, System.Reflection.Assembly.GetCallingAssembly()); 2501MetadataWorkspace.ImplicitLoadFromEntityType(entitySet.ElementType, System.Reflection.Assembly.GetCallingAssembly()); 2512ReadOnlyMetadataCollection<EdmMember> keyMembers = entitySet.ElementType.KeyMembers; 3174if (entitySet != null && !entitySet.ElementType.IsAssignableFrom(modelEdmType))
System\Data\Objects\ObjectStateManager.cs (6)
290StateManagerTypeMetadata typeMetadata = GetOrAddStateManagerTypeMetadata(entitySet.ElementType); 349if ((isAdded) && !entitySet.ElementType.IsAssignableFrom(entityEdmType)) 1480for (int i = 0; i < entitySetForKey.ElementType.KeyMembers.Count; ++i) 1482EdmMember keyField = entitySetForKey.ElementType.KeyMembers[i]; 3722ReadOnlyMetadataCollection<EdmMember> keyMembers = entitySet.ElementType.KeyMembers; 3738throw EntityUtil.NullKeyValue(keyName, entitySet.ElementType.Name);
System\Data\Query\PlanCompiler\ITreeGenerator.cs (1)
2111Node newArg = BuildSoftCast(VisitExprAsScalar(e.Argument), TypeHelpers.CreateKeyRowType(e.EntitySet.ElementType));
System\Data\Query\PlanCompiler\PreProcessor.cs (3)
281(set.ElementType.Equals(entityType.EdmType) || 282TypeSemantics.IsSubTypeOf(entityType.EdmType, set.ElementType) || 283TypeSemantics.IsSubTypeOf(set.ElementType, entityType.EdmType)))
System\Data\Query\PlanCompiler\StructuredTypeInfo.cs (1)
324AddEntityTypeToSetEntry(e.ElementType, e);
System\Data\SqlClient\SqlProviderUtilities.cs (2)
244foreach (EdmProperty column in entitySet.ElementType.Properties) 255AppendJoin(entitySet.ElementType.KeyMembers, k => AppendIdentifier(k.Name), ", ");
System.Data.Entity.Design (19)
System\Data\Entity\Design\Common\MetadataItemSerializer.cs (1)
734_writer.WriteAttributeString(XmlConstants.EntityType, GetFullName(entitySet.ElementType));
System\Data\Entity\Design\Common\OneToOneMappingSerializer.cs (6)
219return names.Count == _storeEntitySet.ElementType.Properties.Count; 232return ((RefType)constraint0.ToRole.TypeUsage.EdmType).ElementType == _storeEntitySet.ElementType && ((RefType)constraint1.ToRole.TypeUsage.EdmType).ElementType == _storeEntitySet.ElementType; 435foreach (EdmProperty storeKeyMember in store.EntitySet.ElementType.KeyMembers) 473writer.WriteAttributeString(StorageMslConstructs.EntityTypeMappingTypeNameAttribute, model.ElementType.FullName); 482foreach (EdmProperty storeProperty in store.ElementType.Properties)
System\Data\Entity\Design\EntityModelSchemaGenerator.cs (1)
751EntityType entity = CreateModelEntityType(session, storeEntitySet.ElementType);
System\Data\Entity\Design\EntityStoreSchemaGenerator.cs (3)
464DbObjectKey key = session.GetKey(entitySet.ElementType); 1601List<KeyValuePair<string, DbExpression>> projectList = new List<KeyValuePair<string, DbExpression>>(entitySet.ElementType.Members.Count); 1602foreach (EdmMember member in entitySet.ElementType.Members)
System\Data\EntityModel\Emitters\EntityContainerEmitter.cs (8)
182if(!AreTypeAndSetAccessCompatible(GetEntityTypeAccessibility(set.ElementType), GetEntitySetPropertyAccessibility(set))) 186set.ElementType.Name, GetAccessibilityCsdlStringFromMemberAttribute(GetEntityTypeAccessibility(set.ElementType)), set.Name, GetAccessibilityCsdlStringFromMemberAttribute(GetEntitySetPropertyAccessibility(set))), 300CodeTypeReference genericParameter = Generator.GetLeastPossibleQualifiedTypeReference(set.ElementType); 338CodeTypeReference genericParameter = Generator.GetLeastPossibleQualifiedTypeReference(set.ElementType); 435codeMethod.Attributes = MemberAttributes.Final | GetEntityTypeAccessibility(set.ElementType); 440parameter.Type = Generator.GetLeastPossibleQualifiedTypeReference(set.ElementType); 441parameter.Name = Utils.FixParameterName(set.ElementType.Name);
System.Data.Services (4)
System\Data\Services\Providers\ObjectContextServiceProvider.cs (4)
881Type elementType = GetClrTypeForCSpaceType(metadataWorkspace, entitySet.ElementType); 1066if (IsAssignableFrom(entitySet.ElementType, type)) 1483foreach (NavigationProperty p in set.ElementType.NavigationProperties) 1793xmlWriter.WriteAttributeString(XmlConstants.EntityType, entitySet.ElementType.FullName);
System.Data.Services.Design (8)
System\Data\EntityModel\Emitters\EntityContainerEmitter.cs (8)
148if (!AreTypeAndSetAccessCompatible(GetEntityTypeAccessibility(set.ElementType), GetEntitySetPropertyAccessibility(set))) 152set.ElementType.Name, GetAccessibilityCsdlStringFromMemberAttribute(GetEntityTypeAccessibility(set.ElementType)), set.Name, GetAccessibilityCsdlStringFromMemberAttribute(GetEntitySetPropertyAccessibility(set))), 461CodeTypeReference genericParameter = Generator.GetLeastPossibleQualifiedTypeReference(set.ElementType); 499CodeTypeReference genericParameter = Generator.GetLeastPossibleQualifiedTypeReference(set.ElementType); 596codeMethod.Attributes = MemberAttributes.Final | GetEntityTypeAccessibility(set.ElementType); 601parameter.Type = Generator.GetLeastPossibleQualifiedTypeReference(set.ElementType); 602parameter.Name = Utils.CamelCase(set.ElementType.Name);
System.Web.DynamicData (2)
DynamicData\ModelProviders\EFDataModelProvider.cs (2)
37IDictionary<EntityType, EntitySet> entitySetLookup = container.BaseEntitySets.OfType<EntitySet>().ToDictionary(e => e.ElementType); 109Type rootClrType = GetClrType(entitySet.ElementType);
System.Web.Entity (8)
System\Data\WebControls\EntityDataSourceUtil.cs (1)
77if ( ((EntityType)(entitySet.ElementType)).Members.Contains(propertyName) )
System\Data\WebControls\EntityDataSourceView.cs (6)
361CheckNonPolymorphicTypeUsage(EntitySet.ElementType, 762EntityType entityType = Context.MetadataWorkspace.GetObjectSpaceType(CSpaceFilteredEntityType ?? EntitySet.ElementType) as EntityType; 1482cSpaceType = (EntityType)Context.MetadataWorkspace.GetType(_owner.EntityTypeFilter, EntitySet.ElementType.NamespaceName, DataSpace.CSpace); 1483if (!EntityDataSourceUtil.IsTypeOrSubtypeOf(EntitySet.ElementType, cSpaceType, Context.MetadataWorkspace.GetItemCollection(DataSpace.CSpace))) 1510cSpaceType = EntitySet.ElementType; 1570_keyMembers = ((EntityType)(entitySet.ElementType)).KeyMembers;
System\Data\WebControls\EntityDataSourceWrapperCollection.cs (1)
70EntityType entityType = restrictedEntityType ?? entitySet.ElementType;
System.Web.Entity.Design (3)
System\Data\WebControls\Design\EntityDataSourceDataSelection.cs (2)
213_entityTypeFilters = _helper.GetEntityTypeFilters(entitySetItem.EntitySet.ElementType, false /*sortResults*/); 586entityType = _selectedEntitySetName.EntitySet.ElementType;
System\Data\WebControls\Design\EntityDataSourceDesignerHelper.cs (1)
1403baseEntitySetType = entitySet.ElementType;