亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? bytelist.cs

?? WJ Communications RFID example code
?? CS
字號:
//==========================================================================================
//
//	WJ.MPR.Util.byteList
//	Copyright (c) 2006, WJ Communications, Inc.
//
//==========================================================================================
using System;
using System.Text;

namespace WJ.MPR.Util
{
	/// <summary>
	///	A strongly-typed collection of byte objects.
	/// It can also return a hexstring and has subList capability.
	/// </summary>
	public class byteList : System.Collections.CollectionBase
	{
		#region constructors
		/// <summary>
		/// Construct a byteList from a subrange of another byteList.
		/// </summary>
		/// <param name="src">The byteList to copy from.</param>
		/// <param name="b">The index to start copying from.</param>
		/// <param name="e">One more than the Index of the last element to copy.</param>
		public byteList (byteList src, int b, int e) { for (int i=b; i < e; i++) Add(src[i]); }

		/// <summary>
		/// Construct a byteList from a subrange of another byteList.
		/// </summary>
		/// <param name="src">The byteList to copy from.</param>
		/// <param name="b">The index to start copying from.</param>
		public byteList (byteList src, int b) : this(src, b, src.Count) {}

		/// <summary>
 		/// Construct a byteList from a byte array.
		/// </summary>
		/// <param name="src">The byte[] to copy from.</param>
		public byteList (params byte[] src) { Add(src); }

		/// <summary>
		/// Construct a byteList from a subrange of a byte array.
		/// </summary>
		/// <param name="src">The byte[] to copy from.</param>
		/// <param name="b">The index to start copying from.</param>
		/// <param name="e">One more than the Index of the last element to copy.</param>
		public byteList (byte[] src, int b, int e) { for (int i=b; i < e; i++) Add(src[i]); }

		/// <summary>
		/// Construct a byteList from a subrange of a byte array.
		/// </summary>
		/// <param name="src">The byte[] to copy from.</param>
		/// <param name="b">The index to start copying from.</param>
		public byteList (byte[] src, int b) : this(src, b, src.Length) {}

		/// <summary>
		/// Construct a byteList filling it from the characters of a string.
		/// Each char of the string is first converted to a byte.
		/// If the string is null, an empty byteList is constructed.
		/// </summary>
		/// <param name="s">The string to copy from.</param>
		public byteList (string s) {if (s!=null) foreach (char b in s.ToCharArray()) {Add((byte)b);}}

		/// <summary>
		/// Construct a byteList with a N copies of the same byte (b).
		/// </summary>
		/// <param name="b">The value to copy.</param>
		/// <param name="N">The number of copies.</param>
		public byteList (byte b, int N) {while (N-- > 0) Add(b);}

		/// <summary>
		/// Construct an empty byteList.
		/// </summary>
		public byteList () {}
		#endregion

		/// <summary>
		/// Returns a new byteList consisting of a subset of the original.
		/// </summary>
		/// <param name="b">The index to start copying from.</param>
		/// <param name="e">One more than the Index of the last element to copy.</param>
		/// <returns>A new byteList seeded with elements of this byteList.</returns>
		public byteList subList (int b, int e) { return new byteList(this, b, e); }

		/// <summary>
		/// Returns a new byteList consisting of a subset of the original.
		/// </summary>
		/// <param name="b">The index to start copying from.</param>
		/// <returns>A new byteList seeded with elements of this byteList.</returns>
		public byteList subList (int b) { return new byteList(this, b); }

		/// <summary>
		/// Gets or sets the element at the specified index.
		/// This property is the indexer for the list.
		/// </summary>
		/// <param name="Index">The zero-based index of the element to get or set.</param>
		/// <value>The element at the specified index.</value>
		/// <exception cref="ArgumentOutOfRangeException">index is not a valid index in the list.</exception>
		public byte this[int Index] { get {return (byte) List[Index];} set {List[Index] = value;} }

		/// <summary>
		/// Add a single value to the list.
		/// </summary>
		/// <param name="val">the value to add.</param>
		/// <returns>Index of newly added element.</returns>
		public int Add(params byte[] val) { foreach(byte b in val) {List.Add(b); } return Count; }

		/// <summary>
		/// Decomposes a ushort to two bytes, and adds them to the list.
		/// MSB first, then LSB.  Returns the Index of the LSB.
		/// </summary>
		/// <param name="us">16-bits to add as two bytes to the list</param>
		/// <returns>The index of the Least Significant Byte</returns>
		public int Add(ushort us) { List.Add((byte)(us >> 8)); return List.Add((byte)(us)); }

		/// <summary>
		/// Decomposes a uint to four bytes, and adds them to the list starting with its MSByte.
		/// Returns the Index of the LSB.
		/// </summary>
		/// <param name="ui">32-bit uint to add as four bytes, MSB first, to the list</param>
		/// <returns>The index of the Least Significant Byte</returns>
		public int Add(uint ui) { List.Add((byte)(ui >> 24)); List.Add((byte)(ui >> 16)); List.Add((byte)(ui >> 8)); return List.Add((byte)(ui)); }

		/// <summary>
		/// Add a subrange from an array to the end of the list.
		/// </summary>
		/// <param name="bArray">The array to copy from.</param>
		/// <param name="b">The index to start copying from.</param>
		/// <param name="e">One more than the Index of the last element to copy.</param>
		/// <returns>The Index of the last element added.</returns>
		public int Add(byte[] bArray, int b, int e) { int i=b; while (b < e) i = List.Add(bArray[b++]); return i; }

		/// <summary>
		/// Add the elements from one list to this list.
		/// </summary>
		/// <param name="BL">The list to copy from.</param>
		/// <returns>The Index of the last element added.</returns>
		public int Add(byteList BL) { int i=Count; if (BL != null) return Add(BL.ToArray()); else return i; }

		/// <summary>
		/// Determines the index of a specific element in the list.
		/// </summary>
		/// <param name="val">The element to locate in the list.</param>
		/// <returns>The index of b if found in the list; otherwise, -1.</returns>
		public int IndexOf(byte val) { return List.IndexOf(val); }
		
		/// <summary>
		/// Inserts an element into the list at the specified Index.
		/// </summary>
		/// <param name="Index">The zero-based index at which the value should be inserted.</param>
		/// <param name="val">The value to insert into the list.</param>
		public void Insert(int Index, byte val) { List.Insert(Index, val); }

		/// <summary>
		/// Removes the first occurrence of a specific value from the list.
		/// </summary>
		/// <param name="val">The value to remove from the list.</param>
		public void Remove(byte val) { List.Remove(val); }

		/// <summary>
		/// Determines whether the list contains a specific value.
		/// </summary>
		/// <param name="val">The value to locate in the list.</param>
		/// <returns>true if val is found in the list; otherwise, false.</returns>
		public bool Contains(byte val) { return List.Contains(val); }

		/// <summary>
		/// Convert the list to an array.
		/// </summary>
		/// <returns>The values of this list, as an array.</returns>
		public byte[] ToArray() { byte[] A = new byte[this.Count]; List.CopyTo(A,0); return A; }

		/// <summary>
		/// Converts a sublist of this list to an array.
		/// </summary>
		/// <param name="b">The index to start copying from.</param>
		/// <param name="e">One more than the Index of the last element to copy.</param>
		/// <returns>The values of the sublist, as an array.</returns>
		public byte[] ToArray (int b, int e) 
		{ 
			if (b > e) b = e;
			byte[] A = new byte[e-b];
			for (int i=b, j=0; i < e; i++, j++) 
				A[j] = this[i];
			return A;
		}

		/// <summary>
		/// Method overloaded, defaults sep = " "
		/// </summary>
		/// <returns>A string of Hexadecimal digits.</returns>
		public string ToHexString() { return ToHexString(" "); }

