libCZI
Reading and Writing CZI documents made easy
libCZI::GeneralDocumentInfo Struct Reference

General document information - corresponding to Information/Document. More...

#include <libCZI_Metadata.h>

Public Member Functions

LIBCZI_API GeneralDocumentInfo ()
 Default constructor - all fields are intially marked "invalid".
 
LIBCZI_API void SetName (const wchar_t *sz)
 
LIBCZI_API void SetName (const std::wstring &str)
 
LIBCZI_API void SetTitle (const wchar_t *sz)
 
LIBCZI_API void SetTitle (const std::wstring &str)
 
LIBCZI_API void SetUserName (const wchar_t *sz)
 
LIBCZI_API void SetUserName (const std::wstring &str)
 
LIBCZI_API void SetDescription (const wchar_t *sz)
 
LIBCZI_API void SetDescription (const std::wstring &str)
 
LIBCZI_API void SetComment (const wchar_t *sz)
 
LIBCZI_API void SetComment (const std::wstring &str)
 
LIBCZI_API void SetKeywords (const wchar_t *sz)
 
LIBCZI_API void SetKeywords (const std::wstring &str)
 
LIBCZI_API void SetRating (int rating)
 
LIBCZI_API void SetCreationDate (const wchar_t *sz)
 
LIBCZI_API void SetCreationDate (const std::wstring &str)
 
LIBCZI_API void SetCreationDate (const XmlDateTime *dateTime)
 
LIBCZI_API void Clear ()
 Sets all fields to "invalid".
 

Public Attributes

bool name_valid
 Whether the field name is valid.

 
std::wstring name
 Name of the document.
 
bool title_valid
 Whether the field title is valid.

 
std::wstring title
 Title of the document.
 
bool userName_valid
 Whether the field userName is valid.

 
std::wstring userName
 Name of the user who created the document.
 
bool description_valid
 Whether the field description is valid.

 
std::wstring description
 A text describing the document.
 
bool comment_valid
 Whether the field comment is valid.

 
std::wstring comment
 A text with comments on the document.
 
bool keywords_valid
 Whether the field keywords is valid.

 
std::wstring keywords
 List of keywords (should be separated by semicolons)
 
bool rating_valid
 Whether the field rating is valid.

 
int rating
 An integer specifying a "five-star-rating" (should be between 0 and 5).
 
bool creationDateTime_valid
 Whether the field creationDateTime is valid.

 
std::wstring creationDateTime
 The creation date of the document (formatted as xml-datatype "dateTime").
 

Detailed Description

General document information - corresponding to Information/Document.

Member Function Documentation

◆ SetComment() [1/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetComment ( const std::wstring &  str)
inline

Sets the comment and marks it valid if the specified string is non-empty. Otherwise, the comment is set to invalid.

Parameters
strThe string to set as comment.

◆ SetComment() [2/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetComment ( const wchar_t *  sz)
inline

Sets the comment and marks it valid if the specified string is non-null and non-empty. Otherwise, the comment is set to invalid.

Parameters
szThe string to set as comment.

◆ SetCreationDate() [1/3]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetCreationDate ( const std::wstring &  str)
inline

Sets the creationDateTime and marks it valid if the specified string is non-empty. Otherwise, the creationDateTime is set to invalid.

Parameters
strThe string to set as creationDateTime.

◆ SetCreationDate() [2/3]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetCreationDate ( const wchar_t *  sz)
inline

Sets the creationDateTime and marks it valid if the specified string is non-null and non-empty. Otherwise, the creationDateTime is set to invalid.

Parameters
szThe string to set as creationDateTime.

◆ SetCreationDate() [3/3]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetCreationDate ( const XmlDateTime dateTime)
inline

Sets the creationDateTime and marks it valid if the specified XmlDateTime-struct pointer is non-null and valid. Otherwise, the creationDateTime is set to invalid.

Parameters
dateTimeThe XmlDateTime-struct to set as creationDateTime.

◆ SetDescription() [1/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetDescription ( const std::wstring &  str)
inline

Sets the description and marks it valid if the specified string is non-empty. Otherwise, the description is set to invalid.

Parameters
strThe string to set as description.

◆ SetDescription() [2/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetDescription ( const wchar_t *  sz)
inline

Sets the description and marks it valid if the specified string is non-null and non-empty. Otherwise, the description is set to invalid.

Parameters
szThe string to set as description.

◆ SetKeywords() [1/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetKeywords ( const std::wstring &  str)
inline

Sets the keywords and marks it valid if the specified string is non-empty. Otherwise, the keywords is set to invalid.

Parameters
strThe string to set as keywords.

◆ SetKeywords() [2/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetKeywords ( const wchar_t *  sz)
inline

Sets the keywords and marks it valid if the specified string is non-null and non-empty. Otherwise, the keywords is set to invalid.

Parameters
szThe string to set as keywords.

◆ SetName() [1/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetName ( const std::wstring &  str)
inline

Sets the name and marks it valid if the specified string is non-empty. Otherwise, the name is set to invalid.

Parameters
strThe string to set as name.

◆ SetName() [2/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetName ( const wchar_t *  sz)
inline

Sets the name and marks it valid if the specified string is non-null and non-empty. Otherwise, the name is set to invalid.

Parameters
szThe string to set as name.

◆ SetRating()

LIBCZI_API void libCZI::GeneralDocumentInfo::SetRating ( int  rating)
inline

Sets the rating and marks it as valid if the specified rating is non-negative. Otherwise, the rating is set to invalid.

Parameters
ratingThe rating.

◆ SetTitle() [1/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetTitle ( const std::wstring &  str)
inline

Sets the title and marks it valid if the specified string is non-empty. Otherwise, the title is set to invalid.

Parameters
strThe string to set as title.

◆ SetTitle() [2/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetTitle ( const wchar_t *  sz)
inline

Sets the title and marks it valid if the specified string is non-null and non-empty. Otherwise, the title is set to invalid.

Parameters
szThe string to set as title.

◆ SetUserName() [1/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetUserName ( const std::wstring &  str)
inline

Sets the username and marks it valid if the specified string is non-empty. Otherwise, the username is set to invalid.

Parameters
strThe string to set as username.

◆ SetUserName() [2/2]

LIBCZI_API void libCZI::GeneralDocumentInfo::SetUserName ( const wchar_t *  sz)
inline

Sets the username and marks it valid if the specified string is non-null and non-empty. Otherwise, the username is set to invalid.

Parameters
szThe string to set as username.

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