Hoyt's FORK of DemoIccMAX 2.1.17.hoyt
Documentation for Hoyt's FORK of DemoIccMAX
Loading...
Searching...
No Matches
CIccCfgDataEntry Class Reference

#include <IccCmmConfig.h>

+ Collaboration diagram for CIccCfgDataEntry:

Public Member Functions

 CIccCfgDataEntry ()
 
bool fromJson (json obj, bool bReset=false)
 
void reset ()
 
void toJson (json &obj)
 
virtual ~CIccCfgDataEntry ()
 

Public Attributes

std::list< std::string > m_debugInfo
 
int m_index
 
std::string m_label
 
std::string m_name
 
std::string m_srcName
 
std::vector< icFloatNumberm_srcValues
 
std::vector< icFloatNumberm_values
 

Detailed Description

Definition at line 141 of file IccCmmConfig.h.

Constructor & Destructor Documentation

◆ CIccCfgDataEntry()

CIccCfgDataEntry::CIccCfgDataEntry ( )

Definition at line 1767 of file IccCmmConfig.cpp.

1768{
1769 reset();
1770}
void reset()

References reset().

+ Here is the call graph for this function:

◆ ~CIccCfgDataEntry()

virtual CIccCfgDataEntry::~CIccCfgDataEntry ( )
inlinevirtual

Definition at line 145 of file IccCmmConfig.h.

145{}

Member Function Documentation

◆ fromJson()

bool CIccCfgDataEntry::fromJson ( json obj,
bool bReset = false )

Definition at line 1783 of file IccCmmConfig.cpp.

1784{
1785 if (!j.is_object())
1786 return false;
1787
1788 if (bReset)
1789 reset();
1790
1791 jsonToValue(j["n"], m_name);
1792 jsonToArray(j["v"], m_values);
1793
1794 jsonToValue(j["sn"], m_srcName);
1795 jsonToArray(j["sv"], m_srcValues);
1796
1797 jsonToValue(j["i"], m_index);
1798 jsonToValue(j["l"], m_label);
1799
1800 jsonToList(j["d"], m_debugInfo);
1801
1802 return true;
1803}
bool jsonToValue(const json &j, icFloatColorEncoding &v)
bool jsonToArray(const json &v, T *vals, int n)
bool jsonToList(const json &v, std::list< std::string > &vals)
std::vector< icFloatNumber > m_srcValues
std::string m_srcName
int m_index
std::string m_label
std::vector< icFloatNumber > m_values
std::list< std::string > m_debugInfo
std::string m_name

References jsonToArray(), jsonToList(), jsonToValue(), m_debugInfo, m_index, m_label, m_name, m_srcName, m_srcValues, m_values, and reset().

+ Here is the call graph for this function:

◆ reset()

void CIccCfgDataEntry::reset ( )

Definition at line 1772 of file IccCmmConfig.cpp.

1773{
1774 m_name.clear();
1775 m_values.clear();
1776 m_srcName.clear();
1777 m_srcValues.clear();
1778 m_index = -1;
1779 m_label.clear();
1780 m_debugInfo.clear();
1781}

References m_debugInfo, m_index, m_label, m_name, m_srcName, m_srcValues, and m_values.

Referenced by CIccCfgDataEntry(), fromJson(), and main().

+ Here is the caller graph for this function:

◆ toJson()

void CIccCfgDataEntry::toJson ( json & obj)

Definition at line 1805 of file IccCmmConfig.cpp.

1806{
1807 if (m_name.size())
1808 obj["n"] = m_name;
1809 if (m_values.size())
1810 obj["v"] = m_values;
1811
1812 if (m_srcName.size())
1813 obj["sn"] = m_srcName;
1814 if (m_srcValues.size())
1815 obj["sv"] = m_srcValues;
1816
1817 if (m_label.size())
1818 obj["l"] = m_label;
1819
1820 if (m_index >= 0)
1821 obj["i"] = m_index;
1822
1823 if (m_debugInfo.size())
1824 obj["d"] = m_debugInfo;
1825}

References m_debugInfo, m_index, m_label, m_name, m_srcName, m_srcValues, and m_values.

Referenced by CIccCfgColorData::toJson().

+ Here is the caller graph for this function:

Member Data Documentation

◆ m_debugInfo

std::list<std::string> CIccCfgDataEntry::m_debugInfo

Definition at line 157 of file IccCmmConfig.h.

Referenced by fromJson(), reset(), toJson(), and CIccCfgColorData::toLegacy().

◆ m_index

int CIccCfgDataEntry::m_index

Definition at line 155 of file IccCmmConfig.h.

Referenced by fromJson(), reset(), CIccCfgColorData::toIt8(), and toJson().

◆ m_label

std::string CIccCfgDataEntry::m_label

Definition at line 156 of file IccCmmConfig.h.

Referenced by fromJson(), reset(), CIccCfgColorData::toIt8(), and toJson().

◆ m_name

std::string CIccCfgDataEntry::m_name

◆ m_srcName

std::string CIccCfgDataEntry::m_srcName

◆ m_srcValues

std::vector<icFloatNumber> CIccCfgDataEntry::m_srcValues

◆ m_values

std::vector<icFloatNumber> CIccCfgDataEntry::m_values

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