Пример #1
0
        protected void ResetPersistentData(IEnumerable <IGH_Goo> list, string name)
        {
            RecordPersistentDataEvent(name);

            PersistentData.Clear();
            if (list is object)
            {
                PersistentData.AppendRange(list, new GH_Path(0));
            }

            OnObjectChanged(GH_ObjectEventType.PersistentData);

            base.ClearData();
            ExpireDownStreamObjects();
            OnSolutionExpired(false);

            Phase = GH_SolutionPhase.Collecting;
            AddVolatileDataTree(PersistentData.Duplicate());
            PostProcessVolatileData();
            Phase = GH_SolutionPhase.Collected;

            if (OnPingDocument() is GH_Document doc)
            {
                doc.ClearReferenceTable();
                doc.NewSolution(false);
            }
        }