Slicer  5.3
Slicer is a multi-platform, free and open source software package for visualization and medical image computing
List of all members | Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Static Protected Member Functions
vtkMRMLAbstractLogic Class Reference

Superclass for MRML logic classes. More...

#include <Libs/MRML/Logic/vtkMRMLAbstractLogic.h>

Inheritance diagram for vtkMRMLAbstractLogic:
Inheritance graph
[legend]
Collaboration diagram for vtkMRMLAbstractLogic:
Collaboration graph
[legend]

Public Types

typedef vtkObject Superclass
 
typedef void(vtkMRMLAbstractLogic::* TaskFunctionPointer) (void *clientdata)
 

Public Member Functions

virtual const char * GetClassName ()
 
virtual vtkMRMLApplicationLogicGetMRMLApplicationLogic () const
 Get access to overall application state. More...
 
vtkMRMLSceneGetMRMLScene () const
 Return a reference to the current MRML scene. More...
 
virtual int IsA (const char *type)
 
void PrintSelf (ostream &os, vtkIndent indent) override
 
virtual void SetMRMLApplicationLogic (vtkMRMLApplicationLogic *logic)
 
void SetMRMLScene (vtkMRMLScene *newScene)
 Set and observe the MRMLScene. More...
 

Static Public Member Functions

static int IsTypeOf (const char *type)
 
static vtkMRMLAbstractLogicNew ()
 
static vtkMRMLAbstractLogicSafeDownCast (vtkObject *o)
 

Protected Member Functions

int EndModify (bool wasModifying)
 
virtual bool EnterMRMLLogicsCallback () const
 
virtual bool EnterMRMLNodesCallback () const
 
virtual bool EnterMRMLSceneCallback () const
 
bool GetDisableModifiedEvent () const
 
int GetInMRMLLogicsCallbackFlag () const
 
int GetInMRMLNodesCallbackFlag () const
 
int GetInMRMLSceneCallbackFlag () const
 
vtkCallbackCommand * GetMRMLLogicsCallbackCommand ()
 
vtkObserverManagerGetMRMLLogicsObserverManager () const
 
vtkCallbackCommand * GetMRMLNodesCallbackCommand ()
 
vtkObserverManagerGetMRMLNodesObserverManager () const
 
vtkCallbackCommand * GetMRMLSceneCallbackCommand ()
 
vtkObserverManagerGetMRMLSceneObserverManager () const
 
int GetPendingModifiedEventCount () const
 
int GetProcessingMRMLSceneEvent () const
 Return the event id currently processed or 0 if any. More...
 
int InvokePendingModifiedEvent ()
 
void Modified () override
 
virtual void ObserveMRMLScene ()
 
virtual void OnMRMLNodeModified (vtkMRMLNode *)
 
virtual void OnMRMLSceneEndBatchProcess ()
 
virtual void OnMRMLSceneEndClose ()
 
virtual void OnMRMLSceneEndImport ()
 
virtual void OnMRMLSceneEndRestore ()
 
virtual void OnMRMLSceneNew ()
 
virtual void OnMRMLSceneNodeAdded (vtkMRMLNode *)
 
virtual void OnMRMLSceneNodeRemoved (vtkMRMLNode *)
 
virtual void OnMRMLSceneStartBatchProcess ()
 
virtual void OnMRMLSceneStartClose ()
 
virtual void OnMRMLSceneStartImport ()
 
virtual void OnMRMLSceneStartRestore ()
 
virtual void ProcessMRMLLogicsEvents (vtkObject *caller, unsigned long event, void *callData)
 
virtual void ProcessMRMLNodesEvents (vtkObject *caller, unsigned long event, void *callData)
 
virtual void ProcessMRMLSceneEvents (vtkObject *caller, unsigned long event, void *callData)
 
virtual void RegisterNodes ()
 
void SetAndObserveMRMLSceneEventsInternal (vtkMRMLScene *newScene, vtkIntArray *events, vtkFloatArray *priorities=nullptr)
 
void SetDisableModifiedEvent (bool onOff)
 
void SetInMRMLLogicsCallbackFlag (int flag)
 
void SetInMRMLNodesCallbackFlag (int flag)
 
void SetInMRMLSceneCallbackFlag (int flag)
 
virtual void SetMRMLSceneInternal (vtkMRMLScene *newScene)
 
void SetProcessingMRMLSceneEvent (int event)
 
