AdoDotNetConnectionProperties 类

定义

表示使用 ADO .NET DbConnectionStringBuilder 对象的 IVsDataConnectionProperties 和 IVsDataConnectionUIProperties 接口的实现。

public ref class AdoDotNetConnectionProperties : Microsoft::VisualStudio::Data::Framework::DataSiteableObject<Microsoft::VisualStudio::Data::Core::IVsDataProvider ^>, Microsoft::VisualStudio::Data::Services::SupportEntities::IVsDataConnectionUIProperties, System::Collections::Generic::ICollection<System::Collections::Generic::KeyValuePair<System::String ^, System::Object ^>>, System::Collections::Generic::IDictionary<System::String ^, System::Object ^>, System::Collections::Generic::IEnumerable<System::Collections::Generic::KeyValuePair<System::String ^, System::Object ^>>, System::ComponentModel::ICustomTypeDescriptor, System::ComponentModel::INotifyPropertyChanged
public class AdoDotNetConnectionProperties : Microsoft.VisualStudio.Data.Framework.DataSiteableObject<Microsoft.VisualStudio.Data.Core.IVsDataProvider>, Microsoft.VisualStudio.Data.Services.SupportEntities.IVsDataConnectionUIProperties, System.Collections.Generic.ICollection<System.Collections.Generic.KeyValuePair<string,object>>, System.Collections.Generic.IDictionary<string,object>, System.Collections.Generic.IEnumerable<System.Collections.Generic.KeyValuePair<string,object>>, System.ComponentModel.ICustomTypeDescriptor, System.ComponentModel.INotifyPropertyChanged
type AdoDotNetConnectionProperties = class
    inherit DataSiteableObject<IVsDataProvider>
    interface IVsDataConnectionProperties
    interface IDictionary<string, obj>
    interface ICollection<KeyValuePair<string, obj>>
    interface seq<KeyValuePair<string, obj>>
    interface IEnumerable
    interface IVsDataConnectionUIProperties
    interface ICustomTypeDescriptor
    interface INotifyPropertyChanged
Public Class AdoDotNetConnectionProperties
Inherits DataSiteableObject(Of IVsDataProvider)
Implements ICollection(Of KeyValuePair(Of String, Object)), ICustomTypeDescriptor, IDictionary(Of String, Object), IEnumerable(Of KeyValuePair(Of String, Object)), INotifyPropertyChanged, IVsDataConnectionUIProperties
继承
AdoDotNetConnectionProperties
实现

构造函数

AdoDotNetConnectionProperties()

初始化 AdoDotNetConnectionProperties 类的新实例。

属性

ConnectionStringBuilder

获取当前连接属性实例的基础 ADO.NET 连接字符串生成器对象。

Count

获取连接属性的数目。

IsComplete

获取一个值,该值指示是否已为连接字符串设置足够的连接属性。

IsExtensible

获取一个值,该值指示 DDEX 提供程序连接属性是否可扩展。

Item[String]

获取或设置 DDEX 提供程序上指定属性的值。 如果设置了 属性, PropertyChanged 则引发 事件。

Keys

获取属于数据连接字符串的所有属性。

Site

获取或设置对象站点。

(继承自 DataSiteableObject<T>)
Values

获取连接字符串的值。

方法

Add(String, Object)

将新属性添加到当前连接属性集合。 引发 PropertyChanged 事件。

Add(String, Type, Object)

将新属性添加到当前连接属性集合。

Contains(KeyValuePair<String,Object>)

测试指定的属性名称和值对是否是当前连接属性集的成员。

ContainsKey(String)

测试指定的属性名称是否是当前连接属性集的成员。

CopyTo(KeyValuePair<String,Object>[], Int32)

从指定的数组索引开始,将连接属性集复制到数组。

GetSynonyms(String)

检索指定数据连接属性的同义词的数组列表。

IsSensitive(String)

返回一个布尔值,该值指示指定的属性是否包含敏感信息。

OnPropertyChanged(PropertyChangedEventArgs)

PropertyChanged数据连接字符串中的属性更改时引发 事件。

OnSiteChanged(EventArgs)

