本文整理汇总了C#中IDatabase.GetHashCode方法的典型用法代码示例。如果您正苦于以下问题:C# IDatabase.GetHashCode方法的具体用法?C# IDatabase.GetHashCode怎么用?C# IDatabase.GetHashCode使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IDatabase
的用法示例。
在下文中一共展示了IDatabase.GetHashCode方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: GetCacheKey
private static string GetCacheKey(IDatabase database, string sql, object parameters) {
return JsonConvert.SerializeObject(new {
database = database.GetHashCode(),
sql,
parameters
});
}
示例2: DisplayDatabaseProperties
//===============================================================================
// Properties
//===============================================================================
public void DisplayDatabaseProperties(IDatabase database, TreeNode tableNode)
{
if (this._currentHashCode == database.GetHashCode()) return;
propGrid.SelectedObject = database;
this._currentHashCode = database.GetHashCode();
}
示例3: DisplayDatabaseProperties
//===============================================================================
// Properties
//===============================================================================
public void DisplayDatabaseProperties(IDatabase database, TreeNode tableNode)
{
if (this._currentHashCode == database.GetHashCode()) return;
DataTable dt = new DataTable("MyData");
dt.Columns.Add("Property", stringType);
dt.Columns.Add("Value", stringType);
dt.Rows.Add(new object[] {"Name", database.Name});
dt.Rows.Add(new object[] {"Alias", database.Alias});
dt.Rows.Add(new object[] {"Description", database.Description});
dt.Rows.Add(new object[] {"SchemaName", database.SchemaName});
dt.Rows.Add(new object[] {"SchemaOwner", database.SchemaOwner});
dt.Rows.Add(new object[] {"DefaultCharSetCatalog", database.DefaultCharSetCatalog});
dt.Rows.Add(new object[] {"DefaultCharSetSchema", database.DefaultCharSetSchema});
dt.Rows.Add(new object[] {"DefaultCharSetName", database.DefaultCharSetName});
this.Grid.DataSource = dt;
this.InitializeGrid();
this.Text = "IDatabase Properties";
this.lnkHELP.Text = "IDatabase Help ...";
this.helpInterface = "IDatabase";
this._currentHashCode = database.GetHashCode();
}