bool StartModify ()
 
virtual void UnobserveMRMLScene ()
 
virtual void UpdateFromMRMLScene ()
 
 vtkMRMLAbstractLogic ()
 
 ~vtkMRMLAbstractLogic () override
 

Static Protected Member Functions

static void MRMLLogicsCallback (vtkObject *caller, unsigned long eid, void *clientData, void *callData)
 MRMLLogicCallback is a static function to relay modified events from the logics. More...
 
static void MRMLNodesCallback (vtkObject *caller, unsigned long eid, void *clientData, void *callData)
 MRMLNodesCallback is a static function to relay modified events from the nodes. More...
 
static void MRMLSceneCallback (vtkObject *caller, unsigned long eid, void *clientData, void *callData)
 

Detailed Description

Superclass for MRML logic classes.

Superclass for all MRML logic classes. When a scene is set, SetMRMLScene(vtkMRMLScene*),

Definition at line 133 of file vtkMRMLAbstractLogic.h.

Member Typedef Documentation

◆ Superclass

Definition at line 142 of file vtkMRMLAbstractLogic.h.

◆ TaskFunctionPointer

typedef void(vtkMRMLAbstractLogic::* vtkMRMLAbstractLogic::TaskFunctionPointer) (void *clientdata)

Typedef for member functions of MRMLLogic that can be used as scheduled tasks.

Definition at line 138 of file vtkMRMLAbstractLogic.h.

Constructor & Destructor Documentation

◆ vtkMRMLAbstractLogic()

vtkMRMLAbstractLogic::vtkMRMLAbstractLogic ( )
protected

◆ ~vtkMRMLAbstractLogic()

vtkMRMLAbstractLogic::~vtkMRMLAbstractLogic ( )
overrideprotected

Member Function Documentation

◆ EndModify()

int vtkMRMLAbstractLogic::EndModify ( bool  wasModifying)
inlineprotected

End modifying the node. Enable Modify events if the previous state of DisableModifiedEvent flag is 0. Return the number of pending ModifiedEvent;

Definition at line 457 of file vtkMRMLAbstractLogic.h.

◆ EnterMRMLLogicsCallback()

virtual bool vtkMRMLAbstractLogic::EnterMRMLLogicsCallback ( ) const
protectedvirtual

Return true if the Logics callback must be executed, false otherwise. By default, it returns true, you can reimplement it in subclasses

◆ EnterMRMLNodesCallback()

virtual bool vtkMRMLAbstractLogic::EnterMRMLNodesCallback ( ) const
protectedvirtual

Return true if the MRML Nodes callback must be executed, false otherwise. By default, it returns true, you can reimplement it in subclasses.

See also
SetInMRMLNodesCallbackFlag()

◆ EnterMRMLSceneCallback()

virtual bool vtkMRMLAbstractLogic::EnterMRMLSceneCallback ( ) const
protectedvirtual

Return true if the MRML callback must be executed, false otherwise. By default, it returns true, you can reimplement it in subclasses

◆ GetClassName()

virtual const char* vtkMRMLAbstractLogic::GetClassName ( )
virtual

