Click or drag to resize

MVCANControllerEditOriginalDocBaseTModel, TView Class

Base of all controllers that edit the original document directly (live).
Inheritance Hierarchy
SystemObject
  Altaxo.GuiControllerBase
    Altaxo.GuiMVCANControllerEditOriginalDocBaseTModel, TView
      More

Namespace: Altaxo.Gui
Assembly: AltaxoBase (in AltaxoBase.dll) Version: 4.8.3179.0 (4.8.3179.0)
Syntax
C#
public abstract class MVCANControllerEditOriginalDocBase<TModel, TView> : ControllerBase, 
	IMVCANController, IMVCAController, IMVCController, IDisposable, IApplyController
where TModel : ICloneable
where TView : class

Type Parameters

TModel
The type of the document to edit.
TView
The type of the view.

The MVCANControllerEditOriginalDocBaseTModel, TView type exposes the following members.

Constructors
 NameDescription
Protected methodMVCANControllerEditOriginalDocBaseTModel, TViewInitializes a new instance of the MVCANControllerEditOriginalDocBaseTModel, TView class
Top
Properties
 NameDescription
Protected propertyCreateNotInitializedException 
Protected propertyCreateNoViewException 
Public propertyDocGets the current document of this controller. If the document is null, an InvalidOperationException is thrown. To check whether the document is null, check on the member _doc directly.
Public propertyIsDisposedGet a value indication whether this controller is already disposed.
(Inherited from ControllerBase)
Public propertyModelObject Returns the document that this controller manages to edit.
Protected propertyNoDocumentException
(Inherited from ControllerBase)
Protected propertyNotInitializedException
(Inherited from ControllerBase)
Protected propertyNoViewException
(Inherited from ControllerBase)
Public propertyUseDocumentCopy Sets whether or not a copy of the document is used. If set to true, a copy of the document is used, so if the controller is not applied, all changes can be reverted. If set to false, no copy must be made. The document is directly changed by the controller, and changes can not be reverted. Use the last option if a controller up in the hierarchie has already made a copy of the document.
Public propertyViewObject Returns the Gui element that shows the model to the user.
Top
Methods
 NameDescription
