public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { int independentVariable = info.GetInt32("IndependentVariable"); int dependentVariable = info.GetInt32("DependentVariable"); double[] parameter; info.GetArray("ParameterValues",out parameter); object fo = info.GetValue("FitFunction"); if( fo is Altaxo.Serialization.Xml.AssemblyAndTypeSurrogate) fo = ((Altaxo.Serialization.Xml.AssemblyAndTypeSurrogate)fo).CreateInstance(); FitFunctionToScalarFunctionDDWrapper s; if(o == null) { s = new FitFunctionToScalarFunctionDDWrapper(fo as IFitFunction,dependentVariable,independentVariable,parameter); } else { s = (FitFunctionToScalarFunctionDDWrapper)o; s = (FitFunctionToScalarFunctionDDWrapper)o; s._independentVariable = independentVariable; s._dependentVariable = dependentVariable; s._parameter = parameter; s._fitFunction = fo as IFitFunction; } return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { IntegerRangeAsCollection s = null!=o ? (IntegerRangeAsCollection)o : new IntegerRangeAsCollection(); s._start = info.GetInt32("Start"); s._count = info.GetInt32("Count"); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { NumericLabelFormattingBase s = (NumericLabelFormattingBase)o; info.GetBaseValueEmbedded(s, typeof(LabelFormattingBase), parent); s._decimalPlaces = info.GetInt32("DecimalPlaces"); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { RowHeaderStyle s = null != o ? (RowHeaderStyle)o : new RowHeaderStyle(); info.GetBaseValueEmbedded(s, typeof(RowHeaderStyle).BaseType, parent); s._rowHeight = info.GetInt32("Height"); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { Log10Scale s = null!=o ? (Log10Scale)o : new Log10Scale(); s._log10Org = (double)info.GetDouble("Log10Org"); s._log10End = (double)info.GetDouble("Log10End"); s._decadesPerMajorTick = (int)info.GetInt32("DecadesPerMajor"); bool AxisOrgFixed = (bool)info.GetBoolean("OrgFixed"); bool AxisEndFixed = (bool)info.GetBoolean("EndFixed"); s._dataBounds = (PositiveFiniteNumericalBoundaries)info.GetValue("Bounds",typeof(PositiveFiniteNumericalBoundaries)); s._dataBounds.BoundaryChanged += new BoundaryChangedHandler(s.OnBoundariesChanged); s._rescaling = new LogarithmicAxisRescaleConditions(); s._rescaling.SetOrgAndEnd(AxisOrgFixed ? BoundaryRescaling.Fixed : BoundaryRescaling.Auto, s.Org, AxisEndFixed ? BoundaryRescaling.Fixed:BoundaryRescaling.Auto, s.End); LogarithmicAxisRescaleConditions rescaling = new LogarithmicAxisRescaleConditions(); rescaling.SetOrgAndEnd(AxisOrgFixed ? BoundaryRescaling.Fixed : BoundaryRescaling.Auto, s.Org, AxisEndFixed ? BoundaryRescaling.Fixed:BoundaryRescaling.Auto, s.End); s._rescaling = rescaling; return s; }
public virtual object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { KohlrauschDecay s = o != null ? (KohlrauschDecay)o : new KohlrauschDecay(); s.NumberOfRelaxations = info.GetInt32("NumberOfRelaxations"); s._logarithmizeResult = info.GetBoolean("LogarithmizeResult"); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { AscendingIntegerCollection s = null != o ? (AscendingIntegerCollection)o : new AscendingIntegerCollection(); int count = info.OpenArray(); for (int i = 0; i < count; i++) { info.OpenElement(); int rangestart = info.GetInt32("Start"); int rangecount = info.GetInt32("Count"); info.CloseElement(); s.AddRange(rangestart, rangecount); } info.CloseArray(count); return s; }
protected virtual AngularRescaleConditions SDeserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { AngularRescaleConditions s = null != o ? (AngularRescaleConditions)o : new AngularRescaleConditions(); s._scaleOrigin = info.GetInt32("ScaleOrigin"); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { RegularPolygon s = null != o ? (RegularPolygon)o : new RegularPolygon(info); info.GetBaseValueEmbedded(s, typeof(RegularPolygon).BaseType, parent); s._vertices = info.GetInt32("NumberOfVertices"); s._cornerRadius = info.GetDouble("CornerRadius"); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { FiniteDateTimeBoundaries s = null != o ? (FiniteDateTimeBoundaries)o : new FiniteDateTimeBoundaries(); s._numberOfItems = info.GetInt32("NumberOfItems"); s._minValue = info.GetDateTime("MinValue"); s._maxValue = info.GetDateTime("MaxValue"); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { var s = (RandomCircles)o ?? new RandomCircles(); info.GetBaseValueEmbedded(s, s.GetType().BaseType, parent); s._randomSeed = info.GetInt32("RandomSeed"); s._circleDiameterPt = info.GetDouble("CircleDiameter"); s._fillingFactor = info.GetDouble("FillingFactor"); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { NumericalBoundaries s = (NumericalBoundaries)o; s._numberOfItems = info.GetInt32("NumberOfItems"); s._minValue = info.GetDouble("MinValue"); s._maxValue = info.GetDouble("MaxValue"); return s; }
protected virtual CSPlaneID SDeserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { var perpendicularAxisNumber = info.GetInt32("Axis"); var logicalValue = info.GetDouble("Logical"); var usePhysicalValue = info.GetBoolean("UsePhysical"); double physicalValue = 0; if (usePhysicalValue) physicalValue = (AltaxoVariant)info.GetValue("Physical", null); return new CSPlaneID(perpendicularAxisNumber, logicalValue, usePhysicalValue, physicalValue); }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { int numberOfLevelsDown = info.GetInt32("LevelsDown"); int count = info.OpenArray("Path"); var arr = new string[count]; for (int i = 0; i < count; i++) arr[i] = info.GetString(); info.CloseArray(count); return new RelativeDocumentPath(numberOfLevelsDown, arr); }
protected virtual CSPlaneID SDeserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { CSPlaneID s = (o == null ? new CSPlaneID() : (CSPlaneID)o); s._perpendicularAxisNumber = info.GetInt32("Axis"); s._logicalValue = info.GetDouble("Logical"); s._usePhysicalValue = info.GetBoolean("UsePhysical"); if (s._usePhysicalValue) s._physicalValue = (AltaxoVariant)info.GetValue("Physical", s); return s; }
protected virtual CultureSettings SDeserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { var s = null != o ? (CultureSettings)o : new CultureSettings(); s._cultureID = info.GetInt32("CultureID"); s._cultureName = info.GetString("CultureName"); s._numberDecimalSeparator = info.GetString("NumberDecimalSeparator"); s._numberGroupSeparator = info.GetString("NumberGroupSeparator"); s.SetCachedCultureInfo(); return s; }
public virtual object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { FitElement s = o!=null ? (FitElement)o : new FitElement(); s.FitFunction = (IFitFunction)info.GetValue("FitFunction",s); int numRows = info.GetInt32("NumberOfRows"); int firstRow = info.GetInt32("FirstRow"); s._rangeOfRows = PositiveIntegerRange.NewFromFirstAndCount(firstRow,numRows); int arraycount = info.OpenArray(); s._independentVariables = new NumericColumnProxy[arraycount]; for(int i=0;i<arraycount;++i) s._independentVariables[i] = (NumericColumnProxy)info.GetValue(s); info.CloseArray(arraycount); arraycount = info.OpenArray(); s._dependentVariables = new NumericColumnProxy[arraycount]; for(int i=0;i<arraycount;++i) s._dependentVariables[i] = (NumericColumnProxy)info.GetValue(s); info.CloseArray(arraycount); arraycount = info.OpenArray(); s._errorEvaluation = new IVarianceScaling[arraycount]; for(int i=0;i<arraycount;++i) s._errorEvaluation[i] = (IVarianceScaling)info.GetValue(s); info.CloseArray(arraycount); info.GetArray("ParameterNames",out s._parameterNames); for(int i=0;i<s._parameterNames.Length;++i) if(s._parameterNames[i]==string.Empty) s._parameterNames[i]=null; // serialization can not distinguish between an empty string and a null string s._parameterNameStart = info.GetString("ParameterNameStart"); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { Log10Scale s = null != o ? (Log10Scale)o : new Log10Scale(); s._log10Org = (double)info.GetDouble("Log10Org"); s._log10End = (double)info.GetDouble("Log10End"); s._decadesPerMajorTick = (int)info.GetInt32("DecadesPerMajor"); bool AxisOrgFixed = (bool)info.GetBoolean("OrgFixed"); bool AxisEndFixed = (bool)info.GetBoolean("EndFixed"); s._dataBounds = (PositiveFiniteNumericalBoundaries)info.GetValue("Bounds", s); s._dataBounds.ParentObject = s; s._rescaling = new LogarithmicScaleRescaleConditions() { ParentObject = s }; s._rescaling.SetUserParameters(AxisOrgFixed ? BoundaryRescaling.Fixed : BoundaryRescaling.Auto, s.Org, AxisEndFixed ? BoundaryRescaling.Fixed : BoundaryRescaling.Auto, s.End); return s; }
protected virtual DropLinePlotStyle SDeserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { DropLinePlotStyle s = null != o ? (DropLinePlotStyle)o : new DropLinePlotStyle(info); s._independentSkipFreq = info.GetBoolean("IndependentSkipFreq"); s._skipFreq = info.GetInt32("SkipFreq"); s._dropTargets = (CSPlaneIDList)info.GetValue("DropLine", s); s._additionalDropTargetIsEnabled = info.GetBoolean("HasAdditionalDropTarget"); if (s._additionalDropTargetIsEnabled) { s._additionalDropTargetPerpendicularAxis = info.GetInt32("AdditionalDropTargetAxis"); s._additionalDropTargetUsePhysicalBaseValue = info.GetBoolean("AdditionalDropTargetUsePhysicalValue"); s._additionalDropTargetBaseValue = (Altaxo.Data.AltaxoVariant)info.GetValue("AdditionalDropTargetBaseValue", s); } s._pen = (PenX3D)info.GetValue("Pen", s); s._independentColor = info.GetBoolean("IndependentColor"); s._independentSymbolSize = info.GetBoolean("IndependentSymbolSize"); s._symbolSize = info.GetDouble("SymbolSize"); s._lineWidth1Offset = info.GetDouble("LineWidth1Offset"); s._lineWidth1Factor = info.GetDouble("LineWidth1Factor"); s._lineWidth2Offset = info.GetDouble("LineWidth2Offset"); s._lineWidth2Factor = info.GetDouble("LineWidth2Factor"); s._gapAtStartOffset = info.GetDouble("GapAtStartOffset"); s._gapAtStartFactor = info.GetDouble("GapAtStartFactor"); s._gapAtEndOffset = info.GetDouble("GapAtEndOffset"); s._gapAtEndFactor = info.GetDouble("GapAtEndFactor"); return s; }
protected virtual CSLineID SDeserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { CSLineID s = (o == null ? new CSLineID() : (CSLineID)o); s._parallelAxisNumber = info.GetInt32("Axis"); s._logicalValueFirstOther = info.GetDouble("Logical1"); s._usePhysicalValueFirstOther = info.GetBoolean("UsePhysical1"); if (s._usePhysicalValueFirstOther) s._physicalValueFirstOther = (AltaxoVariant)info.GetValue("Physical1", s); bool is3D = info.GetBoolean("Is3D"); if (is3D) { s._logicalValueSecondOther = info.GetDouble("Logical1"); s._usePhysicalValueSecondOther = info.GetBoolean("UsePhysical2"); if (s._usePhysicalValueSecondOther) s._physicalValueSecondOther = (AltaxoVariant)info.GetValue("Physical2", s); } return s; }
protected virtual ErrorBarPlotStyle SDeserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { ErrorBarPlotStyle s = null != o ? (ErrorBarPlotStyle)o : new ErrorBarPlotStyle(); s._positiveErrorColumn = (Altaxo.Data.NumericColumnProxy)info.GetValue("PositiveError"); s._negativeErrorColumn = (Altaxo.Data.NumericColumnProxy)info.GetValue("NegativeError"); s._independentColor = info.GetBoolean("IndependentColor"); s.Pen = (PenX)info.GetValue("Pen", s); s._isHorizontalStyle = (0==info.GetInt32("Axis")); s._independentSymbolSize = info.GetBoolean("IndependentSymbolSize"); s._symbolSize = info.GetInt32("SymbolSize"); s._symbolGap = info.GetBoolean("SymbolGap"); s._skipFreq = info.GetInt32("SkipFreq"); s._showEndBars = info.GetBoolean("ShowEndBars"); s._doNotShiftHorizontalPosition = info.GetBoolean("NotShiftHorzPos"); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { var first = info.GetInt32("First"); var last = info.GetInt32("Last"); return new RangeOfRowIndices { _firstRowIndexInclusive = first, _lastRowIndexInclusive = last }; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { var start = info.GetInt32("Start"); var count = info.GetInt32("Count"); return RangeOfRowIndices.FromStartAndCount(start, count); }
public virtual XYColumnPlotData SDeserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { var s = (XYColumnPlotData)o ?? new XYColumnPlotData(info); s._dataTable = (DataTableProxy)info.GetValue("DataTable", s); if (null != s._dataTable) s._dataTable.ParentObject = s; s._groupNumber = info.GetInt32("GroupNumber"); s.ChildSetMember(ref s._dataRowSelection, (IRowSelection)info.GetValue("RowSelection", s)); s._xColumn = (IReadableColumnProxy)info.GetValue("XColumn", s); if (null != s._xColumn) s._xColumn.ParentObject = s; s._yColumn = (IReadableColumnProxy)info.GetValue("YColumn", s); if (null != s._yColumn) s._yColumn.ParentObject = s; s._xBoundaries = (IPhysicalBoundaries)info.GetValue("XBoundaries", s); if (null != s._xBoundaries) s._xBoundaries.ParentObject = s; s._yBoundaries = (IPhysicalBoundaries)info.GetValue("YBoundaries", s); if (null != s._yBoundaries) s._yBoundaries.ParentObject = s; return s; }
public virtual XYColumnPlotData SDeserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { XYColumnPlotData s = null != o ? (XYColumnPlotData)o : new XYColumnPlotData(info); s._xColumn = (IReadableColumnProxy)info.GetValue("XColumn", s); if (null != s._xColumn) s._xColumn.ParentObject = s; s._yColumn = (IReadableColumnProxy)info.GetValue("YColumn", s); if (null != s._yColumn) s._yColumn.ParentObject = s; s._xBoundaries = (IPhysicalBoundaries)info.GetValue("XBoundaries", s); if (null != s._xBoundaries) s._xBoundaries.ParentObject = s; s._yBoundaries = (IPhysicalBoundaries)info.GetValue("YBoundaries", s); if (null != s._yBoundaries) s._yBoundaries.ParentObject = s; int rangeStart = info.GetInt32("RangeStart"); int rangeLength = info.GetInt32("RangeLength"); if (rangeStart < 0 || rangeLength != int.MaxValue) s.ChildSetMember(ref s._dataRowSelection, RangeOfRowIndices.FromStartAndCount(rangeStart, rangeLength)); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { DataColumnScript s = null != o ? (DataColumnScript)o : new DataColumnScript(); ScriptStyle scriptStyle = (ScriptStyle)info.GetInt32("Style"); string scriptText = info.GetString("Text"); string rowFrom = info.GetString("From"); string rowCondition = info.GetString("Cond"); string rowTo = info.GetString("To"); string rowInc = info.GetString("Inc"); s.ScriptText = scriptText; return s; }
protected virtual AutoUpdateSettings SDeserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { var s = (o == null ? new AutoUpdateSettings() : (AutoUpdateSettings)o); s.EnableAutoUpdates = info.GetBoolean("EnableAutoUpdates"); s.DownloadUnstableVersion = info.GetBoolean("DownloadUnstableVersion"); s.DownloadIntervalInDays = info.GetInt32("DownloadIntervalInDays"); s.ShowDownloadWindow = info.GetBoolean("ShowDownloadWindow"); s.InstallAtStartup = info.GetBoolean("InstallAtStartup"); s.InstallAtShutdown = info.GetBoolean("InstallAtShutDown"); s.ConfirmInstallation = info.GetBoolean("ConfirmInstallation"); s.ShowInstallationWindow = info.GetBoolean("ShowInstallationWindow"); s.InstallationWindowClosingTime = info.GetInt32("InstallationWindowClosingTime"); return s; }
public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { LinePlotStyle s = (LinePlotStyle)o ?? new LinePlotStyle(info); s._independentSkipFrequency = info.GetBoolean("IndependentSkipFreq"); s._skipFrequency = info.GetInt32("SkipFreq"); s._ignoreMissingDataPoints = info.GetBoolean("IgnoreMissingDataPoints"); s._independentOnShiftingGroupStyles = info.GetBoolean("IndependentOnShiftingGroupStyles"); s._connectCircular = info.GetBoolean("ConnectCircular"); s._connectionStyle = (ILineConnectionStyle)info.GetValue("Connection", s); s._linePen = (PenX)info.GetValue("Pen", s); if (null != s._linePen) s._linePen.ParentObject = s; s._independentDashStyle = info.GetBoolean("IndependentDashStyle"); s._independentColor = info.GetBoolean("IndependentColor"); s._independentSymbolSize = info.GetBoolean("IndependentSymbolSize"); s._symbolSize = info.GetDouble("SymbolSize"); s._useSymbolGap = info.GetBoolean("UseSymbolGap"); s._symbolGapOffset = info.GetDouble("SymbolGapOffset"); s._symbolGapFactor = info.GetDouble("SymbolGapFactor"); return s; }
public virtual object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { HavriliakNegamiSusceptibility s = o != null ? (HavriliakNegamiSusceptibility)o : new HavriliakNegamiSusceptibility(); s._useFrequencyInsteadOmega = info.GetBoolean("UseFrequency"); s._useFlowTerm = info.GetBoolean("FlowTerm"); s._isDielectricData = info.GetBoolean("IsDielectric"); s._invertViscosity = info.GetBoolean("InvertViscosity"); s.NumberOfRelaxations = info.GetInt32("NumberOfRelaxations"); s._invertResult = info.GetBoolean("InvertResult"); s._logarithmizeResults = info.GetBoolean("LogarithmizeResults"); return s; }
protected virtual BarGraphPlotStyle SDeserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent) { BarGraphPlotStyle s = null != o ? (BarGraphPlotStyle)o : new BarGraphPlotStyle(info); s._usePhysicalBaseValue = info.GetBoolean("UsePhysicalBaseValue"); s._baseValue = (Altaxo.Data.AltaxoVariant)info.GetValue("BaseValue", s); s._startAtPreviousItem = info.GetBoolean("StartAtPrevious"); s._previousItemZGap = info.GetDouble("PreviousItemGap"); s._pen = (PenX3D)info.GetValue("Pen", s); s._independentColor = info.GetBoolean("IndependentColor"); s._useUniformCrossSectionThickness = info.GetBoolean("UseUniformCrossSectionThickness"); s._barShiftStrategy = (BarShiftStrategy3D)info.GetEnum("BarShift", typeof(BarShiftStrategy3D)); s._barShiftMaxNumberOfItemsInOneDirection = info.GetInt32("BarShiftMaxItems"); s._relInnerGapX = info.GetDouble("InnerGapX"); s._relOuterGapX = info.GetDouble("OuterGapX"); s._relInnerGapY = info.GetDouble("InnerGapY"); s._relOuterGapY = info.GetDouble("OuterGapY"); return s; }