PlayMakerArrayListProxy.AddRange C# (CSharp) Method

AddRange() public method

public AddRange ( ICollection collection, string type ) : int
collection ICollection
type string
return int
    public int AddRange(ICollection collection,string type)
    {
        arrayList.AddRange(collection);
        // TOFIX: what should I do here...? specific event?
        //dispatchEvent(addEvent,value,type);

        return arrayList.Count;
    }

Usage Example

        public override void OnEnter()
        {
            GameObject _go = Fsm.GetOwnerDefaultTarget(target);

            //Get all Proxy Components
            PlayMakerArrayListProxy[] proxies = _go.GetComponents <PlayMakerArrayListProxy>();

            if (reference.Value != "" || reference.Value != null)
            {
                //Check if more than one Proxy Component exists on the target
                if (proxies.Length > 0)
                {
                    foreach (PlayMakerArrayListProxy iProxy in proxies)
                    {
                        if (iProxy.referenceName == reference.Value)
                        {
                            proxy = iProxy;
                        }
                        else
                        {
                            // Debug.LogWarning("No Array List with the Reference " + reference.Value + " in " + _go.name + " found!");
                            // Finish();
                        }
                    }
                }
            }
            else
            {
                proxy = _go.GetComponent("" + "PlayMakerArrayListProxy") as PlayMakerArrayListProxy;
            }

            try
            {
                Dictionary <string, object> data;

                if (proxy == null)
                {
                    LogError("ArrayMaker Proxy is null!");
                }

                if (GDEDataManager.Get(ItemName.Value, out data) && proxy != null)
                {
                    List <string> val;
                    data.TryGetStringList(FieldName.Value, out val);

                    proxy.AddRange(val, string.Empty);
                }
                else
                {
                    //LogError(string.Format(GDMConstants.ErrorLoadingValue, "string array", ItemName.Value, FieldName.Value));
                }
            } catch (System.Exception ex)
            {
                UnityEngine.Debug.LogException(ex);
            } finally
            {
                Finish();
            }
        }
All Usage Examples Of PlayMakerArrayListProxy::AddRange