Go to the documentation of this file.
53 int main(
int argc,
char *argv[])
71 Info<<
"list1.append(list2): " << list1 <<
endl;
79 Info<<
"Transferred via the xfer() method" <<
endl;
80 Info<<
"list2: " << list2 <<
nl
81 <<
"list3: " << list3 <<
endl;
85 Info<<
"list4: " << list4 <<
nl
86 <<
"list5: " << list5 <<
endl;
88 Info<<
"Swapped via the swap() method" <<
endl;
89 Info<<
"list4: " << list4 <<
nl
90 <<
"list5: " << list5 <<
endl;
95 Info<<
"Elements " << map <<
" out of " << list3
96 <<
" => " << subList3 <<
endl;
131 <<
"-reList: " << reLst <<
nl
132 <<
"-wordList: " << wLst <<
nl
133 <<
"-stringList: " << sLst <<
endl;
137 <<
"Test List Iterator Constuctor" <<
endl;
141 Info<<
" Initial List: " << initialList <<
endl;
143 List<vector> iteratorList(initialList.begin(), initialList.end());
145 Info<<
" Foam::List constructed from Foam::List: "
146 << iteratorList <<
endl;
148 std::list<vector> stlList(initialList.begin(), initialList.end());
150 Info<<
" std::list constructed from Foam::List: ";
152 std::list<vector>::iterator it;
153 for (it=stlList.begin(); it != stlList.end(); ++it)
159 List<vector> iteratorSTLList(stlList.begin(), stlList.end());
161 Info<<
" Foam::List constructed from std::list: "
162 << iteratorList <<
endl;
Functions used by OpenFOAM that are specific to POSIX compliant operating systems and need to be repl...
Useful combination of include files which define Sin, Sout and Serr and the use of IO streams general...
A class for handling words, derived from string.
static void addOption(const word &opt, const string ¶m="", const string &usage="")
Add to an option to validOptions with usage information.
int main(int argc, char *argv[])
label findIndex(const ListType &, typename ListType::const_reference, const label start=0)
Find first occurence of given element and return index,.
Xfer< List< T > > xfer()
Transfer contents to the Xfer container.
static void addBoolOption(const word &opt, const string &usage="")
Add to a bool option to validOptions with usage information.
Ostream & endl(Ostream &os)
Add newline and flush stream.
A wordRe is a word, but can also have a regular expression for matching words.
List< T > optionReadList(const word &opt) const
Read a List of values from the named option.
void append(const T &)
Append an element at the end of the list.
Input from memory buffer stream.
Vector< scalar > vector
A scalar version of the templated Vector.
void setSize(const label)
Reset size of List.
bool optionFound(const word &opt) const
Return true if the named option is found.
Various functions to operate on Lists.
static void noParallel()
Remove the parallel options.
Foam::argList args(argc, argv)
bool optionReadIfPresent(const word &opt, T &) const
Read a value from the named option if present.