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

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

?? readonlypropertiesdictionary.cs

?? 詳細講述了數據庫編程
?? CS
字號:
#region Copyright & License
//
// Copyright 2001-2005 The Apache Software Foundation
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
//
#endregion

using System;
using System.Collections;
#if !NETCF
using System.Runtime.Serialization;
using System.Xml;
#endif

namespace log4net.Util
{
	/// <summary>
	/// String keyed object map that is read only.
	/// </summary>
	/// <remarks>
	/// <para>
	/// This collection is readonly and cannot be modified.
	/// </para>
	/// <para>
	/// While this collection is serializable only member 
	/// objects that are serializable will
	/// be serialized along with this collection.
	/// </para>
	/// </remarks>
	/// <author>Nicko Cadell</author>
	/// <author>Gert Driesen</author>
#if NETCF
	public class ReadOnlyPropertiesDictionary : IDictionary
#else
	[Serializable] public class ReadOnlyPropertiesDictionary : ISerializable, IDictionary
#endif
	{
		#region Private Instance Fields

		/// <summary>
		/// The Hashtable used to store the properties data
		/// </summary>
		private Hashtable m_hashtable = new Hashtable();

		#endregion Private Instance Fields

		#region Public Instance Constructors

		/// <summary>
		/// Constructor
		/// </summary>
		/// <remarks>
		/// <para>
		/// Initializes a new instance of the <see cref="ReadOnlyPropertiesDictionary" /> class.
		/// </para>
		/// </remarks>
		public ReadOnlyPropertiesDictionary()
		{
		}

		/// <summary>
		/// Copy Constructor
		/// </summary>
		/// <param name="propertiesDictionary">properties to copy</param>
		/// <remarks>
		/// <para>
		/// Initializes a new instance of the <see cref="ReadOnlyPropertiesDictionary" /> class.
		/// </para>
		/// </remarks>
		public ReadOnlyPropertiesDictionary(ReadOnlyPropertiesDictionary propertiesDictionary)
		{
			foreach(DictionaryEntry entry in propertiesDictionary)
			{
				InnerHashtable.Add(entry.Key, entry.Value);
			}
		}

		#endregion Public Instance Constructors

		#region Private Instance Constructors

#if !NETCF
		/// <summary>
		/// Deserialization constructor
		/// </summary>
		/// <param name="info">The <see cref="SerializationInfo" /> that holds the serialized object data.</param>
		/// <param name="context">The <see cref="StreamingContext" /> that contains contextual information about the source or destination.</param>
		/// <remarks>
		/// <para>
		/// Initializes a new instance of the <see cref="ReadOnlyPropertiesDictionary" /> class 
		/// with serialized data.
		/// </para>
		/// </remarks>
		protected ReadOnlyPropertiesDictionary(SerializationInfo info, StreamingContext context)
		{
			foreach(SerializationEntry entry in info)
			{
				// The keys are stored as Xml encoded names
				InnerHashtable[XmlConvert.DecodeName(entry.Name)] = entry.Value;
			}
		}
#endif

		#endregion Protected Instance Constructors

		#region Public Instance Properties

		/// <summary>
		/// Gets the key names.
		/// </summary>
		/// <returns>An array of all the keys.</returns>
		/// <remarks>
		/// <para>
		/// Gets the key names.
		/// </para>
		/// </remarks>
		public string[] GetKeys()
		{
			string[] keys = new String[InnerHashtable.Count];
			InnerHashtable.Keys.CopyTo(keys, 0);
			return keys;
		}

		/// <summary>
		/// Gets or sets the value of the  property with the specified key.
		/// </summary>
		/// <value>
		/// The value of the property with the specified key.
		/// </value>
		/// <param name="key">The key of the property to get or set.</param>
		/// <remarks>
		/// <para>
		/// The property value will only be serialized if it is serializable.
		/// If it cannot be serialized it will be silently ignored if
		/// a serialization operation is performed.
		/// </para>
		/// </remarks>
		public virtual object this[string key]
		{
			get { return InnerHashtable[key]; }
			set { throw new NotSupportedException("This is a Read Only Dictionary and can not be modified"); }
		}

		#endregion Public Instance Properties

		#region Public Instance Methods

		/// <summary>
		/// Test if the dictionary contains a specified key
		/// </summary>
		/// <param name="key">the key to look for</param>
		/// <returns>true if the dictionary contains the specified key</returns>
		/// <remarks>
		/// <para>
		/// Test if the dictionary contains a specified key
		/// </para>
		/// </remarks>
		public bool Contains(string key)
		{
			return InnerHashtable.Contains(key);
		}

		#endregion

		/// <summary>
		/// The hashtable used to store the properties
		/// </summary>
		/// <value>
		/// The internal collection used to store the properties
		/// </value>
		/// <remarks>
		/// <para>
		/// The hashtable used to store the properties
		/// </para>
		/// </remarks>
		protected Hashtable InnerHashtable
		{
			get { return m_hashtable; }
		}

		#region Implementation of ISerializable

#if !NETCF
		/// <summary>
		/// Serializes this object into the <see cref="SerializationInfo" /> provided.
		/// </summary>
		/// <param name="info">The <see cref="SerializationInfo" /> to populate with data.</param>
		/// <param name="context">The destination for this serialization.</param>
		/// <remarks>
		/// <para>
		/// Serializes this object into the <see cref="SerializationInfo" /> provided.
		/// </para>
		/// </remarks>
		[System.Security.Permissions.SecurityPermissionAttribute(System.Security.Permissions.SecurityAction.Demand, SerializationFormatter=true)]
		public virtual void GetObjectData(SerializationInfo info, StreamingContext context)
		{
			foreach(DictionaryEntry entry in InnerHashtable)
			{
				string entryKey = entry.Key as string;
				object entryValue = entry.Value;

				// If value is serializable then we add it to the list
				if (entryKey != null && entryValue != null && entryValue.GetType().IsSerializable)
				{
					// Store the keys as an Xml encoded local name as it may contain colons (':') 
					// which are NOT escaped by the Xml Serialization framework.
					// This must be a bug in the serialization framework as we cannot be expected
					// to know the implementation details of all the possible transport layers.
					info.AddValue(XmlConvert.EncodeLocalName(entryKey), entryValue);
				}
			}
		}
#endif

		#endregion Implementation of ISerializable

		#region Implementation of IDictionary

		/// <summary>
		/// See <see cref="IDictionary.GetEnumerator"/>
		/// </summary>
		IDictionaryEnumerator IDictionary.GetEnumerator()
		{
			return InnerHashtable.GetEnumerator();
		}

		/// <summary>
		/// See <see cref="IDictionary.Remove"/>
		/// </summary>
		/// <param name="key"></param>
		void IDictionary.Remove(object key)
		{
			throw new NotSupportedException("This is a Read Only Dictionary and can not be modified");
		}

		/// <summary>
		/// See <see cref="IDictionary.Contains"/>
		/// </summary>
		/// <param name="key"></param>
		/// <returns></returns>
		bool IDictionary.Contains(object key)
		{
			return InnerHashtable.Contains(key);
		}

		/// <summary>
		/// Remove all properties from the properties collection
		/// </summary>
		public virtual void Clear()
		{
			throw new NotSupportedException("This is a Read Only Dictionary and can not be modified");
		}

		/// <summary>
		/// See <see cref="IDictionary.Add"/>
		/// </summary>
		/// <param name="key"></param>
		/// <param name="value"></param>
		void IDictionary.Add(object key, object value)
		{
			throw new NotSupportedException("This is a Read Only Dictionary and can not be modified");
		}

		/// <summary>
		/// See <see cref="IDictionary.IsReadOnly"/>
		/// </summary>
		bool IDictionary.IsReadOnly
		{
			get { return true; }
		}

		/// <summary>
		/// See <see cref="IDictionary.this[object]"/>
		/// </summary>
		object IDictionary.this[object key]
		{
			get
			{
				if (!(key is string)) throw new ArgumentException("key must be a string");
				return InnerHashtable[key];
			}
			set
			{
				throw new NotSupportedException("This is a Read Only Dictionary and can not be modified");
			}
		}

		/// <summary>
		/// See <see cref="IDictionary.Values"/>
		/// </summary>
		ICollection IDictionary.Values
		{
			get { return InnerHashtable.Values; }
		}

		/// <summary>
		/// See <see cref="IDictionary.Keys"/>
		/// </summary>
		ICollection IDictionary.Keys
		{
			get { return InnerHashtable.Keys; }
		}

		/// <summary>
		/// See <see cref="IDictionary.IsFixedSize"/>
		/// </summary>
		bool IDictionary.IsFixedSize
		{
			get { return InnerHashtable.IsFixedSize; }
		}

		#endregion

		#region Implementation of ICollection

		/// <summary>
		/// See <see cref="ICollection.CopyTo"/>
		/// </summary>
		/// <param name="array"></param>
		/// <param name="index"></param>
		void ICollection.CopyTo(Array array, int index)
		{
			InnerHashtable.CopyTo(array, index);
		}

		/// <summary>
		/// See <see cref="ICollection.IsSynchronized"/>
		/// </summary>
		bool ICollection.IsSynchronized
		{
			get { return InnerHashtable.IsSynchronized; }
		}

		/// <summary>
		/// The number of properties in this collection
		/// </summary>
		public int Count
		{
			get { return InnerHashtable.Count; }
		}

		/// <summary>
		/// See <see cref="ICollection.SyncRoot"/>
		/// </summary>
		object ICollection.SyncRoot
		{
			get { return InnerHashtable.SyncRoot; }
		}

		#endregion

		#region Implementation of IEnumerable

		/// <summary>
		/// See <see cref="IEnumerable.GetEnumerator"/>
		/// </summary>
		IEnumerator IEnumerable.GetEnumerator()
		{
			return ((IEnumerable)InnerHashtable).GetEnumerator();
		}

		#endregion
	}
}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产精品每日更新| 国产欧美1区2区3区| 韩国精品免费视频| 国产精品美女www爽爽爽| 精品视频在线视频| 国产一区二三区| 亚洲欧美视频在线观看视频| 欧美日韩视频专区在线播放| 激情六月婷婷久久| 一区二区三区精品| 久久久亚洲精品石原莉奈| 在线视频欧美精品| 国产 日韩 欧美大片| 日韩专区欧美专区| 国产激情一区二区三区桃花岛亚洲| 国产精品久久久久影院亚瑟| 91精品麻豆日日躁夜夜躁| 北岛玲一区二区三区四区| 蜜桃一区二区三区在线| 一区二区三区欧美视频| 国产婷婷色一区二区三区四区 | 欧美挠脚心视频网站| 国产精品99久久久| 日本女人一区二区三区| 亚洲色图清纯唯美| 欧美极品美女视频| 日韩欧美一区二区视频| 欧美伊人久久久久久午夜久久久久| 国产乱一区二区| 日韩中文字幕区一区有砖一区| 国产精品人妖ts系列视频| 日韩午夜三级在线| 欧美精品亚洲二区| 欧美性色欧美a在线播放| 国产91精品一区二区麻豆亚洲| 日本va欧美va瓶| 亚洲gay无套男同| 亚洲欧美视频在线观看| 国产女主播视频一区二区| 日韩欧美一区二区三区在线| 欧美日韩国产高清一区| 欧美在线观看一区| 91免费国产在线观看| 成人在线综合网站| 国产成人亚洲精品青草天美| 国模套图日韩精品一区二区| 免费欧美高清视频| 美国毛片一区二区三区| 日韩电影免费一区| 青青草原综合久久大伊人精品优势 | 日韩欧美电影一区| 91精品国产综合久久久蜜臀粉嫩 | 久久精品国产一区二区| 午夜天堂影视香蕉久久| 亚洲综合网站在线观看| 亚洲狠狠丁香婷婷综合久久久| 国产精品色哟哟| 国产女同性恋一区二区| 国产视频一区在线观看| 国产日韩精品视频一区| 中文字幕免费不卡在线| 国产精品嫩草久久久久| 国产精品国产精品国产专区不蜜| 亚洲国产精品精华液ab| 日韩美女视频一区二区| 亚洲日本va在线观看| 亚洲激情网站免费观看| www.成人在线| 国产不卡视频在线播放| 99久久99久久精品国产片果冻| 99热99精品| 色香蕉成人二区免费| 欧美色大人视频| 欧美一区二区三区在线观看视频| 日韩三级视频中文字幕| 久久亚洲春色中文字幕久久久| 国产亚洲欧美日韩日本| 国产精品久久久久久亚洲伦| 亚洲人精品午夜| 亚洲成a天堂v人片| 久久黄色级2电影| 国产精品18久久久久久久久 | 国产美女一区二区| 国产69精品久久久久毛片 | 日本一区免费视频| 亚洲乱码国产乱码精品精可以看| 香蕉成人伊视频在线观看| 蜜臀av性久久久久av蜜臀妖精| 激情成人综合网| 9色porny自拍视频一区二区| 欧美在线观看18| 精品三级在线看| 国产精品第五页| 舔着乳尖日韩一区| 国产精品2024| 精品视频在线视频| 久久精品亚洲乱码伦伦中文| 亚洲视频一区在线| 蜜臀av一区二区三区| heyzo一本久久综合| 欧美美女一区二区在线观看| 欧美精品一区二区不卡| 亚洲精品高清在线| 蜜桃在线一区二区三区| av电影在线观看一区| 欧美一区二区在线视频| 中文文精品字幕一区二区| 亚洲一区二区三区四区在线免费观看 | 亚洲18影院在线观看| 国产精品影视在线| 欧美色男人天堂| 国产精品小仙女| 欧美日韩一区二区三区四区五区| 精品久久久久av影院| 亚洲欧美区自拍先锋| 黄色资源网久久资源365| 在线观看一区二区精品视频| 久久综合视频网| 亚洲高清视频的网址| 粉嫩在线一区二区三区视频| 欧美精品aⅴ在线视频| 国产精品久久久久9999吃药| 美女视频免费一区| 欧美视频一区二区| 国产精品久久久久久久久久久免费看| 午夜精品久久久久久不卡8050| 成人99免费视频| 久久久一区二区| 黄色资源网久久资源365| 91麻豆精品国产91久久久久久久久 | 日本欧美一区二区三区| 一本一本大道香蕉久在线精品 | 精品人在线二区三区| 日本韩国一区二区三区视频| 精品国产91久久久久久久妲己| 亚洲综合一二三区| 成人短视频下载| 欧美国产日本视频| 国产乱码精品一区二区三区忘忧草| 欧美日韩的一区二区| 亚洲男帅同性gay1069| 成人爱爱电影网址| 久久久久99精品国产片| 蜜臀久久99精品久久久画质超高清 | 日韩国产精品久久久| 91国产精品成人| 最新国产成人在线观看| 成人激情电影免费在线观看| 久久久美女毛片| 国产做a爰片久久毛片| 欧美videossexotv100| 青青草国产成人av片免费| 欧美性大战久久久| 亚洲综合激情小说| 欧洲生活片亚洲生活在线观看| 中文字幕中文字幕一区二区| 成人av电影在线| 亚洲人成影院在线观看| 91免费看片在线观看| 亚洲欧美激情在线| 色婷婷国产精品综合在线观看| 最近日韩中文字幕| 色妹子一区二区| 亚洲欧美国产三级| 91丨porny丨国产入口| 亚洲免费观看高清在线观看| 91免费观看视频| 一区二区三区波多野结衣在线观看| 91在线一区二区三区| 亚洲激情图片qvod| 欧美日韩三级在线| 麻豆专区一区二区三区四区五区| 欧美一二三四区在线| 国产揄拍国内精品对白| 久久精品视频免费| av午夜精品一区二区三区| 亚洲精品视频观看| 这里是久久伊人| 国产曰批免费观看久久久| 亚洲国产精华液网站w| 色域天天综合网| 午夜激情久久久| 日韩欧美国产午夜精品| 国产一区二区三区不卡在线观看| 欧美国产国产综合| 欧美艳星brazzers| 亚洲免费在线视频| 蜜臀av性久久久久蜜臀aⅴ四虎| 九一九一国产精品| 91精品国产综合久久久久| 精油按摩中文字幕久久| 国产精品乱人伦| 亚洲专区一二三| 欧美日产国产精品| 韩国v欧美v日本v亚洲v| 中文字幕欧美日本乱码一线二线 | 欧美日韩国产成人在线91| 精品亚洲国内自在自线福利| 欧美激情一区二区三区不卡 | 久久精品亚洲乱码伦伦中文|