Go to the documentation of this file.
161 template<
class Form,
class Cmpt,
int nCmpt>
166 template<
class T,
unsigned Size>
202 forAll(tag.children_, i)
204 os << tag.children_[i];
210 os << tag.str().c_str();
213 os << indent << "</" << tag.name_ << '>
' << endl;
224 //- Append the supplied data to the tag text
226 xmlTag& operator<<(xmlTag& tag, const UList<T>& data)
230 tag << data[i] << token::SPACE;
238 //- Append the supplied data to the tag text
240 xmlTag& operator<<(xmlTag& tag, const LongList<T>& data)
244 tag << data[i] << token::SPACE;
253 //- Append the supplied data to the tag text
254 template<class Form, class Cmpt, int nCmpt>
255 xmlTag& operator<<(xmlTag& tag, const VectorSpace<Form, Cmpt, nCmpt>& data)
259 tag << data[i] << token::SPACE;
267 //- Append the supplied data to the tag text
268 template<class T, unsigned Size>
269 xmlTag& operator<<(xmlTag& tag, const FixedList<T, Size>& data)
273 tag << data[i] << token::SPACE;
281 //- Append the supplied data to the tag text
282 xmlTag& operator<<(xmlTag& tag, const labelledTri& data)
284 const triFace& tFace = data;
289 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
291 } // End namespace Foam
293 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
297 // ************************************************************************* //
xmlTag & addChild(const word &name)
Create and add a new child.
A class for handling words, derived from string.
A class for handling file names.
A 1D vector of objects of type <T> that resizes itself as necessary to accept the new objects.
xmlTag & addChild(const xmlTag &tag)
Add a child.
void addAttribute(const keyType &key, const word &value)
Add a word attribute.
An STL-conforming const_iterator.
xmlTag()
Null constructor.
string str() const
Return the string.
void addAttribute(const keyType &key, const string &value)
Add a string attribute.
A class for handling keywords in dictionaries.
virtual const fileName & name() const
Return the name of the stream.
void T(FieldField< Field, Type > &f1, const FieldField< Field, Type > &f2)
Simple XML tag class allowing child tags and attributes. Specialized output stream operators are prov...
void operator=(const xmlTag &tag)
xmlTag(const xmlTag &tag)
Construct as copy.
Ostream & operator<<(Ostream &, const edgeMesh &)
xmlTag(const word &name)
Construct given tag name.
Ostream & indent(Ostream &os)
Indent stream.
An STL-conforming hash table.
Output to memory buffer stream.
A 1D vector of objects of type <T> with a fixed size <Size>.
void rewind()
Rewind the OStringStream.
Triangle with additional region number.
DynamicList< xmlTag > children_
Child tags.
An Ostream is an abstract base class for all output systems (streams, files, token lists,...
friend Ostream & operator<<(Ostream &, const xmlTag &)
Write the tag in XML format to the supplied output stream.
HashTable< string > attributes_
Attributes.
void addAttribute(const keyType &key, const fileName &value)
Add a fileName attribute.
void addAttribute(const keyType &key, const T &value)
Add an attribute.