点击或拖拽改变大小

HslExtensionGetBoolByIndex 方法 (Byte, Int32)

获取Byte数组的第 boolIndex 偏移的bool值,这个偏移值可以为 10,就是第 1 个字节的 第3位
Get the bool value of the boolIndex offset of the Byte array. The offset value can be 10, which is the third bit of the first byte

命名空间:  HslCommunication
程序集:  HslCommunication (在 HslCommunication.dll 中) 版本:11.8.2.0 (11.8.2.0)
语法
public static bool GetBoolByIndex(
	this byte[] bytes,
	int boolIndex
)

参数

bytes
类型:SystemByte
字节数组信息
boolIndex
类型:SystemInt32
指定字节的位偏移

返回值

类型:Boolean
bool值

备注

在 Visual Basic 和 C# 中,这个方法可以当成为类型 的实例方法来调用。在采用实例方法语法调用这个方法时,请省略第一个参数。请参考 扩展方法 (Visual Basic)扩展方法 (C# 编程指南) 获取更多信息。
参见