|
OpenXLSX 1.9.1
|
The XLAppProperties class represents the extended/application properties (docProps/app.xml). More...
#include <XLProperties.hpp>
Public Member Functions | |
| XLAppProperties ()=default | |
| Default constructor. | |
| XLAppProperties (XLXmlData *xmlData, XMLDocument const &workbookXml) | |
| Constructor for creating from existing data and workbook. | |
| XLAppProperties (XLXmlData *xmlData) | |
| Constructor for existing XML data. | |
| XLAppProperties (const XLAppProperties &other)=default | |
| Copy constructor. | |
| XLAppProperties (XLAppProperties &&other) noexcept=default | |
| Move constructor. | |
| ~XLAppProperties () | |
| Destructor. | |
| XLAppProperties & | operator= (const XLAppProperties &other)=default |
| Copy assignment operator. | |
| XLAppProperties & | operator= (XLAppProperties &&other) noexcept=default |
| Move assignment operator. | |
| void | incrementSheetCount (int16_t increment) |
| Increment or decrement the worksheet count in HeadingPairs and TitlesOfParts. | |
| void | alignWorksheets (const std::vector< std::string > &workbookSheetNames) |
| Align the sheet names in TitlesOfParts with the actual workbook sheet names. | |
| void | addSheetName (std::string_view title) |
| Add a sheet name to TitlesOfParts. | |
| void | deleteSheetName (std::string_view title) |
| Delete a sheet name from TitlesOfParts. | |
| void | setSheetName (std::string_view oldTitle, std::string_view newTitle) |
| Update a sheet name in TitlesOfParts. | |
| void | addHeadingPair (std::string_view name, int value) |
| Add a HeadingPair (e.g., "Worksheets"). | |
| void | deleteHeadingPair (std::string_view name) |
| Delete a HeadingPair. | |
| void | setHeadingPair (std::string_view name, int newValue) |
| Update a HeadingPair value. | |
| void | setProperty (std::string_view name, std::string_view value) |
| Set a generic property in app.xml. | |
| std::string | property (std::string_view name) const |
| Get a property value from app.xml. | |
| void | deleteProperty (std::string_view name) |
| Delete a property from app.xml. | |
| void | appendSheetName (std::string_view sheetName) |
| Append a sheet name. | |
| void | prependSheetName (std::string_view sheetName) |
| Prepend a sheet name. | |
| void | insertSheetName (std::string_view sheetName, unsigned int index) |
| Insert a sheet name at a specific index. | |
Public Member Functions inherited from OpenXLSX::XLXmlFile | |
| XLXmlFile ()=default | |
| Default constructor. | |
| std::string | xmlData (XLXmlSavingDeclaration savingDeclaration=XLXmlSavingDeclaration{}) const |
| Method for getting the XML data represented by the object. | |
| XLXmlFile (XLXmlData *xmlData) | |
| Constructor. Creates an object based on the xmlData input. | |
| XLXmlFile (const XLXmlFile &other)=default | |
| Copy constructor. Default implementation used. | |
| XLXmlFile (XLXmlFile &&other) noexcept=default | |
| Move constructor. Default implementation used. | |
| ~XLXmlFile ()=default | |
| Destructor. Default implementation used. | |
| bool | valid () const |
| check whether class is linked to a valid XML file | |
| XLXmlFile & | operator= (const XLXmlFile &other)=default |
| The copy assignment operator. The default implementation has been used. | |
| XLXmlFile & | operator= (XLXmlFile &&other) noexcept=default |
| The move assignment operator. The default implementation has been used. | |
| XLDocument & | parentDoc () |
| This function provides access to the parent XLDocument object. | |
| const XLDocument & | parentDoc () const |
| This function provides access to the parent XLDocument object. | |
| XMLDocument & | xmlDocument () |
| This function provides access to the underlying XMLDocument object. | |
| const XMLDocument & | xmlDocument () const |
| This function provides access to the underlying XMLDocument object. | |
| std::string | getXmlPath () const |
| Retrieve the path of the XML data in the .xlsx zip archive via m_xmlData->getXmlPath. | |
Additional Inherited Members | |
Protected Member Functions inherited from OpenXLSX::XLXmlFile | |
| void | setXmlData (std::string_view xmlData) |
| Provide the XML data represented by the object. | |
| std::string | relationshipID () const |
| This function returns the relationship ID (the ID used in the XLRelationships objects) for the object. | |
Protected Attributes inherited from OpenXLSX::XLXmlFile | |
| XLXmlData * | m_xmlData {nullptr} |
The XLAppProperties class represents the extended/application properties (docProps/app.xml).
|
default |
Default constructor.
|
explicit |
Constructor for creating from existing data and workbook.
| xmlData | Pointer to the XML data. |
| workbookXml | The workbook XML document. |
|
explicit |
Constructor for existing XML data.
| xmlData | Pointer to the XML data. |
|
default |
Copy constructor.
|
defaultnoexcept |
Move constructor.
|
default |
Destructor.
| void XLAppProperties::addHeadingPair | ( | std::string_view | name, |
| int | value | ||
| ) |
Add a HeadingPair (e.g., "Worksheets").
| name | The name of the pair. |
| value | The value. |
| void XLAppProperties::addSheetName | ( | std::string_view | title | ) |
Add a sheet name to TitlesOfParts.
| title | The sheet name. |
| void XLAppProperties::alignWorksheets | ( | const std::vector< std::string > & | workbookSheetNames | ) |
Align the sheet names in TitlesOfParts with the actual workbook sheet names.
| workbookSheetNames | Vector of sheet names. |
| void XLAppProperties::appendSheetName | ( | std::string_view | sheetName | ) |
Append a sheet name.
| sheetName | The name to append. |
| void XLAppProperties::deleteHeadingPair | ( | std::string_view | name | ) |
Delete a HeadingPair.
| name | The name of the pair. |
| void XLAppProperties::deleteProperty | ( | std::string_view | name | ) |
Delete a property from app.xml.
| name | The property name. |
| void XLAppProperties::deleteSheetName | ( | std::string_view | title | ) |
Delete a sheet name from TitlesOfParts.
| title | The sheet name. |
| void XLAppProperties::incrementSheetCount | ( | int16_t | increment | ) |
Increment or decrement the worksheet count in HeadingPairs and TitlesOfParts.
| increment | The change in count. |
| void XLAppProperties::insertSheetName | ( | std::string_view | sheetName, |
| unsigned int | index | ||
| ) |
Insert a sheet name at a specific index.
| sheetName | The name to insert. |
| index | The 1-based index. |
|
default |
Copy assignment operator.
|
defaultnoexcept |
Move assignment operator.
| void XLAppProperties::prependSheetName | ( | std::string_view | sheetName | ) |
Prepend a sheet name.
| sheetName | The name to prepend. |
| std::string XLAppProperties::property | ( | std::string_view | name | ) | const |
Get a property value from app.xml.
| name | The property name. |
| void XLAppProperties::setHeadingPair | ( | std::string_view | name, |
| int | newValue | ||
| ) |
Update a HeadingPair value.
| name | The name of the pair. |
| newValue | The new value. |
| void XLAppProperties::setProperty | ( | std::string_view | name, |
| std::string_view | value | ||
| ) |
Set a generic property in app.xml.
| name | The property name. |
| value | The value. |
| void XLAppProperties::setSheetName | ( | std::string_view | oldTitle, |
| std::string_view | newTitle | ||
| ) |
Update a sheet name in TitlesOfParts.
| oldTitle | The old name. |
| newTitle | The new name. |