§ getAddDateTime()
bool getAddDateTime |
( |
void |
| ) |
const |
- Returns
- 'true', if log lines are prefixed with the date and time of the EGLOG() call, 'false' otherwise.
- See also
- setAddDateTime()
§ setAddDateTime()
Sets the value of the AddDateTime flag. The default value of this flag is 'true'.
- Parameters
-
addTime | 'true' instructs the Logger instance to prefix log lines with the date and time of the EGLOG() call, 'false' prevents it from doing so. |
- See also
- getAddDateTime()
§ getAddLevel()
bool getAddLevel |
( |
void |
| ) |
const |
§ setAddLevel()
Sets the value of the AddLevel flag. The default value of this flag is 'true'.
- Parameters
-
addLevel | 'true' instructs the Logger instance to prefix log lines with the DebugLevel of the EGLOG() call, 'false' prevents it from doing so. |
- See also
- getAddLevel()
§ getAddFile()
bool getAddFile |
( |
void |
| ) |
const |
- Returns
- 'true', if log lines are prefixed with the source file of the EGLOG() call, 'false' otherwise.
- See also
- setAddFile()
§ setAddFile()
Sets the value of the AddFile flag. The default value of this flag is 'true'.
- Parameters
-
addFile | 'true' instructs the Logger instance to prefix log lines with the source file of the EGLOG() call, 'false' prevents it from doing so. |
- See also
- getAddFile()
§ getAddFunction()
bool getAddFunction |
( |
void |
| ) |
const |
- Returns
- 'true', if log lines are prefixed with the name of the function that did the EGLOG() call, 'false' otherwise.
- See also
- setAddFunction()
§ setAddFunction()
Sets the value of the AddFunction flag. The default value of this flag is 'true'.
- Parameters
-
addFunction | 'true' instructs the Logger instance to prefix log lines with the name of the function that did the EGLOG() call, 'false' prevents it from doing so. |
- See also
- getAddFunction()
§ getMaxNumberOfNamespaces()
unsigned int getMaxNumberOfNamespaces |
( |
void |
| ) |
const |
§ setMaxNumberOfNamespaces()
LogFormatOptions & setMaxNumberOfNamespaces |
( |
unsigned int |
maxNumberOfNamespaces | ) |
|
Sets the maximum number of namespaces that are included in the name of the function that did the EGLOG() call. The default value of this option is UINT_MAX, which means that all namespaces should be printed.
- Note
- The name of the class counts as a namespace in this context and inner namespaces take precedence about outer namespaces.
Example:
The fully qualified name of the class member function includes 3 namespaces and the class name and is CompanyName::ProductName::ProjectName::ClassName::functionName().
- If the maxNumberOfNamespaces is 0, then the printed function name will be functionName().
- If the maxNumberOfNamespaces is 1, then the printed function name will be ClassName::functionName().
- If the maxNumberOfNamespaces is 2, then the printed function name will be ProjectName::ClassName::functionName().
- If the maxNumberOfNamespaces is 3, then the printed function name will be ProductName::ProjectName::ClassName::functionName().
- If the maxNumberOfNamespaces is 4, then the printed function name will be CompanyName::ProductName::ProjectName::ClassName::functionName().
- If the maxNumberOfNamespaces is 5, then the printed function name will still be CompanyName::ProductName::ProjectName::ClassName::functionName().
Usually the values that make the most sense are:
- UINT_MAX (the fully qualified function name including all namespaces)
- 0 (just the function name itself)
- 1 (for class member functions this means the function name and the class name, but no namespaces, while for free functions it means the function name and the name of the most inner namespace, but not the names of any other namespaces)
- Remarks
- This option is only relevant when the values returend by getAddFunction() is set to 'true' (which is the default).
- Parameters
-
maxNumberOfNamespaces | the maximum number of namespaces |
- See also
- getAddFunction(), setAddFunction(), getMaxNumberOfNamespaces()
§ getAddLine()
bool getAddLine |
( |
void |
| ) |
const |
- Returns
- 'true', if log lines are prefixed with the line of the EGLOG() call, 'false' otherwise.
- See also
- setAddLine()
§ setAddLine()
Sets the value of the AddLine flag. The default value of this flag is 'true'.
- Parameters
-
addLine | 'true' instructs the Logger instance to prefix log lines with the line of the EGLOG() call, 'false' prevents it from doing so. |
- See also
- getAddLine()
§ toString()
- Remarks
- The cost of this function depends a lot on implementation details of the implementing subclasses, but for container classes this function can become quite expensive, if the instance contains huge amounts of data, as its cost for many container class implementations increases disproportionately high to the size of the payload.
- Parameters
-
retStr | reference to a string, to store the return-value in; the information, which is generated by this function, will be attached at the end of any eventually existing previous content of the string |
withTypes | set to true, to include type information in the generated string |
- Returns
- a JString representation of the instance and its contents for debugging purposes.
Implements ToString.