Public methodApply Called when the user input has to be applied to the document being controlled. Returns true if Apply is successfull.
Protected methodApplyEnd Standard procedure at the end of the Apply phase. If the applyResult is true, the controller is either disposed (if disposeController is true) or the document is shortly resumed (if disposeController is false. Nothing is done if applyResult is false.
Protected methodAttachView Override this function to attach the view to the controller, either by subscribing to events of the view, or by setting the controller object on the view.
Protected methodCheckDocumentInitializedT
(Inherited from ControllerBase)
Protected methodDetachView Override this function to detach the view from the controller, either by unsubscribing to events of the view, or by setting the controller object on the view to null.
Public methodDispose Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
(Inherited from ControllerBase)
Public methodDispose(Boolean) Releases unmanaged and - optionally - managed resources.
(Overrides ControllerBaseDispose(Boolean))
Public methodEqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
Public methodGetHashCodeServes as the default hash function.
(Inherited from Object)
Public methodGetSubControllers Enumerates the sub controllers. This function is called on Dispose(Boolean) of this controller to dispose the subcontrollers too. By overriding this function, there is no need to override Dispose(Boolean)
Protected methodGetSuspendTokenForControllerDocument Gets the suspend token for the controller document. This default implementation calls SuspendGetToken() on the document. By overriding this function you can suspend parent nodes in case it is neccessary to modify nodes at lower levels of the hierarchy.
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Protected methodInitialize Basic initialization of the document. Here, it is tried to suspend the event handling of the documnt by calling GetSuspendTokenForControllerDocument (but only if _useDocumentCopy is true).
Public methodInitializeDocument Initialize the controller with the document. If successfull, the function has to return true.
Protected methodMemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Public methodOnPropertyChanged
(Inherited from ControllerBase)
Public methodRevert Try to revert changes to the model, i.e. restores the original state of the model.
Protected methodThrowIfNotInitializedThrows an exception if the controller is not initialized with a document.
Public methodToStringReturns a string that represents the current object.
(Inherited from Object)
Top
Events
 NameDescription
Public eventPropertyChanged Occurs when a property value changes.
(Inherited from ControllerBase)
Top
Fields
 NameDescription
Protected field_clonedCopyOfDocCloned copy of the document (is null if _useDocumentCopy is false). Used to revert the edited document to the state before editing.
Protected field_docThe document to edit.
Protected field_suspendToken The suspend token of the document being edited. If _useDocumentCopy is false, we assume that a controller higher in hierarchy has made a copy of the document, thus we do not use a suspendToken for the document.
Protected field_useDocumentCopyIf true, a copy of the document is made before editing; this copy can later be used to revert the state of the document to the original state.
Protected field_viewThe Gui view of this controller
Top
See Also
Inheritance Hierarchy
SystemObject
  Altaxo.GuiControllerBase
    Altaxo.GuiMVCANControllerEditOriginalDocBaseTModel, TView
      Altaxo.Gui.Analysis.FourierRealFourierTransformation2DController
      Altaxo.Gui.Analysis.FourierRealFourierTransformationController
      Altaxo.Gui.Analysis.NonLinearFittingParameterSetController
      Altaxo.Gui.Analysis.StatisticsHistogramCreationController
      Altaxo.Gui.Analysis.StatisticsLinearBinningController
      Altaxo.Gui.Analysis.StatisticsLogarithmicBinningController
      Altaxo.Gui.CommonAscendingIntegerCollectionController
      Altaxo.Gui.Common.ToolsTestAllProjectsInFolderController
      Altaxo.Gui.DataConvertXYVToMatrixController
      Altaxo.Gui.DataConvertXYVToMatrixDataController
      Altaxo.Gui.DataConvertXYVToMatrixOptionsController
      Altaxo.Gui.DataDataSourceControllerBaseTItem
      Altaxo.Gui.DataDataSourceImportOptionsController
      Altaxo.Gui.DataDataTableMatrixProxyController
      Altaxo.Gui.DataDataTableMatrixProxyWithMultipleColumnHeaderColumnsController
      Altaxo.Gui.DataDataTableProxyController
      Altaxo.Gui.DataDataTableTransposeOptionsController
      Altaxo.Gui.DataDataTableXYColumnProxyController
      Altaxo.Gui.DataDecomposeByColumnContentController
      Altaxo.Gui.DataDecomposeByColumnContentDataController
      Altaxo.Gui.DataDecomposeByColumnContentOptionsController
      Altaxo.Gui.DataExpandCyclingVariableController
      Altaxo.Gui.DataExpandCyclingVariableDataController
      Altaxo.Gui.DataExpandCyclingVariableOptionsController
      Altaxo.Gui.DataFileImportScriptDataSourceController
      Altaxo.Gui.DataConnectionAltaxoOleDbDataSourceController
      Altaxo.Gui.DataConnectionLoginCredentialsController
      Altaxo.Gui.Graph.GdiArrangeLayersController
      Altaxo.Gui.Graph.Gdi.AxisAxisCreationController
      Altaxo.Gui.Graph.Gdi.AxisAxisLabelStyleController
      Altaxo.Gui.Graph.Gdi.AxisAxisLineStyleController
      Altaxo.Gui.Graph.Gdi.AxisGridPlaneController
      Altaxo.Gui.Graph.Gdi.AxisXYGridStyleController
      Altaxo.Gui.Graph.GdiClipboardRenderingOptionsController
      Altaxo.Gui.Graph.Gdi.CSG2DCartesicCSController
      Altaxo.Gui.Graph.Gdi.CSG2DPolarCSController
      Altaxo.Gui.Graph.Gdi.CSG3DCartesicCSController
      Altaxo.Gui.Graph.GdiDefaultLineScatterGraphDocumentController
      Altaxo.Gui.Graph.GdiEmbeddedObjectRenderingOptionsController
      Altaxo.Gui.Graph.GdiGraphExportOptionsController
      Altaxo.Gui.Graph.GdiHostLayerController
      Altaxo.Gui.Graph.GdiItemLocationByGridController
      Altaxo.Gui.Graph.GdiItemLocationDirectController
      Altaxo.Gui.Graph.Gdi.LabelFormattingDateTimeLabelFormattingController
      Altaxo.Gui.Graph.Gdi.LabelFormattingFreeLabelFormattingController
      Altaxo.Gui.Graph.Gdi.LabelFormattingMultiLineLabelFormattingBaseController
      Altaxo.Gui.Graph.Gdi.LabelFormattingNumericLabelFormattingScientificController
      Altaxo.Gui.Graph.Gdi.PlotDensityImagePlotItemController
      Altaxo.Gui.Graph.Gdi.PlotDensityImagePlotItemOptionController
      Altaxo.Gui.Graph.Gdi.PlotG2DPlotItemController
      Altaxo.Gui.Graph.Gdi.Plot.GroupsPlotGroupCollectionController
      Altaxo.Gui.Graph.Gdi.Plot.GroupsPlotGroupCollectionControllerAdvanced
      Altaxo.Gui.Graph.Gdi.Plot.GroupsPlotGroupCollectionControllerSimple
      Altaxo.Gui.Graph.Gdi.Plot.GroupsWaterfallTransformController
      Altaxo.Gui.Graph.Gdi.Plot.StylesBarGraphPlotStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesColumnDrivenColorPlotStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesColumnDrivenSymbolSizePlotStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesDensityImagePlotStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesDropAreaPlotStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesDropLinePlotStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesErrorBarPlotStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesFillToCurvePlotStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesLinePlotStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesScatterPlotStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesVectorCartesicPlotStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesXYPlotLabelStyleController
      Altaxo.Gui.Graph.Gdi.Plot.StylesXYPlotStyleCollectionController
      Altaxo.Gui.Graph.Gdi.PlotXYPlotLayerContentsController
      Altaxo.Gui.Graph.Gdi.ShapesClosedCardinalSplineController
      Altaxo.Gui.Graph.Gdi.ShapesClosedPathShapeController
      Altaxo.Gui.Graph.Gdi.ShapesDensityImageLegendController
      Altaxo.Gui.Graph.Gdi.ShapesFloatingScaleController
      Altaxo.Gui.Graph.Gdi.ShapesImageGraphicController
      Altaxo.Gui.Graph.Gdi.ShapesOpenCardinalSplineController
      Altaxo.Gui.Graph.Gdi.ShapesOpenPathShapeController
      Altaxo.Gui.Graph.Gdi.ShapesRegularPolygonController
      Altaxo.Gui.Graph.Gdi.ShapesShapeGroupController
      Altaxo.Gui.Graph.Gdi.ShapesTextGraphicController
      Altaxo.Gui.Graph.GdiXYPlotLayerController
      Altaxo.Gui.Graph.Graph2D.Plot.StylesScatterSymbolController
      Altaxo.Gui.Graph.Graph2DResizeGraphController
      Altaxo.Gui.Graph.Graph3D.AxisAxisCreationController
      Altaxo.Gui.Graph.Graph3D.AxisAxisLabelStyleController
      Altaxo.Gui.Graph.Graph3D.AxisAxisLineStyleController
      Altaxo.Gui.Graph.Graph3D.AxisGridPlaneController
      Altaxo.Gui.Graph.Graph3D.AxisXYGridStyleController
      Altaxo.Gui.Graph.Graph3DGridPartitioningController
      Altaxo.Gui.Graph.Graph3DHostLayerController
      Altaxo.Gui.Graph.Graph3DItemLocationByGridController
      Altaxo.Gui.Graph.Graph3DItemLocationDirectController
      Altaxo.Gui.Graph.Graph3D.LabelFormattingDateTimeLabelFormattingController
      Altaxo.Gui.Graph.Graph3D.LabelFormattingFreeLabelFormattingController
      Altaxo.Gui.Graph.Graph3D.LabelFormattingMultiLineLabelFormattingBaseController
      Altaxo.Gui.Graph.Graph3D.LabelFormattingNumericLabelFormattingScientificController
      Altaxo.Gui.Graph.Graph3D.PlotG3DPlotItemController
      Altaxo.Gui.Graph.Graph3D.Plot.GroupsPlotGroupCollectionController
      Altaxo.Gui.Graph.Graph3D.Plot.GroupsPlotGroupCollectionControllerAdvanced
      Altaxo.Gui.Graph.Graph3D.Plot.GroupsPlotGroupCollectionControllerSimple
      Altaxo.Gui.Graph.Graph3D.Plot.GroupsScatterSymbolGroupStyleController
      Altaxo.Gui.Graph.Graph3D.Plot.StylesBarGraphPlotStyleController
      Altaxo.Gui.Graph.Graph3D.Plot.StylesDataMeshPlotStyleController
      Altaxo.Gui.Graph.Graph3D.Plot.StylesDropLinePlotStyleController
      Altaxo.Gui.Graph.Graph3D.Plot.StylesErrorBarPlotStyleController
      Altaxo.Gui.Graph.Graph3D.Plot.StylesLinePlotStyleController
      Altaxo.Gui.Graph.Graph3D.Plot.StylesScatterPlotStyleController
      Altaxo.Gui.Graph.Graph3D.Plot.StylesVectorCartesicPlotStyleController
      Altaxo.Gui.Graph.Graph3D.Plot.StylesXYPlotLabelStyleController
      Altaxo.Gui.Graph.Graph3D.Plot.StylesXYZPlotStyleCollectionController
      Altaxo.Gui.Graph.Graph3D.ShapesClosedPathShapeController
      Altaxo.Gui.Graph.Graph3D.ShapesOpenPathShapeController
      Altaxo.Gui.Graph.Graph3D.ShapesShapeGroupController
      Altaxo.Gui.Graph.Graph3D.ShapesTextGraphicController
      Altaxo.Gui.Graph.Graph3D.TemplatesDefaultCartesicPlotTemplateController
      Altaxo.Gui.Graph.Graph3DXYPlotLayerController
      Altaxo.Gui.Graph.Graph3DXYZPlotLayerContentsController
      Altaxo.Gui.GraphGridPartitioningController
      Altaxo.Gui.Graph.Plot.DataColumnPlotDataControllerBaseTModel
      Altaxo.Gui.Graph.Plot.DataColumnPlotDataExchangeColumnsController
      Altaxo.Gui.Graph.Plot.DataColumnPlotDataExchangeTableController
      Altaxo.Gui.Graph.Plot.DataFunctionPlotDataController
      Altaxo.Gui.Graph.Plot.DataXYZMeshedColumnPlotDataController
      Altaxo.Gui.Graph.Plot.GroupsColorGroupStyleController
      Altaxo.Gui.Graph.Plot.GroupsDashPatternGroupStyleController
      Altaxo.Gui.GraphPlottingRangeController
      Altaxo.Gui.Graph.ScalesAxisLinkController
      Altaxo.Gui.Graph.Scales.RescalingAngularScaleRescaleConditionsController
      Altaxo.Gui.Graph.Scales.RescalingCumulativeProbabilityScaleRescaleConditionsController
      Altaxo.Gui.Graph.Scales.RescalingDateTimeScaleRescaleConditionsController
      Altaxo.Gui.Graph.Scales.RescalingInverseScaleRescaleConditionsController
      Altaxo.Gui.Graph.Scales.RescalingLinearScaleRescaleConditionsController
      Altaxo.Gui.Graph.Scales.RescalingLogarithmicScaleRescaleConditionsController
      Altaxo.Gui.Graph.Scales.TicksAngularTickSpacingController
      Altaxo.Gui.Graph.Scales.TicksCumulativeProbabilityTickSpacingController
      Altaxo.Gui.Graph.Scales.TicksDateTimeTickSpacingController
      Altaxo.Gui.Graph.Scales.TicksInverseTickSpacingController
      Altaxo.Gui.Graph.Scales.TicksLinearTickSpacingController
      Altaxo.Gui.Graph.Scales.TicksLog10TickSpacingController
      Altaxo.Gui.Graph.Scales.TicksNoTickSpacingController
      Altaxo.Gui.Graph.Scales.TicksSpanTickSpacingController
      Altaxo.Gui.Graph.Scales.TicksTextTickSpacingController
      Altaxo.Gui.MainAddBasicPropertyValueController
      Altaxo.Gui.MainPropertyBagController
      Altaxo.GuiMVCANControllerEditOriginalDocInstanceCanChangeBaseTModel, TView
      Altaxo.GuiMVCANDControllerEditOriginalDocBaseTModel, TView
      Altaxo.Gui.Science.Spectroscopy.RamanRamanCalibrationDataSourceController
      Altaxo.Gui.Science.SpectroscopySpectralPreprocessingDataController
      Altaxo.Gui.ScriptingFitFunctionNameAndCategoryController
      Altaxo.Gui.Serialization.AsciiAsciiDocumentAnalysisOptionsController
      Altaxo.Gui.Serialization.AsciiAsciiImportOptionsController
      Altaxo.Gui.Serialization.ClipboardProjectItemsPasteOptionsController
      Altaxo.Gui.SettingsAutoUpdateSettingsController
      Altaxo.Gui.SettingsCultureSettingsController
      Altaxo.Gui.TextHtmlExportOptionsController
      Altaxo.Gui.TextMamlExportOptionsController
      Altaxo.Gui.WorksheetAsciiImportDataSourceController