7#ifndef IOSS_IOVS_CATALYST_LOGGING_H
8#define IOSS_IOVS_CATALYST_LOGGING_H
10#include "iovs_export.h"
82 std::vector<std::string> getLogFileHeaders();
83 std::vector<std::string> writeToLogFile();
84 std::vector<std::vector<std::string>> readLogFile();
85 static std::vector<std::vector<std::string>> readLogFile(
const std::string &logFilePath);
88 if (logOutputDirectoryPath.empty()) {
89 return getLogFileName();
92 std::string opath = getLogOutputDirectoryPath();
93 if (opath.back() !=
'/') {
96 return opath + getLogFileName();
103 return propName.substr(logPrefix.length());
107 return logPrefix + headerName;
111 return propName == enabledProp || propName == fileNameProp || propName == directoryPathProp;
116 if (properties && properties->exists(propName)) {
129 std::string logPrefix =
"CATALYST_LOGGING_";
130 std::string enabledProp = logPrefix +
"ENABLED";
131 std::string fileNameProp = logPrefix +
"FILE_NAME";
132 std::string directoryPathProp = logPrefix +
"OUTPUT_DIRECTORY_PATH";
133 void initializeDefaults();
134 void writeVectorWithDelimeter(std::fstream &file,
const std::vector<std::string> &string_vector,
136 static std::vector<std::string> splitStringWithDelimeter(
const std::string &input,
138 bool isLogFileEmpty();
139 std::vector<std::string> getLogOutputFromProps(std::vector<std::string> &headers);
A collection of Ioss::Property objects.
Definition Ioss_PropertyManager.h:36
BasicType
Definition Ioss_Property.h:29
@ INTEGER
Definition Ioss_Property.h:29
@ REAL
Definition Ioss_Property.h:29
@ STRING
Definition Ioss_Property.h:29
Definition Iovs_CatalystLogging.h:20
bool isReservedPropName(std::string &propName)
Definition Iovs_CatalystLogging.h:109
std::string logFileName
Definition Iovs_CatalystLogging.h:126
bool isCatalystLoggingProp(std::string &propName)
Definition Iovs_CatalystLogging.h:100
const Ioss::PropertyManager * properties
Definition Iovs_CatalystLogging.h:128
std::string getLogFileName()
Definition Iovs_CatalystLogging.h:77
static std::string getDefaultLogFileName()
Definition Iovs_CatalystLogging.h:78
bool catalystLoggingEnabled
Definition Iovs_CatalystLogging.h:125
std::string getHeaderNameFromPropName(std::string &propName)
Definition Iovs_CatalystLogging.h:101
bool isCatalystLoggingON()
Definition Iovs_CatalystLogging.h:76
std::string getLogFilePath()
Definition Iovs_CatalystLogging.h:86
std::string getLogOutputDirectoryPath()
Definition Iovs_CatalystLogging.h:79
static char getDelimeter()
Definition Iovs_CatalystLogging.h:99
std::string getDefaultLogOutputDirectoryPath()
Definition Iovs_CatalystLogging.h:80
bool isSupportedPropType(std::string &propName)
Definition Iovs_CatalystLogging.h:113
std::string logOutputDirectoryPath
Definition Iovs_CatalystLogging.h:127
std::string getPropNameFromHeaderName(std::string &headerName)
Definition Iovs_CatalystLogging.h:105
Definition CatalystManager.h:22