Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitk::LineOperation Class Reference

Operation that holds everything necessary for an operation on a line. More...

#include <mitkLineOperation.h>

Inheritance diagram for mitk::LineOperation:
Collaboration diagram for mitk::LineOperation:

Public Member Functions

 mitkClassMacro (LineOperation, CellOperation)
 
 LineOperation (OperationType operationType, int cellId, Vector3D vector, int pIdA=-1, int pIdB=-1, int id=-1)
 Construct a LineOperation with a displacement vector. More...
 
 LineOperation (OperationType operationType, int cellId=-1, int pIdA=-1, int pIdB=-1, int id=-1)
 Construct a LineOperation without a displacement vector. More...
 
 ~LineOperation () override
 
int GetPIdA ()
 Get the first endpoint ID. More...
 
int GetPIdB ()
 Get the second endpoint ID. More...
 
int GetId ()
 Get the line ID within the cell. More...
 
- Public Member Functions inherited from mitk::CellOperation
 mitkClassMacro (CellOperation, Operation)
 
 CellOperation (OperationType operationType, int cellId, Vector3D vector)
 Construct a CellOperation with a displacement vector. More...
 
 CellOperation (OperationType operationType, int cellId)
 Construct a CellOperation without a displacement vector. More...
 
 ~CellOperation () override
 
int GetCellId ()
 Get the cell identifier. More...
 
Vector3D GetVector ()
 Get the displacement vector. More...
 
- Public Member Functions inherited from mitk::Operation
 mitkClassMacroNoParent (Operation) virtual bool IsValid() const
 Check whether this operation is still valid and can be executed. More...
 
virtual ~Operation ()=default
 Virtual destructor. More...
 
OperationType GetOperationType ()
 Get the type identifier of this operation. More...
 

Protected Attributes

int m_PIdA
 
int m_PIdB
 
int m_Id
 
- Protected Attributes inherited from mitk::CellOperation
int m_CellId
 
Vector3D m_Vector
 
- Protected Attributes inherited from mitk::Operation
OperationType m_OperationType
 The type identifier for this operation. More...
 

Additional Inherited Members

- Protected Member Functions inherited from mitk::Operation
 Operation (OperationType operationType)
 Construct an operation with the given type. More...
 
 Operation (const Operation &)=default
 
 Operation (Operation &&)=default
 
Operation & operator= (const Operation &)=default
 
Operation & operator= (Operation &&)=default
 

Detailed Description

Operation that holds everything necessary for an operation on a line.

Stores operation type, cell ID, two endpoint IDs, an optional line ID, and a displacement vector. Used for selecting, inserting, moving, and removing lines within cells.

See also
CellOperation, Operation

Definition at line 32 of file mitkLineOperation.h.

Constructor & Destructor Documentation

◆ LineOperation() [1/2]

mitk::LineOperation::LineOperation ( OperationType  operationType,
int  cellId,
Vector3D  vector,
int  pIdA = -1,
int  pIdB = -1,
int  id = -1 
)

Construct a LineOperation with a displacement vector.

Parameters
[in]operationTypeThe type of operation (e.g. move, add).
[in]cellIdThe cell identifier.
[in]vectorThe displacement vector.
[in]pIdAFirst endpoint ID (default -1 = unset).
[in]pIdBSecond endpoint ID (default -1 = unset).
[in]idThe line ID within the cell (default -1 = unset).

◆ LineOperation() [2/2]

mitk::LineOperation::LineOperation ( OperationType  operationType,
int  cellId = -1,
int  pIdA = -1,
int  pIdB = -1,
int  id = -1 
)

Construct a LineOperation without a displacement vector.

Parameters
[in]operationTypeThe type of operation.
[in]cellIdThe cell identifier (default -1).
[in]pIdAFirst endpoint ID (default -1).
[in]pIdBSecond endpoint ID (default -1).
[in]idThe line ID within the cell (default -1).

◆ ~LineOperation()

mitk::LineOperation::~LineOperation ( )
inlineoverride

Definition at line 60 of file mitkLineOperation.h.

Member Function Documentation

◆ GetId()

int mitk::LineOperation::GetId ( )

Get the line ID within the cell.

Returns
The line ID.

◆ GetPIdA()

int mitk::LineOperation::GetPIdA ( )

Get the first endpoint ID.

Returns
The point ID A.

◆ GetPIdB()

int mitk::LineOperation::GetPIdB ( )

Get the second endpoint ID.

Returns
The point ID B.

◆ mitkClassMacro()

mitk::LineOperation::mitkClassMacro ( LineOperation  ,
CellOperation   
)

Member Data Documentation

◆ m_Id

int mitk::LineOperation::m_Id
protected

Definition at line 84 of file mitkLineOperation.h.

◆ m_PIdA

int mitk::LineOperation::m_PIdA
protected

Definition at line 82 of file mitkLineOperation.h.

◆ m_PIdB

int mitk::LineOperation::m_PIdB
protected

Definition at line 83 of file mitkLineOperation.h.


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