Reimplemented in vtkMRMLLayoutLogic, vtkSlicerCropVolumeLogic, vtkSlicerVolumesLogic, vtkSlicerMarkupsLogic, vtkMRMLSliceLayerLogic, vtkSlicerVolumeRenderingLogic, vtkMRMLSliceLogic, vtkMRMLViewLogic, vtkSlicerTransformLogic, vtkSlicerApplicationLogic, vtkMRMLApplicationLogic, vtkSlicerSegmentationsModuleLogic, vtkMRMLAbstractDisplayableManager, vtkMRMLMarkupsDisplayableManager, vtkSlicerSceneViewsModuleLogic, vtkMRMLModelDisplayableManager, vtkSlicerSubjectHierarchyModuleLogic, vtkMRMLViewLinkLogic, vtkSlicerPlotsLogic, vtkSlicerSequencesLogic, vtkMRMLAnnotationDisplayableManager, vtkSlicerReformatLogic, vtkSlicerUnitsLogic, vtkSlicerCLIModuleLogic, vtkSlicerTablesLogic, vtkMRMLLinearTransformsDisplayableManager3D, vtkMRMLAbstractSliceViewDisplayableManager, vtkMRMLSliceLinkLogic, vtkSlicerCamerasModuleLogic, vtkSlicerViewControllersLogic, vtkMRMLViewDisplayableManager, vtkSlicerTerminologiesModuleLogic, vtkMRMLSegmentationsDisplayableManager2D, vtkMRMLVolumeRenderingDisplayableManager, vtkMRMLAbstractThreeDViewDisplayableManager, vtkMRMLModelSliceDisplayableManager, vtkSlicerModelsLogic, vtkMRMLSegmentationsDisplayableManager3D, vtkSlicerTextsLogic, vtkMRMLTransformsDisplayableManager2D, vtkMRMLTransformsDisplayableManager3D, vtkMRMLCrosshairDisplayableManager, vtkMRMLScalarBarDisplayableManager, vtkSlicerDataModuleLogic, vtkMRMLCameraDisplayableManager, vtkMRMLVolumeGlyphSliceDisplayableManager, vtkMRMLColorLogic, vtkMRMLAnnotationRulerDisplayableManager, vtkSlicerScriptedLoadableModuleLogic, vtkMRMLLightBoxRendererManagerProxy, vtkMRMLOrientationMarkerDisplayableManager, vtkMRMLRulerDisplayableManager, vtkMRMLThreeDReformatDisplayableManager, vtkMRMLDisplayableHierarchyLogic, vtkMRMLRemoteIOLogic, vtkMRMLAnnotationFiducialDisplayableManager, vtkMRMLColorLegendDisplayableManager, vtkMRMLAnnotationROIDisplayableManager, vtkMRMLCrosshairDisplayableManager3D, vtkMRMLScriptedDisplayableManager, vtkSlicerColorLogic, vtkSlicerAnnotationModuleLogic, vtkDataIOManagerLogic, and vtkSlicerModuleLogic.

◆ GetDisableModifiedEvent()

bool vtkMRMLAbstractLogic::GetDisableModifiedEvent ( ) const
protected

◆ GetInMRMLLogicsCallbackFlag()

int vtkMRMLAbstractLogic::GetInMRMLLogicsCallbackFlag ( ) const
protected

Return 0 when not processing any MRML logic event, >0 otherwise. Values can be higher than 1 when receiving nested events: processing a MRML logic event fires other node events.

See also
SetMRMLLogicsCallbackFlag()

◆ GetInMRMLNodesCallbackFlag()

int vtkMRMLAbstractLogic::GetInMRMLNodesCallbackFlag ( ) const
protected

Return 0 when not processing any MRML node event, >0 otherwise. Values can be higher than 1 when receiving nested events: processing a MRML node event fires other node events.

See also
SetMRMLNodesCallbackFlag()

◆ GetInMRMLSceneCallbackFlag()

int vtkMRMLAbstractLogic::GetInMRMLSceneCallbackFlag ( ) const
protected

Return 0 when not processing a MRML scene event, >0 otherwise. Values can be higher than 1 when receiving nested event: processing a MRML scene event fires other scene events.

See also
SetInMRMLCallbackFlag()

◆ GetMRMLApplicationLogic()

virtual vtkMRMLApplicationLogic* vtkMRMLAbstractLogic::GetMRMLApplicationLogic ( ) const
virtual

Get access to overall application state.

◆ GetMRMLLogicsCallbackCommand()

vtkCallbackCommand* vtkMRMLAbstractLogic::GetMRMLLogicsCallbackCommand ( )
protected

Get the MRML Logic callback command.

See also
GetMRMLSceneCallbackCommand(), GetMRMLNodesCallbackCommand()

◆ GetMRMLLogicsObserverManager()

vtkObserverManager* vtkMRMLAbstractLogic::GetMRMLLogicsObserverManager ( ) const
protected

Get MRML logics observerManager. It points to the logics callback.

See also
GetMRMLLogicsCallbackCommand()

◆ GetMRMLNodesCallbackCommand()

vtkCallbackCommand* vtkMRMLAbstractLogic::GetMRMLNodesCallbackCommand ( )
protected

Get the MRML nodes callbackCommand. The Execute function associated the the callback calls ProcessMRMLNodesEvents. Only vtkMRMLNodes can be listened to.

See also
ProcessMRMLNodesEvents()

◆ GetMRMLNodesObserverManager()

vtkObserverManager* vtkMRMLAbstractLogic::GetMRMLNodesObserverManager ( ) const
protected

Get MRML nodes observerManager. It points to the nodes callback.

See also
GetMRMLNodesCallbackCommand()

