logo
Main Page | Namespaces | Classes | Compounds | Files | Compound Members | Related

Utils Namespace Reference

Conversion and XML routines. Utils consists of simple string conversions routines and a small XML parsing library. More...


Compounds

class  AttributeNode
 Used to represent XML Attributes. More...

class  parseError
 Exception thrown by XMLDoc.parser. More...

class  TagNode
 Used to represent a tag node (I.E.: <html> ) . More...

class  TextNode
 Used to represent text nodes. More...

class  XMLDoc
 Class for representing a XML document. More...

class  XMLNode
 The base class for all XMLNodes. More...

class  XMLSearch

Functions

double Log2 (double x)
 Returns base 2 logarithm (log2 (x) = log10(x) / log10(2)).

void trim (string &S)
 Trims leading and trailing spaces.

std::string newline ()
std::string space (int indent)
 Returns 'indent' spaces.

std::string floatToString (float f)
 Converts a float to a C++ std::string.

std::string intToString (int i)
 Converts a int to a C++ std::string.

float stringToFloat (string s)
 Converts a C++ std::string to a float.

int stringToInt (string s)
 Converts a C++ std::string to an int.


Detailed Description

Conversion and XML routines. Utils consists of simple string conversions routines and a small XML parsing library.

The XML library is a DOM (document object model) parsing library. It is not very efficient and should be used for small files (<2MB) only.

A simple search routine for traversing the DOM tree is provided. (See XMLDoc for example usage).


Function Documentation

string Utils::newline  
 

Returns a newline For the time being a CR / NL (WIN 32 standard) todo Should be platform independent.

Definition at line 46 of file Utils.cpp.

Referenced by SynthCore::WaveShaper::getXML(), Utils::TextNode::getXML(), Utils::TagNode::getXML(), SynthCore::Tube::getXML(), SynthCore::Synth::getXML(), SynthCore::Sampler::getXML(), SynthCore::Polyphony::getXML(), SynthCore::Module::getXML(), SynthCore::Output::getXML(), SynthCore::Input::getXML(), SynthCore::BiQuad::getXML(), SynthCore::Envelope3::getXML(), and Utils::XMLDoc::parseFile().


Syntopia Project. Visit the web page, or the SourceForge page.
Docs made by Doxygen. Email: Mikael Christensen