本文整理汇总了C#中System.Data.DataSet.ShouldSerializeLocale方法的典型用法代码示例。如果您正苦于以下问题:C# System.Data.DataSet.ShouldSerializeLocale方法的具体用法?C# System.Data.DataSet.ShouldSerializeLocale怎么用?C# System.Data.DataSet.ShouldSerializeLocale使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Data.DataSet
的用法示例。
在下文中一共展示了System.Data.DataSet.ShouldSerializeLocale方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ReadXmlSchema
internal void ReadXmlSchema(XmlReader reader, bool denyResolving)
{
IntPtr ptr;
Bid.ScopeEnter(out ptr, "<ds.DataTable.ReadXmlSchema|INFO> %d#, denyResolving=%d{bool}\n", this.ObjectID, denyResolving);
try
{
System.Data.DataSet set = new System.Data.DataSet();
SerializationFormat remotingFormat = this.RemotingFormat;
set.ReadXmlSchema(reader, denyResolving);
string mainTableName = set.MainTableName;
if (!ADP.IsEmpty(this.tableName) || !ADP.IsEmpty(mainTableName))
{
DataTable currentTable = null;
if (!ADP.IsEmpty(this.tableName))
{
if (!ADP.IsEmpty(this.Namespace))
{
currentTable = set.Tables[this.tableName, this.Namespace];
}
else
{
int num3 = set.Tables.InternalIndexOf(this.tableName);
if (num3 > -1)
{
currentTable = set.Tables[num3];
}
}
}
else
{
string str3 = "";
int index = mainTableName.IndexOf(':');
if (index > -1)
{
str3 = mainTableName.Substring(0, index);
}
string str4 = mainTableName.Substring(index + 1, (mainTableName.Length - index) - 1);
currentTable = set.Tables[str4, str3];
}
if (currentTable == null)
{
string tableName = string.Empty;
if (!ADP.IsEmpty(this.tableName))
{
tableName = (this.Namespace.Length > 0) ? (this.Namespace + ":" + this.tableName) : this.tableName;
}
else
{
tableName = mainTableName;
}
throw ExceptionBuilder.TableNotFound(tableName);
}
currentTable._remotingFormat = remotingFormat;
List<DataTable> tableList = new List<DataTable> {
currentTable
};
this.CreateTableList(currentTable, tableList);
List<DataRelation> relationList = new List<DataRelation>();
this.CreateRelationList(tableList, relationList);
if (relationList.Count == 0)
{
if (this.Columns.Count == 0)
{
DataTable table5 = currentTable;
if (table5 != null)
{
table5.CloneTo(this, null, false);
}
if ((this.DataSet == null) && (this.tableNamespace == null))
{
this.tableNamespace = table5.Namespace;
}
}
}
else
{
if (ADP.IsEmpty(this.TableName))
{
this.TableName = currentTable.TableName;
if (!ADP.IsEmpty(currentTable.Namespace))
{
this.Namespace = currentTable.Namespace;
}
}
if (this.DataSet == null)
{
System.Data.DataSet set2 = new System.Data.DataSet(set.DataSetName);
set2.SetLocaleValue(set.Locale, set.ShouldSerializeLocale());
set2.CaseSensitive = set.CaseSensitive;
set2.Namespace = set.Namespace;
set2.mainTableName = set.mainTableName;
set2.RemotingFormat = set.RemotingFormat;
set2.Tables.Add(this);
}
this.CloneHierarchy(currentTable, this.DataSet, null);
foreach (DataTable table2 in tableList)
{
DataTable table4 = this.DataSet.Tables[table2.tableName, table2.Namespace];
DataTable table6 = set.Tables[table2.tableName, table2.Namespace];
foreach (Constraint constraint3 in table6.Constraints)
//.........这里部分代码省略.........