		/// <summary>
		/// Convert byteList to string of hexadecimal octets, each pair separated by sep.
		/// </summary>
		/// <param name="sep">The string to separate each byte (pair of hex digits).</param>
		/// <returns>The byteList as a string of hex digits pairs.</returns>
		public string ToHexString(string sep)
		{
			StringBuilder SB = new System.Text.StringBuilder();
			foreach	(byte b	in List)
				SB.AppendFormat(null,"{0:X2}{1}", b, sep);
			// Remove the trailing sep
			return SB.ToString().TrimEnd(sep.ToCharArray());
		}

		/// <summary>
		/// Converts byteList to a string.  Each byte is converted to a char.
		/// </summary>
		/// <returns>A string.</returns>
		public override string ToString()
		{
			StringBuilder aString = new	StringBuilder(this.Count);
			foreach(byte b in this)
				aString.Append((char)b);
			return aString.ToString();
		}
	}
}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美日韩国产综合视频在线观看| 极品少妇xxxx精品少妇偷拍| 91片黄在线观看| 国产精品国产三级国产aⅴ原创| 国产99久久久精品| 亚洲视频每日更新| 欧美三级电影网| 日本成人在线电影网| 精品国产青草久久久久福利| 国产一区在线观看麻豆| 中文字幕中文乱码欧美一区二区| 丰满放荡岳乱妇91ww| 国产欧美一区二区精品秋霞影院| 久久精品国产99| 337p粉嫩大胆色噜噜噜噜亚洲| 精品中文字幕一区二区| 久久综合狠狠综合| 国产成人精品免费一区二区| 中文字幕免费不卡在线| 国产一区在线观看视频| 久久久蜜臀国产一区二区| 国产乱妇无码大片在线观看| 久久久精品国产99久久精品芒果| 久久99精品久久久久久国产越南 | 午夜婷婷国产麻豆精品| 欧美日韩精品一区视频| 日韩高清不卡一区二区| 精品91自产拍在线观看一区| 激情久久久久久久久久久久久久久久| 在线不卡欧美精品一区二区三区| 日韩av一级电影| 久久精品一区四区| 91免费国产在线| 香蕉加勒比综合久久| 日韩精品中文字幕一区二区三区| 日日摸夜夜添夜夜添亚洲女人| 日韩一区二区电影在线| 极品尤物av久久免费看| 中文字幕的久久| 色诱视频网站一区| 午夜视频一区在线观看| 日韩三区在线观看| 国产一区二三区| 成人免费在线播放视频| 91成人看片片| 亚洲国产日韩精品| 日韩欧美激情四射| www.在线成人| 亚洲一区二区三区在线播放| 91精品久久久久久久99蜜桃| 成人小视频在线| 青青国产91久久久久久| 国产精品麻豆久久久| 欧美丰满高潮xxxx喷水动漫| 成人黄页在线观看| 日韩电影免费一区| 日韩美女视频19| 精品美女在线观看| 欧美日韩一区二区三区高清| 国产精品一区免费在线观看| 亚洲国产精品久久久久秋霞影院 | 91国内精品野花午夜精品 | 94-欧美-setu| 国模套图日韩精品一区二区| 一区二区三区美女视频| 久久久久久免费| 91精品国产色综合久久| 91首页免费视频| 国产福利一区在线观看| 日本一不卡视频| 国产精品日日摸夜夜摸av| 91精品国产黑色紧身裤美女| jizz一区二区| 国产精品香蕉一区二区三区| 亚洲欧美日韩国产综合在线| 久久久国产一区二区三区四区小说| 欧美日韩国产小视频| 色呦呦日韩精品| 成人av在线资源| 国产成人在线看| 麻豆91在线看| 亚洲国产日韩在线一区模特| 国产精品高潮呻吟| 久久久亚洲欧洲日产国码αv| 欧美日韩一区三区| 99热国产精品| 国产精品一区二区在线观看不卡| 另类中文字幕网| 偷拍自拍另类欧美| 亚洲线精品一区二区三区| 国产女人18毛片水真多成人如厕 | 精品一区二区综合| 久久er99热精品一区二区| 水野朝阳av一区二区三区| 亚洲激情中文1区| 一区二区三区在线播| 亚洲色图都市小说| 综合av第一页| 亚洲乱码精品一二三四区日韩在线 | 亚洲国产精品人人做人人爽| 一级做a爱片久久| 一二三区精品视频| 亚洲va国产va欧美va观看| 图片区小说区区亚洲影院| 日韩av一区二区在线影视| 琪琪一区二区三区| 久久成人羞羞网站| 国产精品99久久久久| 国产不卡高清在线观看视频| 懂色av一区二区三区蜜臀| 国产成人无遮挡在线视频| 国产成人欧美日韩在线电影| av爱爱亚洲一区| 在线一区二区视频| 欧美三级视频在线观看| 欧美不卡123| 亚洲国产精品黑人久久久| 国产精品成人免费在线| 一区二区三区欧美久久| 视频一区免费在线观看| 狠狠色狠狠色综合日日91app| 国产精品99久久久久久有的能看| 91在线国产福利| 欧美日本在线视频| 91精品国产综合久久香蕉麻豆| 欧美一级免费大片| 日韩一区二区精品| 国产亚洲精品7777| 亚洲精品免费电影| 激情六月婷婷综合| 91小宝寻花一区二区三区| 欧美四级电影网| 69堂国产成人免费视频| 精品国产一区二区三区不卡| 中文字幕一区在线观看视频| 亚洲视频一区在线观看| 亚洲视频狠狠干| 蜜臀av性久久久久蜜臀aⅴ四虎| 久久99久久久欧美国产| 99精品视频中文字幕| 欧美一区二区在线免费观看| 久久久另类综合| 亚洲成人久久影院| 青青草成人在线观看| 99精品国产热久久91蜜凸| 91精品国产高清一区二区三区蜜臀| 欧美激情在线观看视频免费| 一区视频在线播放| 日韩高清中文字幕一区| 床上的激情91.| 日韩欧美中文字幕一区| 亚洲精品久久久蜜桃| 国产剧情一区在线| 制服丝袜国产精品| 亚洲男人的天堂在线aⅴ视频| 蜜臀av性久久久久av蜜臀妖精 | 欧美一区二区三区免费| 成人免费在线播放视频| 久久精品理论片| 欧美午夜免费电影| 国产精品毛片无遮挡高清| 另类成人小视频在线| 在线视频欧美区| 亚洲欧美成aⅴ人在线观看| 国产成人亚洲综合a∨婷婷| 日韩午夜精品电影| 亚洲午夜激情av| 91在线小视频| 国产精品毛片a∨一区二区三区| 奇米一区二区三区av| 欧美亚洲一区二区在线观看| 欧美国产成人精品| 国产精品91一区二区| 日韩免费高清电影| 免费av网站大全久久| 在线播放/欧美激情| 亚洲va欧美va人人爽午夜| 欧洲一区在线电影| 一区二区免费在线| 一本到不卡免费一区二区| 国产精品五月天| 国产成a人亚洲精品| 国产亚洲va综合人人澡精品| 国产制服丝袜一区| 久久九九影视网| 激情偷乱视频一区二区三区| 欧美成人bangbros| 国产精品一二三四区| 国产亚洲成aⅴ人片在线观看| 国产成人在线免费观看| 国产欧美精品国产国产专区| 丁香啪啪综合成人亚洲小说 | 免费日韩伦理电影| 日韩欧美亚洲国产精品字幕久久久 | 首页综合国产亚洲丝袜| 成人激情图片网| 亚洲乱码日产精品bd| 欧美在线观看一区| 日韩精品视频网| 精品日韩av一区二区|