STYLE: favour include word.H instead of string.H

- in many places the string.H include is redundant anyhow.
  May wish to change to foamString.H (or equiv) in the future
This commit is contained in:
Mark Olesen 2023-02-22 18:25:33 +01:00
parent d88272f031
commit e623e6a865
22 changed files with 42 additions and 74 deletions

View File

@ -28,7 +28,6 @@ Description
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#include "string.H"
#include "macros.H" #include "macros.H"
#include "IOstreams.H" #include "IOstreams.H"
#include "List.H" #include "List.H"

View File

@ -29,7 +29,7 @@ Description
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#include "string.H" #include "word.H"
#include "IOstreams.H" #include "IOstreams.H"
using namespace Foam; using namespace Foam;

View File

@ -32,8 +32,8 @@ Description
#include <limits> #include <limits>
#include "int.H" #include "int.H"
#include "uint.H" #include "uint.H"
#include "string.H"
#include "scalar.H" #include "scalar.H"
#include "word.H"
#include "IOstreams.H" #include "IOstreams.H"
using namespace Foam; using namespace Foam;

View File

@ -31,7 +31,6 @@ Description
#include "bool.H" #include "bool.H"
#include "Switch.H" #include "Switch.H"
#include "string.H"
#include "dictionary.H" #include "dictionary.H"
#include "zero.H" #include "zero.H"
#include "IOstreams.H" #include "IOstreams.H"

View File

@ -29,12 +29,7 @@ Description
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#include "string.H" #include "fieldExprFwd.H"
#include "stringOps.H"
#include "dictionary.H"
#include "IOstreams.H"
#include "OSspecific.H"
#include "int.H" #include "int.H"
#include "uint.H" #include "uint.H"
#include "scalar.H" #include "scalar.H"
@ -42,6 +37,10 @@ Description
#include "fileName.H" #include "fileName.H"
#include "stringList.H" #include "stringList.H"
#include "stringOps.H" #include "stringOps.H"
#include "dictionary.H"
#include "IOstreams.H"
#include "OSspecific.H"
using namespace Foam; using namespace Foam;

View File

@ -28,12 +28,7 @@ Description
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#include "string.H" #include "fieldExprFwd.H"
#include "stringOps.H"
#include "dictionary.H"
#include "IOstreams.H"
#include "OSspecific.H"
#include "int.H" #include "int.H"
#include "uint.H" #include "uint.H"
#include "scalar.H" #include "scalar.H"
@ -41,7 +36,10 @@ Description
#include "fileName.H" #include "fileName.H"
#include "stringList.H" #include "stringList.H"
#include "stringOps.H" #include "stringOps.H"
#include "fieldExprFwd.H" #include "dictionary.H"
#include "IOstreams.H"
#include "OSspecific.H"
using namespace Foam; using namespace Foam;

View File

@ -38,7 +38,7 @@ SourceFiles
#ifndef PDRpatchDef_H #ifndef PDRpatchDef_H
#define PDRpatchDef_H #define PDRpatchDef_H
#include "string.H" #include "word.H"
#include "scalar.H" #include "scalar.H"
#include "Enum.H" #include "Enum.H"

View File

@ -58,7 +58,6 @@ Usage
#include "volFields.H" #include "volFields.H"
#include "pointFields.H" #include "pointFields.H"
#include "surfaceFields.H" #include "surfaceFields.H"
#include "string.H"
using namespace Foam; using namespace Foam;

View File

@ -40,10 +40,10 @@ SourceFiles
#ifndef Foam_UPstream_H #ifndef Foam_UPstream_H
#define Foam_UPstream_H #define Foam_UPstream_H
#include "wordList.H"
#include "labelList.H" #include "labelList.H"
#include "DynamicList.H" #include "DynamicList.H"
#include "HashTable.H" #include "HashTable.H"
#include "string.H"
#include "Enum.H" #include "Enum.H"
#include "ListOps.H" #include "ListOps.H"

View File

@ -43,7 +43,7 @@ SeeAlso
#ifndef Foam_expressions_exprString_H #ifndef Foam_expressions_exprString_H
#define Foam_expressions_exprString_H #define Foam_expressions_exprString_H
#include "string.H" #include "word.H"
#include "dictionary.H" #include "dictionary.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

View File

