public void ReadValue(ref string[] array) { StringArrayHandlerAction handleract = Pool <StringArrayHandlerAction> .Default.Acquire(); handleract.list = new List <string>(); ReadArray(handleract.action); array = handleract.list.ToArray(); handleract.list = null; Pool <StringArrayHandlerAction> .Default.Release(handleract); }
public void ReadValue(ref List <string> list) { StringArrayHandlerAction handleract = Pool <StringArrayHandlerAction> .Default.Acquire(); if (list == null) { list = new List <string>(); } else { list.Clear(); } handleract.list = list; ReadArray(handleract.action); handleract.list = null; Pool <StringArrayHandlerAction> .Default.Release(handleract); }