◆ GetMRMLScene()

vtkMRMLScene* vtkMRMLAbstractLogic::GetMRMLScene ( ) const

Return a reference to the current MRML scene.

◆ GetMRMLSceneCallbackCommand()

vtkCallbackCommand* vtkMRMLAbstractLogic::GetMRMLSceneCallbackCommand ( )
protected

Get MRML scene callbackCommand. You shouldn't have to use it manually, reimplementing SetMRMLSceneInternal and setting the events to listen should be enough.

See also
SetMRMLSceneInternal()

◆ GetMRMLSceneObserverManager()

vtkObserverManager* vtkMRMLAbstractLogic::GetMRMLSceneObserverManager ( ) const
protected

Get MRML scene observerManager. It points to the scene callback.

See also
GetMRMLSceneCallbackCommand()

◆ GetPendingModifiedEventCount()

int vtkMRMLAbstractLogic::GetPendingModifiedEventCount ( ) const
protected

◆ GetProcessingMRMLSceneEvent()

int vtkMRMLAbstractLogic::GetProcessingMRMLSceneEvent ( ) const
protected

Return the event id currently processed or 0 if any.

◆ InvokePendingModifiedEvent()

int vtkMRMLAbstractLogic::InvokePendingModifiedEvent ( )
protected

Invokes any modified events that are 'pending', meaning they were generated while the DisableModifiedEvent flag was nonzero.

◆ IsA()

virtual int vtkMRMLAbstractLogic::IsA ( const char *  type)
virtual

Reimplemented in vtkMRMLLayoutLogic, vtkSlicerCropVolumeLogic, vtkSlicerVolumesLogic, vtkSlicerMarkupsLogic, vtkMRMLSliceLayerLogic, vtkSlicerVolumeRenderingLogic, vtkMRMLSliceLogic, vtkMRMLViewLogic, vtkSlicerTransformLogic, vtkSlicerApplicationLogic, vtkMRMLApplicationLogic, vtkSlicerSegmentationsModuleLogic, vtkMRMLAbstractDisplayableManager, vtkMRMLMarkupsDisplayableManager, vtkSlicerSceneViewsModuleLogic, vtkMRMLModelDisplayableManager, vtkSlicerSubjectHierarchyModuleLogic, vtkMRMLViewLinkLogic, vtkSlicerPlotsLogic, vtkSlicerSequencesLogic, vtkMRMLAnnotationDisplayableManager, vtkSlicerReformatLogic, vtkSlicerUnitsLogic, vtkSlicerCLIModuleLogic, vtkSlicerTablesLogic, vtkMRMLLinearTransformsDisplayableManager3D, vtkMRMLAbstractSliceViewDisplayableManager, vtkMRMLSliceLinkLogic, vtkSlicerCamerasModuleLogic, vtkSlicerViewControllersLogic, vtkMRMLViewDisplayableManager, vtkSlicerTerminologiesModuleLogic, vtkMRMLSegmentationsDisplayableManager2D, vtkMRMLVolumeRenderingDisplayableManager, vtkMRMLAbstractThreeDViewDisplayableManager, vtkMRMLModelSliceDisplayableManager, vtkSlicerModelsLogic, vtkMRMLSegmentationsDisplayableManager3D, vtkSlicerTextsLogic, vtkMRMLTransformsDisplayableManager2D, vtkMRMLTransformsDisplayableManager3D, vtkMRMLCrosshairDisplayableManager, vtkMRMLScalarBarDisplayableManager, vtkSlicerDataModuleLogic, vtkMRMLCameraDisplayableManager, vtkMRMLVolumeGlyphSliceDisplayableManager, vtkMRMLColorLogic, vtkMRMLAnnotationRulerDisplayableManager, vtkSlicerScriptedLoadableModuleLogic, vtkMRMLLightBoxRendererManagerProxy, vtkMRMLOrientationMarkerDisplayableManager, vtkMRMLRulerDisplayableManager, vtkMRMLThreeDReformatDisplayableManager, vtkMRMLDisplayableHierarchyLogic, vtkMRMLRemoteIOLogic, vtkMRMLAnnotationFiducialDisplayableManager, vtkMRMLColorLegendDisplayableManager, vtkMRMLAnnotationROIDisplayableManager, vtkMRMLCrosshairDisplayableManager3D, vtkMRMLScriptedDisplayableManager, vtkSlicerColorLogic, vtkSlicerAnnotationModuleLogic, vtkDataIOManagerLogic, and vtkSlicerModuleLogic.

