一款简单易用的基础网络通讯组件库。

SystemTextJsonStringToClassSerializerFormatterTStateTrySerialize 方法

尝试将对象序列化为字符串。

Definition

命名空间: TouchSocket.Core
程序集: TouchSocket.Core (在 TouchSocket.Core.dll 中) 版本:4.0.0-beta.143+5fcca7a4e70968794985dc3793adc50531308be6
C#
public bool TrySerialize(
	TState state,
	 in Object target,
	out string source
)

参数

state  TState
状态对象。
target  Object
要序列化的对象。
source  String
序列化后的字符串。

返回值

Boolean
如果序列化成功,则为;否则为

参见