6 writes to DataType
System.Data (4)
fx\src\data\System\Data\DataColumn.cs (2)
253
DataType
= typeof(int);
1493
clone.
DataType
= DataType;
fx\src\data\System\Data\DataTable.cs (1)
431
dc.
DataType
= (Type) info.GetValue(String.Format(formatProvider, "DataTable.DataColumn_{0}.DataType", i), typeof(Type));
fx\src\data\System\Data\XMLSchema.cs (1)
254
col.
DataType
= DataStorage.GetType(value);
System.Web.Entity (2)
System\Data\WebControls\EntityDataSourceViewSchema.cs (2)
108
column.
DataType
= typeArguments[0];
113
column.
DataType
= propertyType;
131 references to DataType
System.Data (116)
fx\src\data\Microsoft\SqlServer\Server\MetadataUtilsSmi.cs (4)
634
SqlDbType dbType = InferSqlDbTypeFromType_Katmai(column.
DataType
);
636
throw SQL.UnsupportedColumnTypeForSqlProvider(column.ColumnName, column.
DataType
.Name);
646
if (column.
DataType
== typeof(SqlDecimal)) {
724
column.
DataType
,
fx\src\data\System\Data\CodeGen\datacache.cs (33)
446
Type DataType = index[i].
DataType
;
521
findBy.Parameters.Add(ParameterDecl(GetTypeName(index[i].
DataType
), RowColumnPropertyName(index[i])));
579
TypeOf(GetTypeName(column.
DataType
)),
776
Type DataType = col.
DataType
;
821
if(col.
DataType
.IsSubclassOf(typeof(System.ValueType))) {
822
errorList.Add(Res.GetString(Res.CodeGen_TypeCantBeNull, col.ColumnName, col.
DataType
.Name));
827
if(col.
DataType
== typeof(string)) {
828
nullValueExpr = Property(TypeExpr(col.
DataType
), "Empty");
833
System.Reflection.ConstructorInfo ctor = col.
DataType
.GetConstructor(new Type[] {typeof(string)});
835
errorList.Add(Res.GetString(Res.CodeGen_NoCtor0, col.ColumnName, col.
DataType
.Name));
840
nullValueFieldInit = New(col.
DataType
, new CodeExpression[] {});
849
col.
DataType
== typeof(char) || col.
DataType
== typeof(string) ||
850
col.
DataType
== typeof(decimal)|| col.
DataType
== typeof(bool) ||
851
col.
DataType
== typeof(Single) || col.
DataType
== typeof(double) ||
852
col.
DataType
== typeof(SByte) || col.
DataType
== typeof(Byte) ||
853
col.
DataType
== typeof(Int16) || col.
DataType
== typeof(UInt16) ||
854
col.
DataType
== typeof(Int32) || col.
DataType
== typeof(UInt32) ||
855
col.
DataType
== typeof(Int64) || col.
DataType
== typeof(UInt64)
861
if(col.
DataType
== typeof(Byte[])) {
863
}else if(col.
DataType
== typeof(DateTime) || col.
DataType
== typeof(TimeSpan)) {
864
nullValueFieldInit = MethodCall(TypeExpr(col.
DataType
), "Parse", Primitive(nullValueObj.ToString()));
867
System.Reflection.ConstructorInfo ctor = col.
DataType
.GetConstructor(new Type[] {typeof(string)});
869
errorList.Add(Res.GetString(Res.CodeGen_NoCtor1, col.ColumnName, col.
DataType
.Name));
874
nullValueFieldInit = New(col.
DataType
, new CodeExpression[] {Primitive(nullValue)});
883
CodeMemberField nullValueField = FieldDecl(col.
DataType
, rowColumnName + "_nullValue"); {
fx\src\data\System\Data\Common\AdapterUtil.cs (1)
992
return DataMapping(Res.GetString(Res.ADP_ColumnSchemaMismatch, srcColumn, srcType.Name, column.ColumnName, column.
DataType
.Name));
fx\src\data\System\Data\Common\DataColumnMapping.cs (1)
118
if ((null == dataType) || (dataType.IsArray == dataColumn.
DataType
.IsArray)) {
fx\src\data\System\Data\DataColumn.cs (13)
249
if (!IsAutoIncrementType(
DataType
)) {
251
throw ExceptionBuilder.AutoIncrementCannotSetIfHasData(
DataType
.Name);
273
return (this.autoInc ?? (this.autoInc = ((this.
DataType
== typeof(System.Numerics.BigInteger))
631
if (
DataType
!= typeof(DateTime) && value != DataSetDateTime.UnspecifiedLocal) { //Check for column being DateTime. If the column is not DateTime make sure the value that is being is only the default[UnspecifiedLocal].
692
if (newDefaultValue != DBNull.Value &&
DataType
!= typeof(Object)) {
695
newDefaultValue = SqlConvert.ChangeTypeForDefaultValue(newDefaultValue,
DataType
, FormatProvider);
698
throw ExceptionBuilder.DefaultValueColumnDataType(ColumnName, newDefaultValue.GetType(),
DataType
, ex);
952
if ((
DataType
!= typeof(string)) && (
DataType
!= typeof(SqlString))) {
1164
throw ExceptionBuilder.SetFailed(value, this,
DataType
, e);
1196
throw ExceptionBuilder.SetFailed(value, this,
DataType
, e);
1493
clone.DataType =
DataType
;
1577
return DataStorage.IsTypeCustomType(
DataType
);
fx\src\data\System\Data\DataColumnPropertyDescriptor.cs (1)
57
return column.
DataType
;
fx\src\data\System\Data\DataRelation.cs (4)
641
if ((parentKey.ColumnsReference[i].
DataType
!= childKey.ColumnsReference[i].
DataType
) ||
642
((parentKey.ColumnsReference[i].
DataType
== typeof(DateTime)) &&
782
if (col.
DataType
!= typeof(int))
fx\src\data\System\Data\DataRow.cs (1)
1100
throw ExceptionBuilder.UDTImplementsIChangeTrackingButnotIRevertible(dc.
DataType
.AssemblyQualifiedName);
fx\src\data\System\Data\DataTable.cs (3)
363
info.AddValue(String.Format(formatProvider, "DataTable.DataColumn_{0}.DataType", i), Columns[i].
DataType
);
3550
if (DataStorage.IsTypeCustomType(dc.
DataType
) && newValue != dc[record]) {
4377
DataColumn foreignKey = new DataColumn(keyName, parentKey.
DataType
, null, MappingType.Hidden);
fx\src\data\System\Data\DataTableReader.cs (3)
454
return (currentDataTable.Columns[ordinal].
DataType
);
682
dr[DataType] = dc.
DataType
;
684
if (dc.
DataType
== typeof(string)) {
fx\src\data\System\Data\ForeignKeyConstraint.cs (3)
560
if (parentKey.ColumnsReference[i].
DataType
!= childKey.ColumnsReference[i].
DataType
||
561
((parentKey.ColumnsReference[i].
DataType
== typeof(DateTime)) && (parentKey.ColumnsReference[i].DateTimeMode != childKey.ColumnsReference[i].DateTimeMode) && ((parentKey.ColumnsReference[i].DateTimeMode & childKey.ColumnsReference[i].DateTimeMode) != DataSetDateTime.Unspecified)))
fx\src\data\System\Data\Merger.cs (3)
317
if (dest.
DataType
!= src.
DataType
||
318
((dest.
DataType
== typeof(DateTime)) && (dest.DateTimeMode != src.DateTimeMode) && ((dest.DateTimeMode & src.DateTimeMode) != DataSetDateTime.Unspecified))) {
fx\src\data\System\Data\OleDb\OleDbMetaDataFactory.cs (3)
88
if ((null == populationMechanism) || (typeof(System.String) != populationMechanism.
DataType
)) {
92
if ((null == collectionName) || (typeof(System.String) != collectionName.
DataType
)) {
98
if ((null == restrictionCollectionName) || (typeof(System.String) != restrictionCollectionName.
DataType
)) {
fx\src\data\System\Data\ProviderBase\DbMetaDataFactory.cs (2)
229
newDestinationColumn = new DataColumn(sourceColumn.ColumnName,sourceColumn.
DataType
);
252
if ((null == collectionNameColumn) || (typeof(System.String) != collectionNameColumn.
DataType
)) {
fx\src\data\System\Data\ProviderBase\SchemaMapping.cs (4)
541
if (typeof(System.Data.SqlTypes.SqlXml) == dataColumn.
DataType
) {
544
else if (typeof(System.Xml.XmlDocument) == dataColumn.
DataType
) {
740
if (typeof(System.Data.SqlTypes.SqlXml) == dataColumn.
DataType
) {
743
else if (typeof(System.Xml.XmlDocument) == dataColumn.
DataType
) {
fx\src\data\System\Data\Select.cs (2)
580
((isLConst && !isRConst && (leftType == StorageType.String) && (rightType == StorageType.Guid) && (null != (namedNode = expr.right as NameNode)) && (namedNode.column.
DataType
== typeof(Guid))) ||
581
(isRConst && !isLConst && (rightType == StorageType.String) && (leftType == StorageType.Guid) && (null != (namedNode = expr.left as NameNode)) && (namedNode.column.
DataType
== typeof(Guid))))
fx\src\data\System\Data\SqlClient\SqlBulkCopy.cs (1)
1080
t = _dataTableSource.Columns[sourceOrdinal].
DataType
;
fx\src\data\System\Data\XmlDataLoader.cs (1)
1107
!( (column.
DataType
== typeof(Object)) || (typeName != null) || (xsiTypeString != null) );
fx\src\data\System\Data\XMLDiffLoader.cs (2)
357
bool isPolymorphism = (column.
DataType
== typeof(Object)|| (row.GetAttribute(Keywords.MSD_INSTANCETYPE, Keywords.MSDNS) != null) ||
402
if (column.
DataType
== typeof(string))
fx\src\data\System\Data\xmlsaver.cs (31)
177
string dt = XmlDataTypeName(col.
DataType
);
178
if(bIsSqlType || (col.
DataType
== typeof(System.Numerics.BigInteger))) {
179
root.SetAttribute(Keywords.MSD_DATATYPE, Keywords.MSDNS, col.
DataType
.FullName);
181
else if ((dt.Length == 0) || bImplementsInullable || ((dt == Keywords.XSD_ANYTYPE) && (col.XmlDataType != Keywords.XSD_ANYTYPE))|| (col.
DataType
== typeof(DateTimeOffset))) {
187
this.SetMSDataAttribute(root, col.
DataType
);
1116
string typeName = XmlDataTypeName(col.
DataType
); // do not update the hashtable, as it will not write msdata:DataType
1118
if (col.
DataType
== typeof(Guid) || col.
DataType
== typeof(Type) ) {
1123
XmlTreeGen.ValidateColumnMapping(col.
DataType
);
1135
if (col.
DataType
!= typeof(String)) {
1136
string dt = XmlDataTypeName(col.
DataType
);
1137
if ((col.IsSqlType && ((dt.Length == 0) || col.ImplementsINullable)) || (typeof(SqlXml) == col.
DataType
) || col.
DataType
== typeof(DateTimeOffset) || col.
DataType
== typeof(System.Numerics.BigInteger)) { // no need to check if it is Sql typee if it already implements INullable,
1138
root.SetAttribute(Keywords.MSD_DATATYPE, Keywords.MSDNS, col.
DataType
.FullName);
1146
this.SetMSDataAttribute(root, col.
DataType
);
1172
if (col.
DataType
== typeof(DateTime) && col.DateTimeMode != DataSetDateTime.UnspecifiedLocal) {
1234
if (col.
DataType
== typeof(bool))
1238
XmlTreeGen.ValidateColumnMapping(col.
DataType
);
1245
XmlTreeGen.ValidateColumnMapping(col.
DataType
);
1247
if (col.
DataType
== typeof(bool)) {
1255
if (col.
DataType
== typeof(bool)) {
1382
if (col.
DataType
!= typeof(int))
1552
string _typeName = XmlDataTypeName(col.
DataType
);
1606
XmlTreeGen.ValidateColumnMapping(colTxt.
DataType
);
2253
if (!startElementSkipped && columnValue.GetType() != col.
DataType
) {
2261
if (columnValue.GetType() != col.
DataType
) { // throw if polymorphism; not supported
2573
XmlTreeGen.ValidateColumnMapping(col.
DataType
);
2586
XmlTreeGen.ValidateColumnMapping(col.
DataType
);
2626
if (!startElementSkipped && valuesType != col.
DataType
) { // for polymorphism.
2633
if (value.GetType() != col.
DataType
) { // throw if polymorphism; not supported
System.Data.DataSetExtensions (1)
System\Data\DataTableExtensions.cs (1)
166
table.Columns.Add(column.ColumnName, column.
DataType
);
System.Web.DataVisualization (7)
Common\DataManager\DataPoint.cs (6)
1382
columnDataType = ((DataRow)enumerator.Current).Table.Columns[field].
DataType
;
1394
columnDataType = ((DataRow)enumerator.Current).Table.Columns[columnIndex].
DataType
;
1411
columnDataType = ((DataRow)enumerator.Current).Table.Columns[0].
DataType
;
1424
columnDataType = ((DataRowView)enumerator.Current).DataView.Table.Columns[field].
DataType
;
1435
columnDataType = ((DataRowView)enumerator.Current).DataView.Table.Columns[columnIndex].
DataType
;
1452
columnDataType = ((DataRowView)enumerator.Current).DataView.Table.Columns[0].
DataType
;
Common\General\Chart.cs (1)
568
if (!usedForYValue || column.
DataType
!= typeof(string))
System.Windows.Forms.DataVisualization (7)
Common\DataManager\DataPoint.cs (6)
1382
columnDataType = ((DataRow)enumerator.Current).Table.Columns[field].
DataType
;
1394
columnDataType = ((DataRow)enumerator.Current).Table.Columns[columnIndex].
DataType
;
1411
columnDataType = ((DataRow)enumerator.Current).Table.Columns[0].
DataType
;
1424
columnDataType = ((DataRowView)enumerator.Current).DataView.Table.Columns[field].
DataType
;
1435
columnDataType = ((DataRowView)enumerator.Current).DataView.Table.Columns[columnIndex].
DataType
;
1452
columnDataType = ((DataRowView)enumerator.Current).DataView.Table.Columns[0].
DataType
;
Common\General\Chart.cs (1)
568
if (!usedForYValue || column.
DataType
!= typeof(string))