◆ IsTypeOf()

static int vtkMRMLAbstractLogic::IsTypeOf ( const char *  type)
static

◆ Modified()

void vtkMRMLAbstractLogic::Modified ( )
overrideprotected

overrides the vtkObject method so that all changes to the node which would normally generate a ModifiedEvent can be grouped into an 'atomic' operation. Typical usage would be to disable modified events, call a series of Set* operations, and then re-enable modified events and call InvokePendingModifiedEvent to invoke the event (if any of the Set* calls actually changed the values of the instance variables).

◆ MRMLLogicsCallback()

static void vtkMRMLAbstractLogic::MRMLLogicsCallback ( vtkObject *  caller,
unsigned long  eid,
void *  clientData,
void *  callData 
)
staticprotected

MRMLLogicCallback is a static function to relay modified events from the logics.

◆ MRMLNodesCallback()

static void vtkMRMLAbstractLogic::MRMLNodesCallback ( vtkObject *  caller,
unsigned long  eid,
void *  clientData,
void *  callData 
)
staticprotected

MRMLNodesCallback is a static function to relay modified events from the nodes.

◆ MRMLSceneCallback()

static void vtkMRMLAbstractLogic::MRMLSceneCallback ( vtkObject *  caller,
unsigned long  eid,
void *  clientData,
void *  callData 
)
staticprotected

MRMLSceneCallback is a static function to relay modified events from the MRML Scene In subclass, MRMLSceneCallback can also be used to relay event from observe MRML node(s)

◆ New()

static vtkMRMLAbstractLogic* vtkMRMLAbstractLogic::New ( )
static

◆ ObserveMRMLScene()

virtual void vtkMRMLAbstractLogic::ObserveMRMLScene ( )
protectedvirtual

Called after a scene is set to the logic and nodes are registered (RegisterNodes()). The scene events to observe are already set in SetMRMLSceneInternal(). By default, ObserveMRMLScene() calls UpdateFromMRMLScene(). Override for a custom behavior.

See also
SetMRMLSceneInternal, RegisterNodes, UnobserveMRMLScene
UpdateFromMRMLScene

Reimplemented in vtkSlicerMarkupsLogic, vtkSlicerVolumeRenderingLogic, vtkSlicerAnnotationModuleLogic, vtkSlicerUnitsLogic, and vtkSlicerModelsLogic.

◆ OnMRMLNodeModified()

virtual void vtkMRMLAbstractLogic::OnMRMLNodeModified ( vtkMRMLNode )
inlineprotectedvirtual

◆ OnMRMLSceneEndBatchProcess()

virtual void vtkMRMLAbstractLogic::OnMRMLSceneEndBatchProcess ( )
protectedvirtual

◆ OnMRMLSceneEndClose()

virtual void vtkMRMLAbstractLogic::OnMRMLSceneEndClose ( )
inlineprotectedvirtual

◆ OnMRMLSceneEndImport()

virtual void vtkMRMLAbstractLogic::OnMRMLSceneEndImport ( )
inlineprotectedvirtual

◆ OnMRMLSceneEndRestore()

virtual void vtkMRMLAbstractLogic::OnMRMLSceneEndRestore ( )
inlineprotectedvirtual

◆ OnMRMLSceneNew()

virtual void vtkMRMLAbstractLogic::OnMRMLSceneNew ( )
inlineprotectedvirtual

If vtkMRMLScene::SceneNewEvent has been set to be observed in SetMRMLSceneInternal, it is called when the scene fires the event

See also
ProcessMRMLSceneEvents, SetMRMLSceneInternal
OnMRMLSceneStartImport, OnMRMLSceneEndImport

Definition at line 299 of file vtkMRMLAbstractLogic.h.

◆ OnMRMLSceneNodeAdded()

virtual void vtkMRMLAbstractLogic::OnMRMLSceneNodeAdded ( vtkMRMLNode )
inlineprotectedvirtual

◆ OnMRMLSceneNodeRemoved()

virtual void vtkMRMLAbstractLogic::OnMRMLSceneNodeRemoved ( vtkMRMLNode )
inlineprotectedvirtual

◆ OnMRMLSceneStartBatchProcess()

virtual void vtkMRMLAbstractLogic::OnMRMLSceneStartBatchProcess ( )
inlineprotectedvirtual

