xtd 0.2.0
Loading...
Searching...
No Matches
string_reader.hpp
Go to the documentation of this file.
1
4#pragma once
5#include "text_reader.hpp"
6#include <sstream>
7
9namespace xtd {
11 namespace io {
28 public:
30
34 explicit string_reader(const xtd::string& input);
36
38
42 [[nodiscard]] auto peek() const -> xtd::int32 override;
43
46 [[nodiscard]] auto read() -> xtd::int32 override;
48
49 private:
50 mutable std::stringstream stream_;
51 };
52 }
53}
auto peek() const -> xtd::int32 override
Reads the next character without changing the state of the reader or the character source....
auto read() -> xtd::int32 override
Reads the next character from the input stream and advances the character position by one character.
string_reader(const xtd::string &input)
Initializes a new instance of the stream_reader class for the specified file name.
Represents a reader that can read a sequential series of characters.
Definition text_reader.hpp:38
#define core_export_
Define shared library export.
Definition core_export.hpp:13
xtd::basic_string< char > string
Represents text as a sequence of UTF-8 code units.
Definition __string_definitions.hpp:43
std::int32_t int32
Represents a 32-bit signed integer.
Definition int32.hpp:23
The xtd::io namespace contains types that allow reading and writing to files and data streams,...
Definition binary_reader.hpp:17
The xtd namespace contains all fundamental classes to access Hardware, Os, System,...
Definition abstract_object.hpp:8
Contains xtd::io::text_reader class.