57 references to ToRole
System.Data.Entity (49)
System\Data\Common\CommandTrees\Internal\ViewSimplifier.cs (2)
157
var dependentSetEnd = relSet.AssociationSetEnds[fkConstraint.
ToRole
.Name];
323
DbRelatedEntityRef result = DbExpressionBuilder.CreateRelatedEntityRef(fkConstraint.
ToRole
, fkConstraint.FromRole, principalRef);
System\Data\Common\Utils\MetadataHelper.cs (2)
519
if (thisEnd.Equals((AssociationEndMember)constraint.
ToRole
))
527
otherEndType = (EntityType)((RefType)((AssociationEndMember)constraint.
ToRole
).TypeUsage.EdmType).ElementType;
System\Data\Mapping\BaseMetadataMappingVisitor.cs (1)
177
Visit(referentialConstraint.
ToRole
);
System\Data\Mapping\StorageMappingItemCollection.ViewDictionary.cs (3)
292
EntitySet dependentSet = aSet.AssociationSetEnds[rc.
ToRole
.Name].EntitySet;
298
EntityType dependentType = MetadataHelper.GetEntityTypeForEnd((AssociationEndMember)rc.
ToRole
);
324
if (end.Name == rc.
ToRole
.Name)
System\Data\Mapping\StorageMappingItemLoader.cs (2)
1425
IEnumerable<EdmMember> dependentKeys = MetadataHelper.GetEntityTypeForEnd((AssociationEndMember)constraint.
ToRole
).KeyMembers;
4076
if (fromEnd.CorrespondingAssociationEndMember == constraint.
ToRole
&&
System\Data\Mapping\StorageModificationFunctionMapping.cs (2)
215
if ((assocationSet.AssociationSetEnds[constraint.
ToRole
.Name].EntitySet == entitySet) &&
216
(constraint.
ToRole
.GetEntityType().IsAssignableFrom(entityType)))
System\Data\Mapping\Update\Internal\UpdateCommandOrderer.cs (1)
113
source = associationSet.AssociationSetEnds[constraint.
ToRole
.Name];
System\Data\Mapping\Update\Internal\UpdateTranslator.cs (5)
179
EntityKey dependentKey = (EntityKey)record[constraint.
ToRole
.Name];
193
int dependentOffset = GetKeyMemberOffset(constraint.
ToRole
, dependentPropertyEnum.Current,
231
EntityType dependentType = MetadataHelper.GetEntityTypeForEnd((AssociationEndMember)constraint.
ToRole
);
287
throw EntityUtil.Update(Strings.Update_AmbiguousForeignKey(constraint.
ToRole
.DeclaringType.FullName), null, stateEntry);
314
int dependentOffset = GetKeyMemberOffset(constraint.
ToRole
, dependentProperty,
System\Data\Mapping\ViewGeneration\BasicViewGenerator.cs (2)
447
var pkColumns = pkFkInfo.Item2.
ToRole
.GetEntityType().KeyMembers;
456
yield return pkFkInfo.Item1.AssociationSetEnds.Where(ase => ase.Name == pkFkInfo.Item2.
ToRole
.Name).Single().EntitySet;
System\Data\Mapping\ViewGeneration\QueryRewriting\FragmentQueryKB.cs (4)
106
AssociationEndMember toEndMember = (AssociationEndMember)constraint.
ToRole
;
117
Debug.Assert(constraint.
ToRole
.RelationshipMultiplicity.Equals(RelationshipMultiplicity.Many) == false);
134
AssociationEndMember toEndMember = (AssociationEndMember)constraint.
ToRole
;
145
Debug.Assert(constraint.
ToRole
.RelationshipMultiplicity.Equals(RelationshipMultiplicity.One));
System\Data\Mapping\ViewGeneration\Structures\MemberPath.cs (2)
719
end1.Name == constraint.
ToRole
.Name;
721
end0.Name == constraint.
ToRole
.Name;
System\Data\Mapping\ViewGeneration\Validation\ForeignConstraint.cs (1)
119
EntitySet childExtent = endToExtents[constraint.
ToRole
.Name];
System\Data\Metadata\Converter.cs (1)
521
referentialConstraint.
ToRole
.Documentation = ConvertToDocumentation(constraint.DependentRole.Documentation);
System\Data\Metadata\Edm\EntitySet.cs (2)
143
if (constraint.
ToRole
.GetEntityType().IsAssignableFrom(this.ElementType) ||
144
this.ElementType.IsAssignableFrom(constraint.
ToRole
.GetEntityType()))
System\Data\Metadata\Edm\NavigationProperty.cs (1)
150
RelationshipEndMember dependentEndMember = rc.
ToRole
;
System\Data\Metadata\Edm\ReferentialConstraint.cs (3)
64
return this.FromRole.Name + "_" + this.
ToRole
.Name;
128
return this.FromRole.Name + "_" + this.
ToRole
.Name;
146
RelationshipEndMember toRole =
ToRole
;
System\Data\Objects\DataClasses\EntityReference_TResultType.cs (1)
608
if (constraint.
ToRole
== FromEndProperty)
System\Data\Objects\DataClasses\RelatedEnd.cs (5)
422
if (fkConstraint.
ToRole
.EdmEquals(_toEndProperty))
1490
if (constraint.
ToRole
== this.FromEndProperty)
1494
EntityType entityType = constraint.
ToRole
.GetEntityType();
1527
EntityType entityType = constraint.
ToRole
.GetEntityType();
1808
if (constraint.
ToRole
== FromEndProperty)
System\Data\Objects\DataClasses\RelationshipManager.cs (1)
1464
if (constraint.
ToRole
.TypeUsage.EdmType == entitySet.ElementType.GetReferenceType())
System\Data\Objects\EntityEntry.cs (4)
162
EntityType dependentType = MetadataHelper.GetEntityTypeForEnd((AssociationEndMember)constraint.
ToRole
);
2733
if (constraint.
ToRole
.Name == thisRole)
3755
RelatedEnd principalEnd = RelationshipManager.GetRelatedEndInternal(principal.Item1.ElementType.FullName, principal.Item2.
ToRole
.Name);
3842
string dependentId = constraint.
ToRole
.Identity;
System\Data\Objects\ObjectStateManager.cs (1)
3266
if (constraint.
ToRole
== reference.FromEndProperty)
System\Data\Query\PlanCompiler\ConstraintManager.cs (2)
113
internal md.RelationshipMultiplicity ChildMultiplicity { get { return m_constraint.
ToRole
.RelationshipMultiplicity; } }
133
md.AssociationEndMember toEnd = constraint.
ToRole
as md.AssociationEndMember;
System\Data\SqlClient\SqlProviderUtilities.cs (1)
198
var dependentEnd = associationSet.AssociationSetEnds[constraint.
ToRole
.Name];
System.Data.Entity.Design (6)
System\Data\Entity\Design\Common\MetadataItemSerializer.cs (1)
298
WriteReferentialConstraintRoleElement(XmlConstants.DependentRole, constraint.
ToRole
, constraint.ToProperties);
System\Data\Entity\Design\Common\OneToOneMappingSerializer.cs (3)
232
return ((RefType)constraint0.
ToRole
.TypeUsage.EdmType).ElementType == _storeEntitySet.ElementType && ((RefType)constraint1.
ToRole
.TypeUsage.EdmType).ElementType == _storeEntitySet.ElementType;
415
return store.AssociationSetEnds.GetValue(constraint.
ToRole
.Name, false);
System\Data\Entity\Design\EntityModelSchemaGenerator.cs (2)
963
storeConstraint.
ToRole
.RelationshipMultiplicity == RelationshipMultiplicity.Many &&
1003
AssociationEndMember toRole = session.MappingLookups.StoreAssociationEndMemberToModelAssociationEndMember[(AssociationEndMember)storeConstraint.
ToRole
];
System.Data.Services (1)
System\Data\Services\Providers\ObjectContextServiceProvider.cs (1)
1940
WriteReferentialConstraintChildElement(xmlWriter, XmlConstants.Dependent, referentialConstraint.
ToRole
.Name, referentialConstraint.ToProperties);
System.Web.DynamicData (1)
DynamicData\ModelProviders\EFAssociationProvider.cs (1)
112
ReferentialConstraint constraint = relationshipType.ReferentialConstraints.FirstOrDefault(c => c.
ToRole
== navigationProperty.ToEndMember);