OpenFOAM logo
The Open Source CFD Toolbox
  Source Guide OpenCFD Solutions Contact OpenFOAM

word Class Reference

A class for handling words, derived from string. More...

Inheritance diagram for word:
Collaboration diagram for word:

List of all members.


Public Member Functions

 word ()
 Construct null.
 word (const word &)
 Construct as copy.
 word (const char *, const bool doStripInvalid=true)
 Construct as copy of character array.
 word (const char *, const size_type, const bool doStripInvalid)
 Construct as copy with a maximum number of characters.
 word (const string &, const bool doStripInvalid=true)
 Construct as copy of string.
 word (const std::string &, const bool doStripInvalid=true)
 Construct as copy of std::string.
 word (Istream &)
 Construct from Istream.
const word & operator= (const word &)
const word & operator= (const string &)
const word & operator= (const std::string &)
const word & operator= (const char *)

Static Public Member Functions

static bool valid (char)
 Is this character valid for a word.

Static Public Attributes

static const char *const typeName = "word"
static int debug
static const word null

Friends

word operator& (const word &, const word &)
Istream & operator>> (Istream &, word &)
Ostream & operator<< (Ostream &, const word &)

Detailed Description

A class for handling words, derived from string.

A word is a string of characters containing no whitespace and may be constructed from a string by removing whitespace. Words are delimited by whitespace.

Source files

Definition at line 56 of file word.H.


Constructor & Destructor Documentation

word (  )  [inline]

Construct null.

Definition at line 53 of file wordI.H.

word ( const word &  w  )  [inline]

Construct as copy.

Definition at line 47 of file wordI.H.

word ( const char *  s,
const bool  doStripInvalid = true 
) [inline]

Construct as copy of character array.

Definition at line 81 of file wordI.H.

word ( const char *  s,
const size_type  n,
const bool  doStripInvalid 
) [inline]

Construct as copy with a maximum number of characters.

Definition at line 92 of file wordI.H.

word ( const string &  s,
const bool  doStripInvalid = true 
) [inline]

Construct as copy of string.

Definition at line 59 of file wordI.H.

word ( const std::string &  s,
const bool  doStripInvalid = true 
) [inline]

Construct as copy of std::string.

Definition at line 70 of file wordI.H.

word ( Istream &  is  ) 

Construct from Istream.

Definition at line 27 of file wordIO.C.


Member Function Documentation

bool valid ( char  c  )  [inline, static]

Is this character valid for a word.

Definition at line 109 of file wordI.H.

const Foam::word & operator= ( const word &  q  )  [inline]

Reimplemented in keyType, and wordRe.

Definition at line 126 of file wordI.H.

Referenced by Foam::operator&(), word::operator=(), and keyType::operator=().

Here is the caller graph for this function:

const Foam::word & operator= ( const string &  q  )  [inline]

Reimplemented in keyType, and wordRe.

Definition at line 133 of file wordI.H.

References word::operator=().

Here is the call graph for this function:

const Foam::word & operator= ( const std::string &  q  )  [inline]

Reimplemented in wordRe.

Definition at line 141 of file wordI.H.

References word::operator=().

Here is the call graph for this function:

const Foam::word & operator= ( const char *  q  )  [inline]

Reimplemented in keyType, and wordRe.

Definition at line 149 of file wordI.H.

References word::operator=().

Here is the call graph for this function:


Friends And Related Function Documentation

word operator& ( const word &  ,
const word &   
) [friend]

Istream& operator>> ( Istream &  ,
word &   
) [friend]

Ostream& operator<< ( Ostream &  ,
const word &   
) [friend]


Member Data Documentation

const char *const typeName = "word" [static]

Reimplemented from string.

Definition at line 70 of file word.H.

int debug [static]

Reimplemented from string.

Definition at line 71 of file word.H.

const Foam::word null [static]

Reimplemented from string.

Definition at line 72 of file word.H.

Referenced by fieldAverage::addMeanField(), autoHexMeshDriver::autoHexMeshDriver(), Foam::home(), and Foam::writeMeshObject().


The documentation for this class was generated from the following files:
  • src/OpenFOAM/primitives/strings/word/word.H
  • src/OpenFOAM/primitives/strings/word/word.C
  • src/OpenFOAM/primitives/strings/word/wordI.H
  • src/OpenFOAM/primitives/strings/word/wordIO.C
Copyright © 2000-2009 OpenCFD Ltd