Elm  2
ELM is a library providing generic data structures, OS-independent interface, plugins and XML.
StringInput Class Reference

#include <elm/io/StringInput.h>

+ Inheritance diagram for StringInput:

Public Member Functions

 StringInput (const char *str)
 
 StringInput (const cstring &str)
 
 StringInput (const string &str)
 
- Public Member Functions inherited from Input
 Input (void)
 
 Input (InStream &stream)
 
InStreamstream (void) const
 
void setStream (InStream &stream)
 
bool ended () const
 
bool failed () const
 
bool error () const
 
bool ok () const
 
void resetState ()
 
bool scanBool (void)
 
char scanChar (void)
 
t::uint32 scanULong (int base=0)
 
t::int32 scanLong (int base=0)
 
t::uint64 scanULLong (int base=0)
 
t::int64 scanLLong (int base=0)
 
double scanDouble (void)
 
String scanWord (void)
 
String scanLine (void)
 
void swallow (char chr)
 
void swallow (CString str)
 
void swallow (const String &str)
 
void swallowBlank (void)
 
Inputoperator>> (bool &value)
 
Inputoperator>> (char &value)
 
Inputoperator>> (unsigned char &value)
 
Inputoperator>> (short &value)
 
Inputoperator>> (unsigned short &value)
 
Inputoperator>> (int &value)
 
Inputoperator>> (unsigned int &value)
 
Inputoperator>> (signed long &value)
 
Inputoperator>> (unsigned long &value)
 
Inputoperator>> (signed long long &value)
 
Inputoperator>> (unsigned long long &value)
 
Inputoperator>> (float &value)
 
Inputoperator>> (double &value)
 
Inputoperator>> (String &value)
 
Inputoperator>> (const string &text)
 
Inputoperator>> (cstring text)
 
Inputoperator>> (const char *text)
 
template<class T >
Inputoperator>> (T &v)
 
LineRange lines ()
 

Detailed Description

Input performed on a string. It makes easy to perform formatted read from a simple string.

string s = "666";
int x;
in >> x;

Constructor & Destructor Documentation

◆ StringInput() [1/3]

StringInput ( const char *  str)
inline

Perform intput from the given string stored in character array.

Parameters
strTo read.

◆ StringInput() [2/3]

StringInput ( const cstring str)
inline

Perform intput from the given C string.

Parameters
strTo read.

◆ StringInput() [3/3]

StringInput ( const string str)
inline

Perform intput from the given ELM string.

Parameters
strTo read.

The documentation for this class was generated from the following files:
elm::io::StringInput::StringInput
StringInput(const char *str)
Definition: StringInput.h:32
elm::io::in
sys::SystemInStream & in
Definition: system_SystemIO.cpp:116