146 references to DataViewRowState
netstandard (1)
netstandard.cs (1)
519
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Data.
DataViewRowState
))]
System.Data (1)
src\runtime\src\libraries\shims\System.Data\ref\System.Data.cs (1)
88
[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Data.
DataViewRowState
))]
System.Data.Common (143)
System\Data\Common\DBSchemaRow.cs (4)
48
const
DataViewRowState
rowStates =
DataViewRowState
.Unchanged |
DataViewRowState
.Added |
DataViewRowState
.ModifiedCurrent;
System\Data\DataColumn.cs (1)
1077
_sortIndex = _table!.GetIndex(indexDesc,
DataViewRowState
.CurrentRows, null);
System\Data\DataKey.cs (2)
207
internal Index GetSortIndex() => GetSortIndex(
DataViewRowState
.CurrentRows);
209
internal Index GetSortIndex(
DataViewRowState
recordStates)
System\Data\DataRelation.cs (6)
227
Index index = childKey.GetSortIndex((version == DataRowVersion.Original) ?
DataViewRowState
.OriginalRows :
DataViewRowState
.CurrentRows);
242
Index index = parentKey.GetSortIndex((version == DataRowVersion.Original) ?
DataViewRowState
.OriginalRows :
DataViewRowState
.CurrentRows);
262
Index index = parentKey.GetSortIndex((version == DataRowVersion.Original) ?
DataViewRowState
.OriginalRows :
DataViewRowState
.CurrentRows);
System\Data\DataRow.cs (13)
1020
internal DataRowVersion GetDefaultRowVersion(
DataViewRowState
viewState)
1033
Debug.Assert(0 != (
DataViewRowState
.Added & viewState), "not DataViewRowState.Added");
1038
Debug.Assert(_action == DataRowAction.Rollback || 0 != (
DataViewRowState
.Deleted & viewState), "not DataViewRowState.Deleted");
1041
else if (0 != (
DataViewRowState
.ModifiedCurrent & viewState))
1047
Debug.Assert(0 != (
DataViewRowState
.ModifiedOriginal & viewState), "not DataViewRowState.ModifiedOriginal");
1052
internal
DataViewRowState
GetRecordState(int record)
1056
return
DataViewRowState
.None;
1061
return
DataViewRowState
.Unchanged;
1066
return (_newRecord != -1) ?
DataViewRowState
.ModifiedOriginal :
DataViewRowState
.Deleted;
1071
return (_oldRecord != -1) ?
DataViewRowState
.ModifiedCurrent :
DataViewRowState
.Added;
1074
return
DataViewRowState
.None;
System\Data\DataRowView.cs (1)
165
childView.SetIndex("",
DataViewRowState
.CurrentRows, null); // finish construction via RelatedView.SetIndex
System\Data\DataTable.cs (41)
1257
view.SetIndex2("",
DataViewRowState
.CurrentRows, null, true);
2971
DataRow[] rows = Select(filter, "",
DataViewRowState
.CurrentRows);
3177
GetIndex(indexDesc,
DataViewRowState
.CurrentRows, null);
3179
internal Index GetIndex(string sort,
DataViewRowState
recordStates, IFilter? rowFilter) =>
3182
internal Index GetIndex(IndexField[] indexDesc,
DataViewRowState
recordStates, IFilter? rowFilter)
3350
RecordStateChanged(row._oldRecord,
DataViewRowState
.None,
DataViewRowState
.Unchanged);
3354
RecordStateChanged(row._oldRecord,
DataViewRowState
.None, row.GetRecordState(row._oldRecord),
3355
row._newRecord,
DataViewRowState
.None, row.GetRecordState(row._newRecord));
3810
internal void RecordStateChanged(int record,
DataViewRowState
oldState,
DataViewRowState
newState)
3832
internal void RecordStateChanged(int record1,
DataViewRowState
oldState1,
DataViewRowState
newState1,
3833
int record2,
DataViewRowState
oldState2,
DataViewRowState
newState2)
3876
DataViewRowState
states = row.GetRecordState(recordNo);
3880
if (row.HasVersion(version) && ((states & _indexes[indexCount].RecordStates) !=
DataViewRowState
.None))
3910
DataViewRowState
states = row.GetRecordState(recordNo);
3916
if ((states & _indexes[indexCount].RecordStates) !=
DataViewRowState
.None)
4007
DataViewRowState
oldRecordStatePre = row.GetRecordState(oldRecord);
4008
DataViewRowState
newRecordStatePre = row.GetRecordState(newRecord);
4018
RecordStateChanged(oldRecord, oldRecordStatePre,
DataViewRowState
.None, newRecord, newRecordStatePre,
DataViewRowState
.None);
4221
return new Select(this, "", "",
DataViewRowState
.CurrentRows).SelectRows();
4232
return new Select(this, filterExpression, "",
DataViewRowState
.CurrentRows).SelectRows();
4243
return new Select(this, filterExpression, sort,
DataViewRowState
.CurrentRows).SelectRows();
4251
public DataRow[] Select(string? filterExpression, string? sort,
DataViewRowState
recordStates)
4404
DataViewRowState
currentRecordStatePre = row.GetRecordState(currentRecord);
4405
DataViewRowState
secondRecordStatePre = row.GetRecordState(secondRecord);
4411
DataViewRowState
currentRecordStatePost = row.GetRecordState(currentRecord);
4412
DataViewRowState
secondRecordStatePost = row.GetRecordState(secondRecord);
4514
DataViewRowState
originalRecordStatePre = row.GetRecordState(originalRecord);
4515
DataViewRowState
proposedRecordStatePre = row.GetRecordState(proposedRecord);
4523
DataViewRowState
originalRecordStatePost = row.GetRecordState(originalRecord);
4524
DataViewRowState
proposedRecordStatePost = row.GetRecordState(proposedRecord);
4621
_loadIndex = _primaryKey.Key.GetSortIndex(
DataViewRowState
.OriginalRows);
4757
_loadIndexwithCurrentDeleted = _primaryKey.Key.GetSortIndex(
DataViewRowState
.CurrentRows |
DataViewRowState
.Deleted);
4768
_loadIndexwithOriginalAdded = _primaryKey.Key.GetSortIndex(
DataViewRowState
.OriginalRows |
DataViewRowState
.Added);
4799
index = _primaryKey.Key.GetSortIndex(
DataViewRowState
.OriginalRows);
System\Data\DataView.cs (32)
43
private
DataViewRowState
_recordStates =
DataViewRowState
.CurrentRows;
61
private
DataViewRowState
_delayedRecordStates = (
DataViewRowState
)(-1);
113
SetIndex2("",
DataViewRowState
.CurrentRows, null, true);
122
SetIndex2("",
DataViewRowState
.CurrentRows, null, true);
130
public DataView(DataTable table, string? RowFilter, string? Sort,
DataViewRowState
RowState)
146
if ((((int)RowState) & ((int)~(
DataViewRowState
.CurrentRows |
DataViewRowState
.OriginalRows))) != 0)
150
else if ((((int)RowState) & ((int)
DataViewRowState
.ModifiedOriginal)) != 0 &&
151
(((int)RowState) & ((int)
DataViewRowState
.ModifiedCurrent)) != 0)
163
internal DataView(DataTable table, System.Predicate<DataRow>? predicate, System.Comparison<DataRow>? comparison,
DataViewRowState
RowState)
179
if ((((int)RowState) & ((int)~(
DataViewRowState
.CurrentRows |
DataViewRowState
.OriginalRows))) != 0)
183
else if ((((int)RowState) & ((int)
DataViewRowState
.ModifiedOriginal)) != 0 &&
184
(((int)RowState) & ((int)
DataViewRowState
.ModifiedCurrent)) != 0)
377
[DefaultValue(
DataViewRowState
.CurrentRows)]
378
public
DataViewRowState
RowStateFilter
390
if ((((int)value) & ((int)~(
DataViewRowState
.CurrentRows |
DataViewRowState
.OriginalRows))) != 0)
394
else if ((((int)value) & ((int)
DataViewRowState
.ModifiedOriginal)) != 0 &&
395
(((int)value) & ((int)
DataViewRowState
.ModifiedCurrent)) != 0)
504
SetIndex2("",
DataViewRowState
.CurrentRows, null, false);
596
if (_delayedRecordStates != (
DataViewRowState
)(-1))
599
_delayedRecordStates = (
DataViewRowState
)(-1);
1510
SetIndex("",
DataViewRowState
.CurrentRows, null);
1523
internal virtual void SetIndex(string newSort,
DataViewRowState
newRowStates, IFilter? newRowFilter)
1528
internal void SetIndex2(string newSort,
DataViewRowState
newRowStates, IFilter? newRowFilter, bool fireEvent)
1535
Debug.Assert((0 == (
DataViewRowState
.ModifiedCurrent & newRowStates)) ||
1536
(0 == (
DataViewRowState
.ModifiedOriginal & newRowStates)),
1588
newIndex = new Index(_table, SortComparison, ((
DataViewRowState
)_recordStates), GetFilter());
1596
newIndex = _table.GetIndex(Sort, ((
DataViewRowState
)_recordStates), GetFilter());
System\Data\DataViewManager.cs (1)
135
_dataViewSettingsCollection[table]!.RowStateFilter = Enum.Parse<
DataViewRowState
>(r.Value);
System\Data\DataViewSetting.cs (3)
16
private
DataViewRowState
_rowStateFilter =
DataViewRowState
.CurrentRows;
71
public
DataViewRowState
RowStateFilter
System\Data\ForeignKeyConstraint.cs (4)
232
Index childIndex = _childKey.GetSortIndex(row.RowState == DataRowState.Deleted ?
DataViewRowState
.Deleted :
DataViewRowState
.CurrentRows);
362
Index childIndex = _childKey.GetSortIndex(row.RowState == DataRowState.Deleted ?
DataViewRowState
.OriginalRows :
DataViewRowState
.CurrentRows);
System\Data\LinqDataView.cs (3)
64
DataViewRowState
.CurrentRows)
218
internal override void SetIndex(string newSort,
DataViewRowState
newRowStates, IFilter? newRowFilter)
221
if ((base.SortComparison != null || base.RowPredicate != null) && newRowStates !=
DataViewRowState
.CurrentRows)
System\Data\Merger.cs (4)
206
ndxSearch = dst._primaryKey.Key.GetSortIndex(
DataViewRowState
.OriginalRows |
DataViewRowState
.Added);
280
ndxSearch = new Index(dst, dst._primaryKey!.Key.GetIndexDesc(),
DataViewRowState
.OriginalRows |
DataViewRowState
.Added, null);
System\Data\RelatedView.cs (1)
87
internal override void SetIndex(string newSort,
DataViewRowState
newRowStates, IFilter? newRowFilter)
System\Data\Select.cs (2)
17
private readonly
DataViewRowState
_recordStates;
40
public Select(DataTable table, string? filterExpression, string? sort,
DataViewRowState
recordStates)
System\Data\Selection.cs (25)
70
private readonly
DataViewRowState
_recordStates;
88
public Index(DataTable table, IndexField[] indexFields,
DataViewRowState
recordStates, IFilter? rowFilter) :
93
public Index(DataTable table, System.Comparison<DataRow> comparison,
DataViewRowState
recordStates, IFilter? rowFilter) :
109
private Index(DataTable table, IndexField[] indexFields, System.Comparison<DataRow>? comparison,
DataViewRowState
recordStates, IFilter? rowFilter)
116
(~(
DataViewRowState
.CurrentRows |
DataViewRowState
.OriginalRows))) != 0)
143
public bool Equal(IndexField[] indexDesc,
DataViewRowState
recordStates, IFilter? rowFilter)
169
public
DataViewRowState
RecordStates => _recordStates;
682
private int GetChangeAction(
DataViewRowState
oldState,
DataViewRowState
newState)
690
private static int GetReplaceAction(
DataViewRowState
oldState)
692
return ((0 != (
DataViewRowState
.CurrentRows & oldState)) ? ReplaceNewRecordForCompare : // Added/ModifiedCurrent/Unchanged
693
((0 != (
DataViewRowState
.OriginalRows & oldState)) ? ReplaceOldRecordForCompare : // Deleted/ModififedOriginal
717
DataViewRowState
states = _recordStates;
733
if ((states &
DataViewRowState
.Unchanged) != 0)
740
if ((states &
DataViewRowState
.Added) != 0)
747
if ((states &
DataViewRowState
.Deleted) != 0)
754
if ((states &
DataViewRowState
.ModifiedCurrent) != 0)
758
else if ((states &
DataViewRowState
.ModifiedOriginal) != 0)
928
public void RecordStateChanged(int record,
DataViewRowState
oldState,
DataViewRowState
newState)
936
public void RecordStateChanged(int oldRecord,
DataViewRowState
oldOldState,
DataViewRowState
oldNewState,
937
int newRecord,
DataViewRowState
newOldState,
DataViewRowState
newNewState)
System.Data.OleDb (1)
OleDbCommandBuilder.cs (1)
229
DataRow[] dataRows = table.Select(null, ODB.ORDINAL_POSITION_ASC,
DataViewRowState
.CurrentRows);