If vtkMRMLScene::StartBatchProcessEvent has been set to be observed in SetMRMLSceneInternal, it is called when the scene fires the event

See also
ProcessMRMLSceneEvents, SetMRMLSceneInternal
OnMRMLSceneEndBatchProcess

Reimplemented in vtkMRMLApplicationLogic, vtkSlicerUnitsLogic, and vtkMRMLSliceLinkLogic.

Definition at line 257 of file vtkMRMLAbstractLogic.h.

◆ OnMRMLSceneStartClose()

virtual void vtkMRMLAbstractLogic::OnMRMLSceneStartClose ( )
inlineprotectedvirtual

◆ OnMRMLSceneStartImport()

virtual void vtkMRMLAbstractLogic::OnMRMLSceneStartImport ( )
inlineprotectedvirtual

If vtkMRMLScene::StartImportEvent has been set to be observed in SetMRMLSceneInternal, it is called when the scene fires the event

See also
ProcessMRMLSceneEvents, SetMRMLSceneInternal
OnMRMLSceneEndImport, OnMRMLSceneNew

Reimplemented in vtkMRMLApplicationLogic, vtkMRMLCameraDisplayableManager, and vtkMRMLSliceLinkLogic.

Definition at line 279 of file vtkMRMLAbstractLogic.h.

◆ OnMRMLSceneStartRestore()

virtual void vtkMRMLAbstractLogic::OnMRMLSceneStartRestore ( )
inlineprotectedvirtual

If vtkMRMLScene::StartRestoreEvent has been set to be observed in SetMRMLSceneInternal, it is called when the scene fires the event

See also
ProcessMRMLSceneEvents, SetMRMLSceneInternal
OnMRMLSceneEndRestore

Reimplemented in vtkMRMLApplicationLogic, vtkMRMLLayoutLogic, and vtkMRMLSliceLinkLogic.

Definition at line 289 of file vtkMRMLAbstractLogic.h.

◆ PrintSelf()

void vtkMRMLAbstractLogic::PrintSelf ( ostream &  os,
vtkIndent  indent 
)
override

◆ ProcessMRMLLogicsEvents()

virtual void vtkMRMLAbstractLogic::ProcessMRMLLogicsEvents ( vtkObject *  caller,
unsigned long  event,
void *  callData 
)
protectedvirtual

Receives all the events fired by the logics. To listen to a logic, you can add an observer using GetMRMLLogicsCallbackCommand(). To be reimplemented in subclasses if needed.

See also
GetMRMLLogicsCallbackCommand() ,ProcessMRMLSceneEvents(), ProcessMRMLNodesEvents()

Reimplemented in vtkMRMLSliceLogic.

◆ ProcessMRMLNodesEvents()

virtual void vtkMRMLAbstractLogic::ProcessMRMLNodesEvents ( vtkObject *  caller,
unsigned long  event,
void *  callData 
)
protectedvirtual

◆ ProcessMRMLSceneEvents()

virtual void vtkMRMLAbstractLogic::ProcessMRMLSceneEvents ( vtkObject *  caller,
unsigned long  event,
void *  callData 
)
protectedvirtual

Receives all the events fired by the scene. By default, it calls OnMRMLScene*Event based on the event passed.

Reimplemented in vtkMRMLSliceLayerLogic, and vtkMRMLScriptedDisplayableManager.

◆ RegisterNodes()

virtual void vtkMRMLAbstractLogic::RegisterNodes ( )
inlineprotectedvirtual

Register node classes into the MRML scene. Called each time a new scene is set. Do nothing by default. Can be reimplemented in derivated classes.

Reimplemented in vtkSlicerSegmentationsModuleLogic, vtkSlicerMarkupsLogic, vtkSlicerVolumeRenderingLogic, vtkSlicerUnitsLogic, vtkSlicerSequencesLogic, vtkSlicerCropVolumeLogic, vtkSlicerColorLogic, vtkSlicerViewControllersLogic, vtkSlicerAnnotationModuleLogic, vtkSlicerSceneViewsModuleLogic, and vtkSlicerDataModuleLogic.

Definition at line 347 of file vtkMRMLAbstractLogic.h.

◆ SafeDownCast()

static vtkMRMLAbstractLogic* vtkMRMLAbstractLogic::SafeDownCast ( vtkObject *  o)
static

◆ SetAndObserveMRMLSceneEventsInternal()

