SoftBasic.IsTwoBytesEquel 方法 (Byte[],Byte[]) |
判断两个字节的指定部分是否相同
Determines whether the specified portion of a two-byte is the same
命名空间:
HslCommunication.BasicFramework
程序集:
HslCommunication (在 HslCommunication.dll 中) 版本:12.1.2.0 (12.1.2.0)
语法 public static bool IsTwoBytesEquel(
byte[] b1,
byte[] b2
)
Public Shared Function IsTwoBytesEquel (
b1 As Byte(),
b2 As Byte()
) As Boolean
public:
static bool IsTwoBytesEquel(
array<unsigned char>^ b1,
array<unsigned char>^ b2
)
static member IsTwoBytesEquel :
b1 : byte[] *
b2 : byte[] -> bool
参数
- b1
- 类型:System.Byte[]
第一个字节 - b2
- 类型:System.Byte[]
第二个字节
返回值
类型:
Boolean返回是否相等
示例 byte[] b1 = new byte[] { 0x13, 0xA6, 0x15, 0x85, 0x5B, 0x05, 0x12, 0x36, 0xF2, 0x27 };
byte[] b2 = new byte[] { 0x13, 0xA6, 0x15, 0x85, 0x5B, 0x05, 0x12, 0x36, 0xF2, 0x27 };
Console.WriteLine( SoftBasic.IsTwoBytesEquel( b1, b2 ) );
参见