Line input buffer.
More...
#include <cc/LineSource>
|
| using | Item = String |
| | Item type.
|
| |
| using | NullAccess = cc::NullAccess |
| | Error thrown when trying to access a null object.
|
| |
| using | VirginityTestFailed = cc::VirginityTestFailed |
| | Error thrown when trying to initialize an object with a non-virgin state.
|
| |
|
|
template<class T > |
| T | weak () const |
| |
| template<class T > |
| void | initOnce () |
| | Create the object state when called the first time.
|
| |
| template<class T > |
| void | initOncePerThread () |
| | Create a distinct object state for each thread when called the first time in that thread.
|
| |
| | Object (State *newState) |
| | Initialize object with newState.
|
| |
|
| Object (State *state, Alias) |
| |
|
| Object (State *state, Weak) |
| |
|
Object & | operator= (std::nullptr_t) |
| |
| template<class T > |
| static T | alias (const State *state) |
| | Create an alias object for the given state.
|
| |
|
template<class T > |
| static T | weak (const State *state) |
| |
| Handle< State > | me |
| | Internal object state
|
| |
Line input buffer.
- Note
- LineSource supports any type of line terminatation style (e.g. "\r\n", "\n", "\r" or "\0").
- Todo:
- The auxiliary buffer should be of type Bytes.
◆ Item
◆ LineSource() [1/4]
Create a null line source.
◆ LineSource() [2/4]
Open a new line source fed from a memory buffer.
- Parameters
-
◆ LineSource() [3/4]
Open a new line source fed from an input stream.
- Parameters
-
◆ LineSource() [4/4]
Open a new line source fed from an input stream.
- Parameters
-
| stream | Input stream |
| buffer | Input buffer |
◆ read()
Read next line (excluding the end of line marker)
- Parameters
-
| line | Returns the next line (if not end of input) |
- Returns
- True if not end of input
◆ begin()
◆ end()