/** 削除。 */ public void Delete() { Tool.Log("SoundPool", "Delete"); //アンロード。 { System.Collections.Generic.Dictionary <string, Item> .KeyCollection t_collection = this.list.Keys; string[] t_keylist = new string[t_collection.Count]; t_collection.CopyTo(t_keylist, 0); for (int ii = 0; ii < t_keylist.Length; ii++) { this.UnLoad(t_keylist[ii], true); } } //サウンドプールインスタンス。解放。 #if (UNITY_ANDROID) try{ if (this.java_soundpool != null) { this.java_soundpool.Call("release"); this.java_soundpool.Dispose(); this.java_soundpool = null; } }catch (System.Exception t_exception) { Tool.DebugReThrow(t_exception); } #endif }
ToArray <TKey, TValue> (System.Collections.Generic.Dictionary <TKey, TValue> .ValueCollection collection) { var result = new TValue[collection.Count]; collection.CopyTo(result, 0); return(result); }
/// <summary> /// 获取此存储器中所有项的值 /// </summary> /// <returns>存储项列表(数组)</returns> public CCacheItem_WuQi <K, T>[] GetAllValues() { CCacheItem_WuQi <K, T>[] tmp = new CCacheItem_WuQi <K, T> [this.obj_cache.Count]; System.Collections.Generic.Dictionary <K, CCacheItem_WuQi <K, T> > .ValueCollection vc = this.obj_cache.Values; vc.CopyTo(tmp, 0); return(tmp); }
/// <summary> /// 获得此存储器中所有项的健值 /// </summary> /// <returns>健值列表(数组)</returns> public K[] GetAllKeys() { K[] tmp = new K[this.obj_cache.Count]; System.Collections.Generic.Dictionary <K, CCacheItem_WuQi <K, T> > .KeyCollection keysc = this.obj_cache.Keys; keysc.CopyTo(tmp, 0); return(tmp); }
public void RequestMessage(object state) { System.Collections.Generic.Dictionary <string, SMSSender> .ValueCollection valueCollection = _smsPool.Values; SMSSender[] smsSenders = new SMSSender[valueCollection.Count]; valueCollection.CopyTo(smsSenders, 0); foreach (SMSSender smsSender in smsSenders) { InvokeEventLog(String.Format("请求数据:{0}", smsSender.Name)); List <SMSSendInfo> list = _smsQueue.Get(smsSender.Name); foreach (SMSSendInfo smsSendInfo in list) { smsSender.AsyncSend(smsSendInfo); InvokeEventLog(String.Format("压入:{0}", smsSendInfo)); } } }
static StackObject *CopyTo_1(ILIntepreter __intp, StackObject *__esp, IList <object> __mStack, CLRMethod __method, bool isNewObj) { ILRuntime.Runtime.Enviorment.AppDomain __domain = __intp.AppDomain; StackObject *ptr_of_this_method; StackObject *__ret = ILIntepreter.Minus(__esp, 3); ptr_of_this_method = ILIntepreter.Minus(__esp, 1); System.Int32 @index = ptr_of_this_method->Value; ptr_of_this_method = ILIntepreter.Minus(__esp, 2); System.String[] @array = (System.String[]) typeof(System.String[]).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack)); __intp.Free(ptr_of_this_method); ptr_of_this_method = ILIntepreter.Minus(__esp, 3); System.Collections.Generic.Dictionary <System.String, ILRuntime.Runtime.Intepreter.ILTypeInstance> .KeyCollection instance_of_this_method = (System.Collections.Generic.Dictionary <System.String, ILRuntime.Runtime.Intepreter.ILTypeInstance> .KeyCollection) typeof(System.Collections.Generic.Dictionary <System.String, ILRuntime.Runtime.Intepreter.ILTypeInstance> .KeyCollection).CheckCLRTypes(StackObject.ToObject(ptr_of_this_method, __domain, __mStack)); __intp.Free(ptr_of_this_method); instance_of_this_method.CopyTo(@array, @index); return(__ret); }