SVGConfig Class Reference

MathVizAnimator: SVGConfig Class Reference
MathVizAnimator  0.0.1

The SVGConfig class manages the configuration related to SVG files. More...

#include <svg_config.h>

Public Member Functions

void setSVGDir (const QDir &svg_dir)
 Sets the directory for SVG files. More...
 
QDir svgDir ()
 Returns the directory where SVG files are stored. More...
 

Static Public Member Functions

static SVGConfiggetInstance ()
 Returns the singleton instance of SVGConfig. More...
 
static QString hash (const QString &text)
 Generates a hash value for the given text using MD5 algorithm. More...
 

Detailed Description

The SVGConfig class manages the configuration related to SVG files.

This class provides functionalities to set and retrieve the directory where SVG files are stored, as well as a method to generate a hash value for a given text. It is created as a Singleton class so that the directory for the SVG files, as well as the used hash algorithm are the same through the whole library/application. You cannot create an Object of this class, but you can get an Instance of it through the function SVGConfig::getInstance().

Member Function Documentation

◆ getInstance()

static SVGConfig& SVGConfig::getInstance ( )
inlinestatic

Returns the singleton instance of SVGConfig.

Returns
Reference to the singleton instance of SVGConfig.

◆ hash()

static QString SVGConfig::hash ( const QString &  text)
inlinestatic

Generates a hash value for the given text using MD5 algorithm.

Parameters
textThe text for which the hash value will be generated.
Returns
The hash value generated for the text.

◆ setSVGDir()

void SVGConfig::setSVGDir ( const QDir &  svg_dir)
inline

Sets the directory for SVG files.

Parameters
svg_dirThe directory where SVG files will be stored.

◆ svgDir()

QDir SVGConfig::svgDir ( )
inline

Returns the directory where SVG files are stored.

Returns
The directory where SVG files are stored.

The documentation for this class was generated from the following file:
  • /home/docs/checkouts/readthedocs.org/user_builds/mathvizanimator/checkouts/latest/libs/mva_svg/include/svg_config.h