Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitk::PropertyKeyPath::NodeInfo Struct Reference

Information about a single node in a PropertyKeyPath. More...

#include <mitkPropertyKeyPath.h>

Collaboration diagram for mitk::PropertyKeyPath::NodeInfo:

Public Types

enum class  NodeType {
  Invalid , Element , ElementSelection , AnySelection ,
  AnyElement
}
 Types of nodes within a PropertyKeyPath. More...
 

Public Member Functions

 NodeInfo ()
 Default constructor. Creates an Invalid node. More...
 
 NodeInfo (const ElementNameType &name, NodeType type=NodeType::Element, ItemSelectionIndex index=0)
 Construct a node with given name, type, and selection index. More...
 
bool Matches (const NodeInfo &right) const
 Check if this node matches another, respecting wildcards. More...
 
bool operator== (const NodeInfo &right) const
 Check for exact equality (same type, name, and selection). More...
 

Public Attributes

NodeType type
 The type of this node. More...
 
ElementNameType name
 The element name for this node (empty for AnyElement). More...
 
ItemSelectionIndex selection
 The selection index for ElementSelection nodes. More...
 

Detailed Description

Information about a single node in a PropertyKeyPath.

Each node has a type, an optional name, and an optional selection index.

Definition at line 65 of file mitkPropertyKeyPath.h.

Member Enumeration Documentation

◆ NodeType

Types of nodes within a PropertyKeyPath.

Enumerator
Invalid 

Node does not exist or is invalid.

Element 

Selects a specific element given the node name.

ElementSelection 

Selects a specific item in a sequence by index ("[n]").

AnySelection 

Selects all items of a specific element ("[*]").

AnyElement 

Selects any element/item. Node name is wildcarded ("*"); item selection as well implicitly.

Definition at line 68 of file mitkPropertyKeyPath.h.

Constructor & Destructor Documentation

◆ NodeInfo() [1/2]

mitk::PropertyKeyPath::NodeInfo::NodeInfo ( )

Default constructor. Creates an Invalid node.

◆ NodeInfo() [2/2]

mitk::PropertyKeyPath::NodeInfo::NodeInfo ( const ElementNameType &  name,
NodeType  type = NodeType::Element,
ItemSelectionIndex  index = 0 
)

Construct a node with given name, type, and selection index.

Parameters
[in]nameThe element name.
[in]typeThe node type (default: Element).
[in]indexThe selection index (default: 0).

Member Function Documentation

◆ Matches()

bool mitk::PropertyKeyPath::NodeInfo::Matches ( const NodeInfo &  right) const

Check if this node matches another, respecting wildcards.

AnyElement matches any other valid node. AnySelection matches any selection index of the same element name.

Parameters
[in]rightThe node to match against.
Returns
true if the nodes match.

◆ operator==()

bool mitk::PropertyKeyPath::NodeInfo::operator== ( const NodeInfo &  right) const

Check for exact equality (same type, name, and selection).

Parameters
[in]rightThe node to compare against.
Returns
true if both nodes are identical.

Member Data Documentation

◆ name

ElementNameType mitk::PropertyKeyPath::NodeInfo::name

The element name for this node (empty for AnyElement).

Definition at line 81 of file mitkPropertyKeyPath.h.

◆ selection

ItemSelectionIndex mitk::PropertyKeyPath::NodeInfo::selection

The selection index for ElementSelection nodes.

Definition at line 84 of file mitkPropertyKeyPath.h.

◆ type

NodeType mitk::PropertyKeyPath::NodeInfo::type

The type of this node.

Definition at line 78 of file mitkPropertyKeyPath.h.


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