|
| Float | toFloat (std::string_view str, Float default_v=0) |
| | 字符串 -> Float
|
| |
| bool | IsBlank (char ch) |
| | 字符串为空白字符,一般意义上(
\t空格)
|
| |
| std::vector< std::string_view > | ToView (const std::vector< std::string > &a) |
| | 转换为 std::vector<std::string_view>
|
| |
| bool | IsBlank (std::string_view str) |
| | 字符串为空白(全为
\t空格)
|
| |
| std::string_view | EraseBlankBoth (std::string_view str) |
| | 字符串删除首尾空字符
|
| |
| int | toInt (std::string_view str, int default_v=0) |
| | 转为整数,失败返回设定的默认值
|
| |
| unsigned | toUint (std::string_view str, unsigned default_v=0) |
| |
| int64_t | toInt64 (std::string_view str, int64_t default_v=0) |
| | 转为整数,失败返回设定的默认值
|
| |
| bool | getInt (std::string_view str, int &ret) |
| | 转为整数,失败不修改原值
|
| |
| bool | toBool (std::string_view str, bool default_v=false) |
| | 字符串 -> bool
|
| |
| bool | getByte (std::string_view str, std::byte &ret) |
| | 转为单个字节,需要十六进制,失败不修改原值
|
| |
| template<std::size_t N> |
| Array< int, N > | toPoint (std::string_view str, char d=',') |
| | 字符串 -> Point
|
| |
| template<std::size_t N> |
| Array< Float, N > | toPosition (std::string_view str, char d=',') |
| | 字符串 -> Position
|
| |
| Point2 | toPoint2 (std::string_view str, char d=',') |
| |
| Position | toPosition2 (std::string_view str, char d=',') |
| |
| constexpr StringType | GetType (std::string_view str) |
| | 返回字符串类型
|
| |
| std::string | AddQuotes (std::string_view str, char quotes='\"') |
| | 两侧添加引号
|
| |
| size_t | Wcwidth (wchar_t ch) |
| | 获取宽字符宽度(控制台显示优化)
|
| |
| std::string | FillEndl (std::string_view str, char ch=' ') |
| | 多行文本填充字符至一样宽(控制台显示优化)
|
| |
| constexpr std::string_view | GetNotFileName () |
| | 返回不能作为文件名的字符
|
| |