SqlBytes 类

定义

表示包装或换BufferStream的可变引用类型。

public ref class SqlBytes sealed : System::Data::SqlTypes::INullable, System::Runtime::Serialization::ISerializable, System::Xml::Serialization::IXmlSerializable
[System.Serializable]
public sealed class SqlBytes : System.Data.SqlTypes.INullable, System.Runtime.Serialization.ISerializable, System.Xml.Serialization.IXmlSerializable
public sealed class SqlBytes : System.Data.SqlTypes.INullable, System.Runtime.Serialization.ISerializable, System.Xml.Serialization.IXmlSerializable
[<System.Serializable>]
type SqlBytes = class
    interface INullable
    interface IXmlSerializable
    interface ISerializable
type SqlBytes = class
    interface INullable
    interface ISerializable
    interface IXmlSerializable
Public NotInheritable Class SqlBytes
Implements INullable, ISerializable, IXmlSerializable
继承
SqlBytes
属性
实现

构造函数

名称 说明
SqlBytes()

初始化 SqlBytes 类的新实例。

SqlBytes(Byte[])

根据指定的字节数组初始化类的新实例 SqlBytes

SqlBytes(SqlBinary)

根据指定的SqlBinary值初始化类的新实例SqlBytes

SqlBytes(Stream)

根据指定的Stream值初始化类的新实例SqlBytes

属性

名称 说明
Buffer

返回对内部缓冲区的引用。

IsNull

获取一个布尔值,该值指示该值 SqlBytes 是否为 null。

Item[Int64]

获取或设置 SqlBytes 指定索引处的实例。

Length

获取实例中包含的 SqlBytes 值的长度。

MaxLength

获取此 SqlBytes内部缓冲区的值的最大长度。

Null

获取此 SqlBytes实例的 null 实例。

Storage

返回有关此 SqlBytes 实例的存储状态的信息。

Stream

获取或设置此 SqlBytes 数据作为流。

Value

返回由此 SqlBytes保留的值的托管副本。

方法

名称 说明
Equals(Object)

确定指定的对象是否等于当前对象。

(继承自 Object)
GetHashCode()

用作默认哈希函数。

(继承自 Object)
GetType()

获取当前实例的 Type

(继承自 Object)
GetXsdType(XmlSchemaSet)

返回指定 XmlSchemaSetXML 架构定义语言 (XSD)。

MemberwiseClone()

创建当前 Object的浅表副本。

(继承自 Object)
Read(Int64, Byte[], Int32, Int32)

将字节从此 SqlBytes 实例复制到传入缓冲区,并返回复制的字节数。

SetLength(Int64)

设置此 SqlBytes 实例的长度。

SetNull()

将此 SqlBytes 实例设置为 null。

ToSqlBinary()

构造并返回此SqlBytes实例的一个SqlBinary

ToString()

返回一个表示当前对象的字符串。

(继承自 Object)
Write(Int64, Byte[], Int32, Int32)

将传入缓冲区中的字节复制到此 SqlBytes 实例。

运营商

名称 说明
Explicit(SqlBinary to SqlBytes)

SqlBinary 结构转换为 SqlBytes 结构。

Explicit(SqlBytes to SqlBinary)

SqlBytes 结构转换为 SqlBinary 结构。

显式接口实现

名称 说明
ISerializable.GetObjectData(SerializationInfo, StreamingContext)

获取序列化信息,其中包含重新初始化此 SqlBytes 实例所需的所有数据。

IXmlSerializable.GetSchema()

此成员支持 .NET Framework 基础结构,不应直接从代码使用。

IXmlSerializable.ReadXml(XmlReader)

此成员支持 .NET Framework 基础结构,不应直接从代码使用。

IXmlSerializable.WriteXml(XmlWriter)

此成员支持 .NET Framework 基础结构,不应直接从代码使用。

适用于

另请参阅