Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Development
openfoam
Commits
7f4a9992
Commit
7f4a9992
authored
Jun 26, 2008
by
Mark Olesen
Browse files
cleanup of foamNew templates
parent
c20da53c
Changes
9
Hide whitespace changes
Inline
Side-by-side
bin/foamTemplates/foamAppTemplate.C
deleted
100644 → 0
View file @
c20da53c
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-2008 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
OpenFOAM is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.
You should have received a copy of the GNU General Public License
along with OpenFOAM; if not, write to the Free Software Foundation,
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Application
className
Description
Description of the className application
Usage
- className [OPTION]
\*---------------------------------------------------------------------------*/
#include
"fvCFD.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
// Main program:
int
main
(
int
argc
,
char
*
argv
[])
{
# include "setRootCase.H"
# include "createTime.H"
Info
<<
"End
\n
"
<<
endl
;
return
0
;
}
// ************************************************************************* //
bin/foamTemplates/foamTemplate.C
deleted
100644 → 0
View file @
c20da53c
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-2008 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
OpenFOAM is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.
You should have received a copy of the GNU General Public License
along with OpenFOAM; if not, write to the Free Software Foundation,
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
\*---------------------------------------------------------------------------*/
#include
"className.H"
// * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
const
dataType
Foam
::
className
::
staticData
();
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
Foam
::
className
::
className
()
:
baseClassName
(),
data_
()
{}
Foam
::
className
::
className
(
const
dataType
&
data
)
:
baseClassName
(),
data_
(
data
)
{}
Foam
::
className
::
className
(
const
className
&
)
:
baseClassName
(),
data_
()
{}
// * * * * * * * * * * * * * * * * Selectors * * * * * * * * * * * * * * * * //
Foam
::
autoPtr
<
Foam
::
className
>
Foam
::
className
::
New
()
{
return
autoPtr
<
className
>
(
new
className
);
}
// * * * * * * * * * * * * * * * * Destructor * * * * * * * * * * * * * * * //
Foam
::
className
::~
className
()
{}
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
void
Foam
::
className
::
operator
=
(
const
className
&
rhs
)
{
// Check for assignment to self
if
(
this
==
&
rhs
)
{
FatalErrorIn
(
"Foam::className::operator=(const Foam::className&)"
)
<<
"Attempted assignment to self"
<<
abort
(
FatalError
);
}
}
// * * * * * * * * * * * * * * * Friend Functions * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * Friend Operators * * * * * * * * * * * * * //
// ************************************************************************* //
bin/foamTemplates/foamTemplate.H
deleted
100644 → 0
View file @
c20da53c
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-2008 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
OpenFOAM is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.
You should have received a copy of the GNU General Public License
along with OpenFOAM; if not, write to the Free Software Foundation,
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Class
Foam::className
Description
Short Summary
Complete description
SourceFiles
classNameI.H
className.C
classNameIO.C
\*---------------------------------------------------------------------------*/
#ifndef className_H
#define className_H
#include
".H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace
Foam
{
// Forward declaration of classes
class
someClass
;
// Forward declaration of friend functions and operators
class
className
;
Istream
&
operator
>>
(
Istream
&
,
className
&
);
Ostream
&
operator
<<
(
Ostream
&
,
const
className
&
);
/*---------------------------------------------------------------------------*\
Class className Declaration
\*---------------------------------------------------------------------------*/
class
className
:
public
baseClassName
{
// Private data
dataType
data_
;
// Private Member Functions
//- Disallow default bitwise copy construct
className
(
const
className
&
);
//- Disallow default bitwise assignment
void
operator
=
(
const
className
&
);
public:
// Static data members
//- Static data someStaticData
static
const
dataType
staticData
;
// Constructors
//- Construct null
className
();
//- Construct from components
className
(
const
dataType
&
data
);
//- Construct from Istream
className
(
Istream
&
);
//- Construct as copy
className
(
const
className
&
);
// Selectors
//- Select null constructed
static
autoPtr
<
className
>
New
();
//- Destructor
~
className
();
// Member Functions
// Access
// Check
// Edit
// Write
// Member Operators
void
operator
=
(
const
className
&
);
// Friend Functions
// Friend Operators
// IOstream Operators
friend
Istream
&
operator
>>
(
Istream
&
,
className
&
);
friend
Ostream
&
operator
<<
(
Ostream
&
,
const
className
&
);
};
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
}
// End namespace Foam
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#include
"classNameI.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#endif
// ************************************************************************* //
bin/foamTemplates/foamTemplateI.H
deleted
100644 → 0
View file @
c20da53c
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-2008 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
OpenFOAM is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.
You should have received a copy of the GNU General Public License
along with OpenFOAM; if not, write to the Free Software Foundation,
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
\*---------------------------------------------------------------------------*/
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
// * * * * * * * * * * * * * Private Member Functions * * * * * * * * * * * //
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * * Destructors * * * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * Member Operators * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * Friend Functions * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * Friend Operators * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * IOstream Operators * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * Ostream Operator * * * * * * * * * * * * * //
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
// ************************************************************************* //
bin/foamTemplates/foamTemplateIO.C
deleted
100644 → 0
View file @
c20da53c
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 1991-2008 OpenCFD Ltd.
\\/ M anipulation |
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
OpenFOAM is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.
You should have received a copy of the GNU General Public License
along with OpenFOAM; if not, write to the Free Software Foundation,
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
\*---------------------------------------------------------------------------*/
#include
"className.H"
#include
"IOstreams.H"
// * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
Foam
::
className
::
className
(
Istream
&
is
)
:
base1
(
is
),
base2
(
is
),
member1
(
is
),
member2
(
is
)
{
// Check state of Istream
is
.
check
(
"Foam::className::className(Foam::Istream&)"
);
}
// * * * * * * * * * * * * * * * IOstream Operators * * * * * * * * * * * * //
Foam
::
Istream
&
Foam
::
operator
>>
(
Istream
&
is
,
className
&
)
{
// Check state of Istream
is
.
check
(
"Foam::Istream& Foam::operator>>(Foam::Istream&, Foam::className&)"
);
return
is
;
}
Foam
::
Ostream
&
Foam
::
operator
<<
(
Ostream
&
os
,
const
className
&
)
{
// Check state of Ostream
os
.
check
(
"Foam::Ostream& Foam::operator<<(Foam::Ostream&, "
"const Foam::className&)"
);
return
os
;
}
// ************************************************************************* //
bin/foamTemplates/source/foamUtilTemplate.cfg
View file @
7f4a9992
/*--------------------------------
---------
----------------------------------*\
/*--------------------------------
*- C++ -*
----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 1.
4.1
|
| \\ / A nd | Web: http://www.
o
pen
foam
.org |
| \\ / O peration | Version: 1.
5
|
| \\ / A nd | Web: http://www.
O
pen
FOAM
.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
// className tool definition
...
...
bin/foamTemplates/source/newSource
View file @
7f4a9992
...
...
@@ -66,10 +66,10 @@ IO)
template
=
foamTemplateIO
fileType
=
C
;;
App
)
app|
App
)
template
=
foamAppTemplate
fileType
=
C
if
[
!
-d
"
Make
"
]
;
then
if
[
!
-d
Make
]
;
then
echo
"foamNew: Creating Make/files and Make/options"
wmakeFilesAndOptions
fi
...
...
bin/foamTemplates/sourceTemplate/foamTemplateTemplate.H
View file @
7f4a9992
...
...
@@ -54,14 +54,14 @@ template<TemplateClassArgument>
class
ClassName
;
template
<
TemplateClassArgument
>
Istream
&
operator
>>
(
Istream
&
,
ClassName
<
Template
Class
Argument
>&
);
Istream
&
operator
>>
(
Istream
&
,
ClassName
<
TemplateArgument
>&
);
template
<
TemplateClassArgument
>
Ostream
&
operator
<<
(
Ostream
&
,
const
ClassName
<
Template
Class
Argument
>&
);
Ostream
&
operator
<<
(
Ostream
&
,
const
ClassName
<
TemplateArgument
>&
);
/*---------------------------------------------------------------------------*\
Class ClassName Declaration
Class ClassName Declaration
\*---------------------------------------------------------------------------*/
template
<
TemplateClassArgument
>
...
...
bin/foamTemplates/sourceTemplate/newSourceTemplate
View file @
7f4a9992
...
...
@@ -46,7 +46,7 @@ USAGE
exit
1
}
if
[
"$#"
-l
t
2
]
;
then
if
[
"$#"
-l
e
2
]
;
then
usage
"wrong number of arguments, expected 3 (or more)"
fi
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment