Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitk::PropertyFilter Struct Reference

Consists of blacklist and whitelist entries. More...

#include <mitkPropertyFilter.h>

Collaboration diagram for mitk::PropertyFilter:

Public Types

enum  List { Blacklist , Whitelist }
 Specifies the type of a filter entry. More...
 

Public Member Functions

 PropertyFilter ()
 
 ~PropertyFilter ()
 
 PropertyFilter (const PropertyFilter &other)
 
PropertyFilter & operator= (PropertyFilter other)
 
void AddEntry (const std::string &propertyName, List list)
 Add a filter entry for a specific property. More...
 
std::map< std::string, BaseProperty::Pointer > Apply (const std::map< std::string, BaseProperty::Pointer > &propertyMap) const
 Apply the filter to a property list. More...
 
bool HasEntry (const std::string &propertyName, List list) const
 Check if filter has specific entry. More...
 
bool IsEmpty () const
 Check if filter is empty. More...
 
void RemoveAllEntries (List list)
 Remove all entries from property filter. More...
 
void RemoveEntry (const std::string &propertyName, List list)
 Remove specific entry from property filter. More...
 

Public Attributes

std::string key
 The property key to filter on. More...
 
std::string value
 The value to match against (may contain wildcards). More...
 
bool negated
 If true, the filter uses != (not-equal) semantics. More...
 

Detailed Description

Consists of blacklist and whitelist entries.

A single property filter criterion with key, value, and optional negation.

Blacklist filtering is less restrictive than whitelist filtering since you can filter out individual property names. If whitelist entries were added, all other property names are filtered out. In addition, whitelist entries are reduced by blacklist entries.

Supports exact match, negation (!=), and wildcard prefix/suffix patterns. For example:

  • Exact match: filter.name=CT_Scan
  • Not equal: filter.visible!=true
  • Wildcard prefix: filter.name=CT*
  • Wildcard suffix: filter.name=*Scan
See also
NodeQueryParams

Definition at line 30 of file mitkPropertyFilter.h.

Member Enumeration Documentation

◆ List

Specifies the type of a filter entry.

Enumerator
Blacklist 

Blacklisted filter entries are filtered out.

Whitelist 

Whitelisted filter entries are the only entries that remain after filtering.

Definition at line 35 of file mitkPropertyFilter.h.

Constructor & Destructor Documentation

◆ PropertyFilter() [1/2]

mitk::PropertyFilter::PropertyFilter ( )

◆ ~PropertyFilter()

mitk::PropertyFilter::~PropertyFilter ( )

◆ PropertyFilter() [2/2]

mitk::PropertyFilter::PropertyFilter ( const PropertyFilter &  other)

Member Function Documentation

◆ AddEntry()

void mitk::PropertyFilter::AddEntry ( const std::string &  propertyName,
List  list 
)

Add a filter entry for a specific property.

Parameters
[in]propertyNameName of the property.
[in]listType of the filter entry.

◆ Apply()

std::map<std::string, BaseProperty::Pointer> mitk::PropertyFilter::Apply ( const std::map< std::string, BaseProperty::Pointer > &  propertyMap) const

Apply the filter to a property list.

Parameters
[in]propertyMapProperty list to which the filter is applied.
Returns
Filtered property list.

◆ HasEntry()

bool mitk::PropertyFilter::HasEntry ( const std::string &  propertyName,
List  list 
) const

Check if filter has specific entry.

Parameters
[in]propertyNameName of the property.
[in]listType of the filter entry.
Returns
True if property filter has specified entry, false otherwise.

◆ IsEmpty()

bool mitk::PropertyFilter::IsEmpty ( ) const

Check if filter is empty.

Returns
True if filter is empty, false otherwise.

◆ operator=()

PropertyFilter& mitk::PropertyFilter::operator= ( PropertyFilter  other)

◆ RemoveAllEntries()

void mitk::PropertyFilter::RemoveAllEntries ( List  list)

Remove all entries from property filter.

Parameters
[in]listFilter list from which all entries are removed.

◆ RemoveEntry()

void mitk::PropertyFilter::RemoveEntry ( const std::string &  propertyName,
List  list 
)

Remove specific entry from property filter.

Parameters
[in]propertyNameName of property.
[in]listFilter list from which the entry is removed.

Member Data Documentation

◆ key

std::string mitk::PropertyFilter::key

The property key to filter on.

Definition at line 68 of file mitkNodeQueryParams.h.

◆ negated

bool mitk::PropertyFilter::negated

If true, the filter uses != (not-equal) semantics.

Definition at line 70 of file mitkNodeQueryParams.h.

◆ value

std::string mitk::PropertyFilter::value

The value to match against (may contain wildcards).

Definition at line 69 of file mitkNodeQueryParams.h.


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