Skip to content

M_Cyjb_StringView_TryConcat

CYJB edited this page Mar 20, 2024 · 2 revisions

StringView.TryConcat 方法

尝试连接指定的字符串视图。

Namespace: Cyjb
Assembly: Cyjb (in Cyjb.dll) Version: 1.0.23+7750dd8e971297c5fa962a3bee37fb78f72793f6

语法

C#

public bool TryConcat(
	StringView other,
	out StringView result
)

参数

 

other
Type: Cyjb.StringView
要连接的字符串视图。
result
Type: Cyjb.StringView
连接的结果字符串视图。

返回值

Type: Boolean
如果当前字符串视图与 other 是从相同字符串创建的, 且首尾相接时表示可以连接,返回 true,并将连接结果通过 result 返回; 或者两个字符串视图其中之一为空,不需要连接时也会返回 true; 否则返回 falseresult 会返回空。

参见

Reference

StringView 结构
Cyjb 命名空间

Clone this wiki locally