MeVisLab Toolbox Reference
ml::ImagePropertyExtension Class Referenceabstract

#include <mlImagePropertyExtension.h>

Inheritance diagram for ml::ImagePropertyExtension:
ml::DicomTreeImagePropertyExtension

Public Member Functions

 ImagePropertyExtension ()
 Default constructor; does nothing.
virtual ~ImagePropertyExtension ()
 Destructor.
virtual bool equals (const ImagePropertyExtension &extImageProps) const =0
virtual ImagePropertyExtensioncreateClone () const =0
virtual std::string getValueAsString () const =0
virtual void getValueAsString (std::string &valAsString) const
virtual MLErrorCode setValueFromString (const std::string &stringValue)=0
virtual bool operator== (const ImagePropertyExtension &extImageProps) const
 Implements the equality operator based on the equals method.
virtual bool operator!= (const ImagePropertyExtension &extImageProps) const
 Implements the inequality operator based on the equals method.

Detailed Description

Base class from which one can derive own image properties. Note that this class must implement cloning and stream outputs.

Definition at line 36 of file mlImagePropertyExtension.h.

Constructor & Destructor Documentation

◆ ImagePropertyExtension()

ml::ImagePropertyExtension::ImagePropertyExtension ( )
inline

◆ ~ImagePropertyExtension()

virtual ml::ImagePropertyExtension::~ImagePropertyExtension ( )
inlinevirtual

Destructor.

Definition at line 46 of file mlImagePropertyExtension.h.

Member Function Documentation

◆ createClone()

virtual ImagePropertyExtension * ml::ImagePropertyExtension::createClone ( ) const
pure virtual

Pure virtual method that must return a copy of the current object. It must be implemented because applications need to get copies from objects that are only managed via base class pointers.

Implemented in ml::DicomTreeImagePropertyExtension.

References ImagePropertyExtension().

◆ equals()

virtual bool ml::ImagePropertyExtension::equals ( const ImagePropertyExtension & extImageProps) const
pure virtual

Returns true if this object equals extImageProps. This method needs to be overridden by derived classes. In the overrridden method, extImageProps is typically cast to a pointer to the derived class after checking its runtime type.

Implemented in ml::DicomTreeImagePropertyExtension.

References ImagePropertyExtension().

◆ getValueAsString() [1/2]

virtual std::string ml::ImagePropertyExtension::getValueAsString ( ) const
pure virtual

Returns the value of the object as string. Must be implemented, for example, because file formats need to store / load the state of a ImagePropertyExtension instance on/from disk.

Implemented in ml::DicomTreeImagePropertyExtension.

◆ getValueAsString() [2/2]

virtual void ml::ImagePropertyExtension::getValueAsString ( std::string & valAsString) const
virtual

Returns the value of the object as string in valAsString. The default implementation uses getValueAsString() const. However, it can be reimplemented in derived classes to improve performance.

Reimplemented in ml::DicomTreeImagePropertyExtension.

◆ operator!=()

virtual bool ml::ImagePropertyExtension::operator!= ( const ImagePropertyExtension & extImageProps) const
virtual

Implements the inequality operator based on the equals method.

References ImagePropertyExtension().

◆ operator==()

virtual bool ml::ImagePropertyExtension::operator== ( const ImagePropertyExtension & extImageProps) const
virtual

Implements the equality operator based on the equals method.

References ImagePropertyExtension().

◆ setValueFromString()

virtual MLErrorCode ml::ImagePropertyExtension::setValueFromString ( const std::string & stringValue)
pure virtual

Sets the value of a property from the string stringValue and returns ML_RESULT_OK on success or another MLErrorCode on failure.

Implemented in ml::DicomTreeImagePropertyExtension.


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