15 instantiations of DataRelation
System.Data (15)
fx\src\data\System\Data\DataRelation.cs (1)
710DataRelation clone = new DataRelation(relationName, parentColumns, childColumns, false);
fx\src\data\System\Data\DataRelationCollection.cs (7)
105DataRelation relation = new DataRelation(name, parentColumns, childColumns); 119DataRelation relation = new DataRelation(name, parentColumns, childColumns, createConstraints); 132DataRelation relation = new DataRelation(null, parentColumns, childColumns); 147DataRelation relation = new DataRelation(name, parentColumn, childColumn); 162DataRelation relation = new DataRelation(name, parentColumn, childColumn, createConstraints); 175DataRelation relation = new DataRelation(null, parentColumn, childColumn); 804DataRelation newRelation = new DataRelation(rel.relationName, parents, childs, false);
fx\src\data\System\Data\DataSet.cs (1)
503DataRelation rel = new DataRelation(relationName, parentkeyColumns, childkeyColumns, false);
fx\src\data\System\Data\Merger.cs (1)
505destRelation = new DataRelation(relation.RelationName, parentColumns, childColumns, relation.createConstraints);
fx\src\data\System\Data\ProviderBase\SchemaMapping.cs (1)
1033DataRelation relation = new DataRelation(name, new DataColumn[] { parentChapterColumn }, new DataColumn[] { chapterColumn }, false); // MDAC 71878
fx\src\data\System\Data\XDRSchema.cs (1)
605relation = new DataRelation(table.TableName + "_" + _tableChild.TableName, parentKey, childKey, true);
fx\src\data\System\Data\XMLSchema.cs (3)
438relation = new DataRelation(strName, parentKey, childKey, fCreateConstraints); 1137relation = new DataRelation(relName, pKey, fKey); 1515relation = new DataRelation(table.TableName + "_" + _tableChild.TableName, parentKey, childKey, true);
228 references to DataRelation
System.Data (228)
fx\src\data\System\Data\CodeGen\datacache.cs (11)
233private string ChildPropertyName(DataRelation relation) { 253private string ParentPropertyName(DataRelation relation) { 271private string RelationFieldName(DataRelation relation) { 279private bool ChildRelationFollowable(DataRelation relation) { 447DataRelation relation = index[i].FindParentRelation(); 472DataRelation relation = index[i].FindParentRelation(); 921DataRelation relation = ChildRelations[i]; 940DataRelation relation = ParentRelations[i]; 1027dataSetClass.Members.Add(FieldDecl(typeof(DataRelation), RelationFieldName(dataSet.Relations[i]))); 1317foreach(DataRelation relation in dataSet.Relations) { 1339New(typeof(DataRelation), new CodeExpression[] {Str(relation.RelationName), parentColCreate, childColCreate,Primitive(false)})
fx\src\data\System\Data\ConstraintCollection.cs (2)
352DataRelation rel = Table.ChildRelations[i]; 360DataRelation rel = Table.ParentRelations[i];
fx\src\data\System\Data\DataColumn.cs (4)
1519internal DataRelation FindParentRelation() { 1520DataRelation[] parentRelations = new DataRelation[Table.ParentRelations.Count]; 1524DataRelation relation = parentRelations[i];
fx\src\data\System\Data\DataRelation.cs (10)
88/// Initializes a new instance of the <see cref='System.Data.DataRelation'/> class using the specified name, 98/// Initializes a new instance of the <see cref='System.Data.DataRelation'/> class using the specified name, parent, and child columns, and 116/// Initializes a new instance of the <see cref='System.Data.DataRelation'/> class using the specified name 126/// Initializes a new instance of the <see cref='System.Data.DataRelation'/> class using the specified name, matched arrays of parent 405foreach(DataRelation rel in ChildTable.ParentRelations) { 438DataRelation[] relations = list[i].NestedParentRelations; 439foreach(DataRelation rel in relations) { 528foreach(DataRelation rel in ChildTable.ParentRelations) { 695internal DataRelation Clone(DataSet destination) { 710DataRelation clone = new DataRelation(relationName, parentColumns, childColumns, false);
fx\src\data\System\Data\DataRelationCollection.cs (54)
30private DataRelation inTransition = null; 49public abstract DataRelation this[int index] { 56public abstract DataRelation this[string name] { 64public void Add(DataRelation relation) { 88public virtual void AddRange(DataRelation[] relations) { 90foreach(DataRelation relation in relations) { 100/// Creates a <see cref='System.Data.DataRelation'/> with the 104public virtual DataRelation Add(string name, DataColumn[] parentColumns, DataColumn[] childColumns) { 105DataRelation relation = new DataRelation(name, parentColumns, childColumns); 118public virtual DataRelation Add(string name, DataColumn[] parentColumns, DataColumn[] childColumns, bool createConstraints) { 119DataRelation relation = new DataRelation(name, parentColumns, childColumns, createConstraints); 131public virtual DataRelation Add(DataColumn[] parentColumns, DataColumn[] childColumns) { 132DataRelation relation = new DataRelation(null, parentColumns, childColumns); 146public virtual DataRelation Add(string name, DataColumn parentColumn, DataColumn childColumn) { 147DataRelation relation = new DataRelation(name, parentColumn, childColumn); 161public virtual DataRelation Add(string name, DataColumn parentColumn, DataColumn childColumn, bool createConstraints) { 162DataRelation relation = new DataRelation(name, parentColumn, childColumn, createConstraints); 174public virtual DataRelation Add(DataColumn parentColumn, DataColumn childColumn) { 175DataRelation relation = new DataRelation(null, parentColumn, childColumn); 187protected virtual void AddCore(DataRelation relation) { 270public void CopyTo(DataRelation[] array, int index) { 279array[index + i] = (DataRelation)alist[i]; 285/// Returns the index of a specified <see cref='System.Data.DataRelation'/>. 288public virtual int IndexOf(DataRelation relation) { 291if (relation == (DataRelation) List[i]) { 316DataRelation relation = (DataRelation) List[i]; 390public virtual bool CanRemove(DataRelation relation) { 406public void Remove(DataRelation relation) { 427DataRelation dr = this[index]; 442DataRelation dr = this[name]; 455protected virtual void RemoveCore(DataRelation relation) { 518public override DataRelation this[int index] { 521return (DataRelation)relations[index]; 527public override DataRelation this[string name] { 533return (index < 0) ? null : (DataRelation)List[index]; 555private void AddCache(DataRelation relation) { 562protected override void AddCore(DataRelation relation) { 577public override bool CanRemove(DataRelation relation) { 593private void RemoveCache(DataRelation relation) { 606protected override void RemoveCore(DataRelation relation) { 626private DataRelation[] delayLoadingRelations = null; 641public override void AddRange(DataRelation[] relations) { 648foreach(DataRelation relation in relations) { 667public override DataRelation this[int index] { 670return (DataRelation)relations[index]; 676public override DataRelation this[string name] { 682return (index < 0) ? null : (DataRelation)List[index]; 686protected override void AddCore(DataRelation relation) { 704if (childKey.ColumnsEqual(((DataRelation)relations[i]).ChildKey)) { 705if (relation.ParentKey.ColumnsEqual(((DataRelation)relations[i]).ParentKey)) 744protected override void RemoveCore(DataRelation relation) { 778DataRelation rel; 804DataRelation newRelation = new DataRelation(rel.relationName, parents, childs, false);
fx\src\data\System\Data\DataRelationPropertyDescriptor.cs (3)
18DataRelation relation; 20internal DataRelation Relation { 26internal DataRelationPropertyDescriptor(DataRelation dataRelation) : base(dataRelation.RelationName, null) {
fx\src\data\System\Data\DataRow.cs (24)
206internal void CheckForLoops(DataRelation rel){ 227DataRelation[] nestedParentRelations = _table.NestedParentRelations; 228foreach(DataRelation rel in nestedParentRelations) { 749/// specified <see cref='System.Data.DataRelation'/> 752public DataRow[] GetChildRows(DataRelation relation) { 757/// <para>Gets the child rows of this <see cref='System.Data.DataRow'/> using the specified <see cref='System.Data.DataRelation'/> and the specified <see cref='System.Data.DataRowVersion'/></para> 759public DataRow[] GetChildRows(DataRelation relation, DataRowVersion version) { 770return DataRelation.GetChildRows(relation.ParentKey, relation.ChildKey, this, version); 790/// <para>Gets the parent row of this <see cref='System.Data.DataRow'/> using the specified <see cref='System.Data.DataRelation'/> .</para> 792public DataRow GetParentRow(DataRelation relation) { 798/// using the specified <see cref='System.Data.DataRelation'/> and <see cref='System.Data.DataRowVersion'/>.</para> 800public DataRow GetParentRow(DataRelation relation, DataRowVersion version) { 813return DataRelation.GetParentRow(relation.ParentKey, relation.ChildKey, this, version); 819DataRelation[] nestedParentRelations = _table.NestedParentRelations; 820foreach(DataRelation rel in nestedParentRelations) { 851/// Gets the parent rows of this <see cref='System.Data.DataRow'/> using the specified <see cref='System.Data.DataRelation'/> . 854public DataRow[] GetParentRows(DataRelation relation) { 860/// Gets the parent rows of this <see cref='System.Data.DataRow'/> using the specified <see cref='System.Data.DataRelation'/> . 863public DataRow[] GetParentRows(DataRelation relation, DataRowVersion version) { 876return DataRelation.GetParentRows(relation.ParentKey, relation.ChildKey, this, version); 1165foreach (DataRelation relation in _table.ParentRelations) { 1193public void SetParentRow(DataRow parentRow, DataRelation relation) { 1227foreach (DataRelation relation in _table.ParentRelations) 1231internal void SetParentRowToDBNull(DataRelation relation) {
fx\src\data\System\Data\DataRowView.cs (6)
169/// with the specified <see cref="System.Data.DataRelation"/>. 171/// <param name="relation">Specified <see cref="System.Data.DataRelation"/>.</param> 173public DataView CreateChildView(DataRelation relation, bool followParent) { 192public DataView CreateChildView(DataRelation relation) { 197/// <summary><see cref="CreateChildView(DataRelation)"/></summary> 198/// <param name="relationName">Specified <see cref="System.Data.DataRelation"/> name.</param>
fx\src\data\System\Data\DataSet.cs (10)
449foreach (DataRelation rel in Relations) { 503DataRelation rel = new DataRelation(relationName, parentkeyColumns, childkeyColumns, false); 1147DataRelation rel = rels[i].Clone(ds); 2286DataRelation[] nestedParentRelations = t.NestedParentRelations; 2287foreach (DataRelation rel in nestedParentRelations) { 2290foreach (DataRelation rel2 in nestedParentRelations) { 2929protected virtual void OnRemoveRelation(DataRelation relation) 2934internal void OnRemoveRelationHack(DataRelation relation) 3033DataRelation relation = null; 3063DataRelation relation = null;
fx\src\data\System\Data\DataTable.cs (33)
135private static readonly DataRelation[] EmptyArrayDataRelation = new DataRelation[0]; 136private DataRelation[] _nestedParentRelations = EmptyArrayDataRelation; 989foreach(DataRelation rel in ParentRelations) { 1465internal DataRelation[] NestedParentRelations { 1491private DataRelation[] FindNestedParentRelations() { 1492List<DataRelation> nestedParents = null; 1493foreach(DataRelation relation in this.ParentRelations) { 1496nestedParents = new List<DataRelation>(); 1511foreach(DataRelation relation in this.ParentRelations) { 1675DataRelation[] nestedRelations = NestedParentRelations; 1680foreach(DataRelation rel in nestedRelations) { 1688foreach(DataRelation rel in nestedRelations) { 1728DataRelation[] nestedRelations = NestedParentRelations; 1731DataRelation rel = nestedRelations[i]; 1805foreach (DataRelation rel in ChildRelations) 1817foreach(DataRelation rel in ChildRelations) { 1833foreach(DataRelation rel in ParentRelations){ 1851foreach (DataRelation rel in ChildRelations) 2198foreach( DataRelation r in sourceTable.ChildRelations ) { 3911DataRelation relation = ParentRelations[j]; 3919DataRelation relation = ChildRelations[j]; 5653DataRelation[] relations = tableList[i].NestedParentRelations; 5654foreach(DataRelation rel in relations) { 5657foreach (DataRelation rel2 in relations) { 5775List<DataRelation> relationList = new List<DataRelation>(); 5834foreach(DataRelation rel in relationList) { 5868foreach( DataRelation r in currentTable.ChildRelations ) { 5875private void CreateRelationList(List<DataTable> tableList, List<DataRelation> relationList) { 5877foreach( DataRelation r in table.ChildRelations) { 6376DataRelation relation = ParentRelations[j]; 6393DataRelation relation = ChildRelations[j];
fx\src\data\System\Data\DataView.cs (4)
1636e.Action == CollectionChangeAction.Add ? new ListChangedEventArgs(ListChangedType.PropertyDescriptorAdded, new DataRelationPropertyDescriptor((System.Data.DataRelation)e.Element)) : 1638e.Action == CollectionChangeAction.Remove ? new ListChangedEventArgs(ListChangedType.PropertyDescriptorDeleted, new DataRelationPropertyDescriptor((System.Data.DataRelation)e.Element)) : 1646e.Action == CollectionChangeAction.Add ? new ListChangedEventArgs(ListChangedType.PropertyDescriptorAdded, new DataRelationPropertyDescriptor((System.Data.DataRelation)e.Element)) : 1648e.Action == CollectionChangeAction.Remove ? new ListChangedEventArgs(ListChangedType.PropertyDescriptorDeleted, new DataRelationPropertyDescriptor((System.Data.DataRelation)e.Element)) :
fx\src\data\System\Data\DataViewManager.cs (2)
376e.Action == CollectionChangeAction.Add ? new ListChangedEventArgs(ListChangedType.PropertyDescriptorAdded, new DataRelationPropertyDescriptor((System.Data.DataRelation)e.Element)) : 378e.Action == CollectionChangeAction.Remove ? new ListChangedEventArgs(ListChangedType.PropertyDescriptorDeleted, new DataRelationPropertyDescriptor((System.Data.DataRelation)e.Element)) :
fx\src\data\System\Data\Filter\AggregateNode.cs (2)
38private DataRelation relation; 131internal static void Bind(DataRelation relation, List<DataColumn> list)
fx\src\data\System\Data\Filter\LookupNode.cs (1)
21private DataRelation relation;
fx\src\data\System\Data\ForeignKeyConstraint.cs (3)
461if (DataRelation.GetChildRows(this.ParentKey, this.ChildKey, row, DataRowVersion.Default).Length > 0) { 512DataRow parentRow = DataRelation.GetParentRow(this.ParentKey, this.ChildKey, childRow, version); 809internal DataRelation FindParentRelation () {
fx\src\data\System\Data\Merger.cs (2)
432private void MergeRelation(DataRelation relation) { 436DataRelation destRelation = null;
fx\src\data\System\Data\ProviderBase\SchemaMapping.cs (1)
1033DataRelation relation = new DataRelation(name, new DataColumn[] { parentChapterColumn }, new DataColumn[] { chapterColumn }, false); // MDAC 71878
fx\src\data\System\Data\RelationshipConverter.cs (5)
49if (destinationType == typeof(InstanceDescriptor) && value is DataRelation) { 50DataRelation rel = (DataRelation) value; 55ctor = typeof(DataRelation).GetConstructor(new Type[] { typeof(string) /*relationName*/, typeof(string) /*parentTableName*/, typeof(string) /*childTableName */, 61ctor = typeof(DataRelation).GetConstructor(new Type[] { typeof(string)/*relationName*/, typeof(string)/*parentTableName*/, typeof(string)/*parentTableNamespace*/,
fx\src\data\System\Data\XDRSchema.cs (1)
585DataRelation relation = null;
fx\src\data\System\Data\XMLDiffLoader.cs (1)
46foreach( DataRelation r in dt.ChildRelations ) {
fx\src\data\System\Data\xmlsaver.cs (23)
91if (type == typeof(DataRelation)) { 109if (!((instance is DataSet) || (instance is DataTable) || (instance is DataColumn) || (instance is DataRelation))) { 416foreach( DataRelation r in dt.ChildRelations ) { 425foreach( DataRelation r in dt.ChildRelations ) { 426if (! _relations.Contains((DataRelation)r)) { 427_relations.Add((DataRelation)r); 654DataRelation [] rels = new DataRelation[0]; 656rels = new DataRelation[ds.Relations.Count]; 663rels = new DataRelation[_relations.Count]; 671DataRelation rel = rels[i]; 971internal XmlElement HandleRelation(DataRelation rel, XmlDocument dc) { 1181DataRelation [] nestedParentRelations = table.NestedParentRelations; 1392foreach (DataRelation rel in col.Table.ParentRelations) { 1413internal static bool AutoGenerated(DataRelation rel) { 1438DataRelation rel = fk.FindParentRelation(); 1488DataRelation [] nestedParentRelations = _table.NestedParentRelations; 1790DataRelation rel = foreign.FindParentRelation(); 1861AddExtendedProperties(rel.extendedProperties, constraint, typeof(DataRelation)); 1999foreach( DataRelation r in dt.ChildRelations ) { 2394foreach( DataRelation r in dt.ChildRelations ) { 2528foreach( DataRelation r in row.Table.ChildRelations ) { 2671foreach( DataRelation dr in GetNestedChildRelations(row) ) {
fx\src\data\System\Data\XMLSchema.cs (6)
301if ((instance is DataRelation) && (propName.StartsWith(Keywords.MSD_REL_PREFIX, StringComparison.Ordinal))) { 304else if ((instance is DataRelation) && (propName.StartsWith(Keywords.MSD_FK_PREFIX, StringComparison.Ordinal))) { 376DataRelation relation; 808DataRelation relation = null; 1135DataRelation relation = null; 1474DataRelation relation = null;
fx\src\data\System\Data\XmlToDatasetMap.cs (3)
289foreach( DataRelation r in t.ChildRelations ) { // Do we have a child tables ? 358foreach( DataRelation r in t.ChildRelations ) { // Add nested tables information 392foreach(DataRelation childRelations in ((DataTable)tableList[nCounter]).ChildRelations) {
fx\src\data\System\NewXml\XmlDataDocument.cs (17)
265foreach ( DataRelation rel in dataSet.Relations ) { 505foreach( DataRelation dr in GetNestedChildRelations(row) ) { 709foreach( DataRelation r in row.Table.ChildRelations ) { 718DataRelation relation = GetNestedParentRelation(row); 724private static DataRelation GetNestedParentRelation( DataRow row ) { 725DataRelation [] relations = row.Table.NestedParentRelations; 1407DataRelation relation = GetNestedParentRelation(row); 1526DataColumn FindAssociatedParentColumn( DataRelation relation, DataColumn childCol ) { 1560DataRelation relation = GetNestedParentRelation(child); 1984DataRelation rel = (DataRelation)(args.Element); 1991foreach ( DataRelation relTemp in (DataRelationCollection)oRelationsCollection ) { 2381DataRelation rel = GetNestedParentRelation( childRow ); 2611DataRelation [] relations = childRow.Table.NestedParentRelations; 2771foreach(DataRelation r in tableList[readPos].ChildRelations) { 2789foreach(DataRelation r in rootTable.ChildRelations) { 2801foreach(DataRelation r in tableList[counter].ChildRelations) {