protected virtual void Dispose(bool disposing) { if (!disposedValue) { if (disposing) { WriteAction = null; ReadAction = null; // 以下、固有定義開放 RootFunc?.Dispose(); RootFunc = null; } disposedValue = true; } }
public _AssetXML(OwnerClass self) { WriteAction = () => { DataVersion = DATA_VERSION; RootFuncType info = new RootFuncType(); info.AttachVariableIds = self.attachVariableIds; if (self.AttachParam is AttachText) { info.AttachFileName = (string)self.AttachParam.Value; } else { info.AttachFileName = null; } if (self.AttachParam is AttachVariableId) { info.AttachVariableId = (int)self.AttachParam.Value; } else { info.AttachVariableId = 0; } info.AssetType = self.AssetType; info.AssetFuncType = self.AssetFuncType; info.AssetValueTypes = new List <string>(); foreach (var type in self.SelectedVariableType) { if (type != null) { info.AssetValueTypes.Add(type.FullName); } } self.LinkConnectorControl.AssetXML.WriteAction?.Invoke(); info.RootConnector = self.LinkConnectorControl.AssetXML; RootFunc = info; }; }