如果网站已更改,则引发事件。

Parse(String)

将连接字符串的组件反汇编为当前AdoDotNetConnectionProperties类实例中设置的连接属性集。 引发 PropertyChanged 事件。

Remove(String)

从当前连接属性集合中删除属性。

Reset()

将连接属性重置为其初始值并引发 PropertyChanged 事件。

Reset(String)

从连接字符串中删除给定属性并引发 PropertyChanged 事件。

ToDisplayString()

检索适用于屏幕显示的当前数据连接属性集的字符串表示形式。

ToSafeString()

返回当前数据连接属性集的字符串表示形式,不包括应序列化的敏感属性。

ToString()

返回当前数据连接属性集的字符串表示形式。

TryGetValue(String, Object)

通过在.NET Framework 连接字符串生成器基类上调用此方法来检索与提供的键对应的值, (DbConnectionStringBuilder) 。

事件

PropertyChanged

在连接属性发生更改时发生。

SiteChanged

Site 属性更改时发生。

(继承自 DataSiteableObject<T>)

显式接口实现

ICollection<KeyValuePair<String,Object>>.Add(KeyValuePair<String,Object>)

表示使用 ADO .NET DbConnectionStringBuilder 对象的 IVsDataConnectionProperties 和 IVsDataConnectionUIProperties 接口的实现。

ICollection<KeyValuePair<String,Object>>.Clear()

表示使用 ADO .NET DbConnectionStringBuilder 对象的 IVsDataConnectionProperties 和 IVsDataConnectionUIProperties 接口的实现。

ICollection<KeyValuePair<String,Object>>.IsReadOnly

表示使用 ADO .NET DbConnectionStringBuilder 对象的 IVsDataConnectionProperties 和 IVsDataConnectionUIProperties 接口的实现。

ICollection<KeyValuePair<String,Object>>.Remove(KeyValuePair<String,Object>)

表示使用 ADO .NET DbConnectionStringBuilder 对象的 IVsDataConnectionProperties 和 IVsDataConnectionUIProperties 接口的实现。

ICustomTypeDescriptor.GetAttributes()

检索指定对象的自定义特性的集合。

ICustomTypeDescriptor.GetClassName()

检索指定对象的类名。

ICustomTypeDescriptor.GetComponentName()

检索指定对象的名称。

ICustomTypeDescriptor.GetConverter()

检索指定对象的类型转换器。

ICustomTypeDescriptor.GetDefaultEvent()

检索指定对象的默认事件。

ICustomTypeDescriptor.GetDefaultProperty()

检索指定对象的默认属性。

ICustomTypeDescriptor.GetEditor(Type)

检索此 对象的指定类型的编辑器。

ICustomTypeDescriptor.GetEvents()

有关此成员的说明,请参见 GetEvents()

ICustomTypeDescriptor.GetEvents(Attribute[])

有关此成员的说明,请参见 GetEvents()

ICustomTypeDescriptor.GetProperties()

有关此成员的说明,请参见 GetProperties()

ICustomTypeDescriptor.GetProperties(Attribute[])

有关此成员的说明,请参见 GetProperties()

ICustomTypeDescriptor.GetPropertyOwner(PropertyDescriptor)

有关此成员的说明,请参见 GetPropertyOwner(PropertyDescriptor)

IEnumerable.GetEnumerator()

检索枚举器,该枚举器枚举所有已知连接属性及其值(如果有)。

IEnumerable<KeyValuePair<String,Object>>.GetEnumerator()

表示使用 ADO .NET DbConnectionStringBuilder 对象的 IVsDataConnectionProperties 和 IVsDataConnectionUIProperties 接口的实现。

扩展方法

AddRange<TKey,TValue>(IDictionary<TKey,TValue>, IDictionary<TKey,TValue>, Boolean)

将一个字典内容添加到另一个字典

GetOrDefault<TK,TV>(IDictionary<TK,TV>, TK)

按给定键获取值。

EmptyIfNull<T>(IEnumerable<T>)

如果枚举不为 null,则返回此枚举。 如果为 null,则返回空枚举。

适用于