@ -38,9 +38,9 @@ SourceFiles
#ifndef Foam_profilingInformation_H #ifndef Foam_profilingInformation_H
#define Foam_profilingInformation_H #define Foam_profilingInformation_H
#include "label.H" #include "labelFwd.H"
#include "scalar.H" #include "scalarFwd.H"
#include "string.H" #include "word.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
@ -130,45 +130,21 @@ public:
// Access // Access
label id() const label id() const noexcept { return id_; }
{
return id_;
}
const string& description() const const string& description() const noexcept { return description_; }
{
return description_;
}
profilingInformation& parent() const profilingInformation& parent() const noexcept { return *parent_; }
{
return *parent_;
}
label calls() const label calls() const noexcept { return calls_; }
{
return calls_;
}
scalar totalTime() const scalar totalTime() const noexcept { return totalTime_; }
{
return totalTime_;
}
scalar childTime() const scalar childTime() const noexcept { return childTime_; }
{
return childTime_;
}
int maxMem() const int maxMem() const noexcept { return maxMem_; }
{
return maxMem_;
}
bool active() const bool active() const noexcept { return active_; }
{
return active_;
}
// Edit // Edit

View File

@ -38,7 +38,7 @@ SourceFiles
#ifndef Foam_profilingTrigger_H #ifndef Foam_profilingTrigger_H
#define Foam_profilingTrigger_H #define Foam_profilingTrigger_H
#include "string.H" #include "word.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

View File

@ -26,10 +26,10 @@ License
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#include "scalarRange.H" #include "scalarRange.H"
#include "string.H"
#include "Switch.H" #include "Switch.H"
#include "MinMax.H" #include "MinMax.H"
#include "error.H" #include "error.H"
#include "word.H"
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * // // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //

View File

@ -43,10 +43,10 @@ Description
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#ifndef stringList_H #ifndef Foam_stringList_H
#define stringList_H #define Foam_stringList_H
#include "string.H" #include "word.H"
#include "List.H" #include "List.H"
#include "SubList.H" #include "SubList.H"

View File

@ -43,8 +43,8 @@ Description
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#ifndef wordList_H #ifndef Foam_wordList_H
#define wordList_H #define Foam_wordList_H
#include "word.H" #include "word.H"
#include "List.H" #include "List.H"

View File

@ -26,8 +26,8 @@ License
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#include "genericRagelLemonDriver.H" #include "genericRagelLemonDriver.H"
#include "string.H"
#include "error.H" #include "error.H"
#include "word.H"
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //

View File

@ -40,13 +40,12 @@ SourceFiles
#define Foam_stringOps_H #define Foam_stringOps_H
#include "scalar.H" #include "scalar.H"
#include "string.H"
#include "SubStrings.H" #include "SubStrings.H"
#include "word.H"
#include "dictionary.H" #include "dictionary.H"
#include "HashTable.H" #include "HashTable.H"
#include "stringOpsSort.H" #include "stringOpsSort.H"
#include "stringOpsEvaluate.H" #include "stringOpsEvaluate.H"
#include "word.H"
#include "wordRes.H" #include "wordRes.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

View File

@ -31,8 +31,8 @@ Description
\*---------------------------------------------------------------------------*/ \*---------------------------------------------------------------------------*/
#ifndef stringOpsEvaluate_H #ifndef Foam_stringOpsEvaluate_H
#define stringOpsEvaluate_H #define Foam_stringOpsEvaluate_H
#include "labelFwd.H" #include "labelFwd.H"
#include "string.H" #include "string.H"

View File

@ -44,7 +44,7 @@ SourceFiles
#include "foamGltfBase.H" #include "foamGltfBase.H"
#include "Field.H" #include "Field.H"
#include "label.H" #include "label.H"
#include "string.H" #include "word.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

View File

@ -44,7 +44,7 @@ SourceFiles
#define Foam_vtk_outputOptions_H #define Foam_vtk_outputOptions_H
#include "foamVtkOutput.H" #include "foamVtkOutput.H"
#include "string.H" #include "word.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

View File

@ -37,9 +37,10 @@ SourceFiles
#ifndef Foam_curve_H #ifndef Foam_curve_H
#define Foam_curve_H #define Foam_curve_H
#include "string.H"
#include "primitiveFields.H"
#include "autoPtr.H" #include "autoPtr.H"
#include "point.H"
#include "primitiveFields.H"
#include "word.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

View File

@ -38,8 +38,6 @@ SourceFiles
#ifndef Foam_graph_H #ifndef Foam_graph_H
#define Foam_graph_H #define Foam_graph_H
#include "string.H"
#include "point.H"
#include "curve.H" #include "curve.H"
#include "HashPtrTable.H" #include "HashPtrTable.H"