void vtkMRMLAbstractLogic::SetAndObserveMRMLSceneEventsInternal ( vtkMRMLScene newScene,
vtkIntArray *  events,
vtkFloatArray *  priorities = nullptr 
)
protected

Typically called by a subclass in the derived SetMRMLSceneInternal to observe specific node events.

void vtkMRMLMyLogic::SetMRMLSceneInternal(vtkMRMLScene* newScene)
{
vtkNew<vtkIntArray> events;
events->InsertNextValue(vtkMRMLScene::NodeAddedEvent);
events->InsertNextValue(vtkMRMLScene::NodeRemovedEvent);
this->SetAndObserveMRMLSceneEventsInternal(newScene, events);
}
See also
SetMRMLSceneInternal()

◆ SetDisableModifiedEvent()

void vtkMRMLAbstractLogic::SetDisableModifiedEvent ( bool  onOff)
protected

◆ SetInMRMLLogicsCallbackFlag()

void vtkMRMLAbstractLogic::SetInMRMLLogicsCallbackFlag ( int  flag)
protected

Set InMRMLLogicsCallback flag. In InMRMLLogicsCallback, loop are avoided by checking the value of the flag.

See also
EnterMRMLLogicsCallback()

◆ SetInMRMLNodesCallbackFlag()

void vtkMRMLAbstractLogic::SetInMRMLNodesCallbackFlag ( int  flag)
protected

Set InMRMLNodesCallback flag. In InMRMLNodesCallback, loop are avoided by checking the value of the flag.

See also
EnterMRMLNodesCallback()

◆ SetInMRMLSceneCallbackFlag()

void vtkMRMLAbstractLogic::SetInMRMLSceneCallbackFlag ( int  flag)
protected

Set MRMLSceneCallback flag True means ProcessMRMLEvent has already been called In MRMLSceneCallback, loop are avoided by checking the value of the flag

See also
EnterMRMLSceneCallback()

◆ SetMRMLApplicationLogic()

virtual void vtkMRMLAbstractLogic::SetMRMLApplicationLogic ( vtkMRMLApplicationLogic logic)
virtual

Reimplemented in vtkSlicerCLIModuleLogic.

◆ SetMRMLScene()

void vtkMRMLAbstractLogic::SetMRMLScene ( vtkMRMLScene newScene)

Set and observe the MRMLScene.

◆ SetMRMLSceneInternal()

virtual void vtkMRMLAbstractLogic::SetMRMLSceneInternal ( vtkMRMLScene newScene)
protectedvirtual

◆ SetProcessingMRMLSceneEvent()

void vtkMRMLAbstractLogic::SetProcessingMRMLSceneEvent ( int  event)
protected

Set event id currently processed or 0 if any.

See also
EnterMRMLSceneCallback()

◆ StartModify()

bool vtkMRMLAbstractLogic::StartModify ( )
inlineprotected

Start modifying the logic. Disable Modify events. Returns the previous state of DisableModifiedEvent flag that should be passed to EndModify() method

Definition at line 449 of file vtkMRMLAbstractLogic.h.

◆ UnobserveMRMLScene()

virtual void vtkMRMLAbstractLogic::UnobserveMRMLScene ( )
protectedvirtual

◆ UpdateFromMRMLScene()

virtual void vtkMRMLAbstractLogic::UpdateFromMRMLScene ( )
protectedvirtual

Called every time the scene has been significantly changed. If the scene BatchProcessState events are observed (in SetMRMLSceneInternal() ), UpdateFromMRMLScene is called after each batch process (Close, Import, Restore...). It is also being called by default when a new scene is set (SetMRMLScene).

See also
SetMRMLSceneInternal, UnobserveMRMLScene, ObserveMRMLScene

Reimplemented in vtkSlicerMarkupsLogic, vtkMRMLSliceLogic, vtkMRMLLayoutLogic, vtkSlicerUnitsLogic, vtkMRMLAnnotationDisplayableManager, vtkMRMLModelDisplayableManager, vtkSlicerSequencesLogic, vtkMRMLViewLogic, vtkSlicerSubjectHierarchyModuleLogic, vtkMRMLMarkupsDisplayableManager, vtkMRMLColorLegendDisplayableManager, vtkSlicerDataModuleLogic, vtkMRMLThreeDReformatDisplayableManager, and vtkMRMLVolumeGlyphSliceDisplayableManager.


The documentation for this class was generated from the following file: