Synergy Color Management Component - SDK -  2018.0.80
SYNCOLOR::SynStatus Class Reference

SynColor SDK error status reporting class. More...

Public Member Functions

 SynStatus ()
 Constructor. More...
 
virtual ~SynStatus ()
 Destructor. More...
 
 SynStatus (const SynStatus &rhs)
 Copy constructor. More...
 
SynStatusoperator= (const SynStatus &rhs)
 Assignment operator. More...
 
SYNCOLOR::ErrorId getErrorCode () const
 Error ID. More...
 
void setErrorCode (SYNCOLOR::ErrorId ID)
 Set the error ID. More...
 
const char * getErrorMessage () const
 Get the error message string. More...
 
void setErrorMessage (const char *msg)
 Set the error message. More...
 
 operator bool () const
 Boolean operator where true means no error. More...
 

Protected Attributes

char * _errMsg
 Error message string. More...
 
SYNCOLOR::ErrorId _errCode
 Error ID. More...
 

Detailed Description

SynColor SDK error status reporting class.

The SYNCOLOR::SynStatus class is composed of an error ID and a message string. A error ID other SYNCOLOR::ERROR_NONE indicates an error condition. See synColor/errorIds.h for the complete list. The error message strings contain useful contextual information. They are designed for user notifications posted in application interfaces. The error message strings are available for each of the SYNCOLOR::Language defined.

Constructor & Destructor Documentation

SYNCOLOR::SynStatus::SynStatus ( )

Constructor.

virtual SYNCOLOR::SynStatus::~SynStatus ( )
virtual

Destructor.

SYNCOLOR::SynStatus::SynStatus ( const SynStatus rhs)

Copy constructor.

Parameters
rhsInstance to copy.

Member Function Documentation

SynStatus& SYNCOLOR::SynStatus::operator= ( const SynStatus rhs)

Assignment operator.

Parameters
rhsInstance to copy.
Returns
Reference to itself.
SYNCOLOR::ErrorId SYNCOLOR::SynStatus::getErrorCode ( ) const

Error ID.

Returns
The error ID. //!
void SYNCOLOR::SynStatus::setErrorCode ( SYNCOLOR::ErrorId  ID)

Set the error ID.

Parameters
IDError ID to assign.
const char* SYNCOLOR::SynStatus::getErrorMessage ( ) const

Get the error message string.

SynColor error message strings contain useful contextual information. These messages are designed for user notifications posted in application interfaces.

Note
The error message string is in the language specified by SYNCOLOR::getErrorMessageLanguage.
The returned pointer is null when the instance is not an error. In this case the error ID is SYNCOLOR::ERROR_NONE.
See also
SYNCOLOR::getErrorMessageLanguage(), SYNCOLOR::setErrorMessageLanguage()
Returns
The error message string corresponding to the error ID.
void SYNCOLOR::SynStatus::setErrorMessage ( const char *  msg)

Set the error message.

Parameters
msgMessage string to assign.
SYNCOLOR::SynStatus::operator bool ( ) const

Boolean operator where true means no error.

Returns
return True if the status is SYNCOLOR::ERROR_NONE.

Member Data Documentation

char* SYNCOLOR::SynStatus::_errMsg
protected

Error message string.

NULL if the ID is SYNCOLOR::ERROR_NONE.

SYNCOLOR::ErrorId SYNCOLOR::SynStatus::_errCode
protected

Error ID.