Skip to content

Commit f603973

Browse files
committed
4.4 CSM API String to TimeStamp.vi
1 parent 2ca22f4 commit f603973

File tree

4 files changed

+24
-2
lines changed

4 files changed

+24
-2
lines changed
Binary file not shown.
Binary file not shown.
Binary file not shown.

help/NEVSTOP/Communicable State Machine(CSM)/Examples/Addons - API String Arguments Support(CN).md

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616

1717
- step1: 所有的普通类型,空字符串会被转换为参考数据类型连接的数值。
1818
- step2: String 数据类型,空字符串会被转换为空字符串。
19+
- step3: timestamp 数据类型,空字符串会转换为当前时间。
1920

2021
## 2. CSM API String to Typical datatypes.vi
2122

@@ -135,7 +136,7 @@ e、-e、pi、-pi、inf、+inf、-inf 和 NaN 等特殊浮点数值不支持单
135136

136137
#### Overview
137138

138-
本范例用于演示 APIString 对于复数的支持。
139+
本范例用于演示 API String 对于复数的支持。
139140

140141
#### Introduction
141142

@@ -145,4 +146,25 @@ API String 支持复数类型。a+bi 或 a-bi 格式表示复数。其中 a 和
145146
- 空字符串将转换为原型(Prototype)的输入值。
146147
- 标签-数据对(Tag:Value)可以被正确解析。标签仅用于提高可读性,转换过程中会被忽略。
147148

148-
###
149+
### Timestamp 类型(4.4 CSM API String to Timestamp.vi)
150+
151+
#### Overview
152+
153+
本范例用于演示 API String 对于时间戳的支持。
154+
155+
#### Introduction
156+
157+
API String 时间戳的标准格式为:TimeStamp_String(Format_String)。其中 Format_String 用于解析 TimeStamp_String。
158+
159+
特殊情况说明:
160+
- 当字符串不包含 Format_String 时,TimeStamp_String 应符合 RFC3339 标准格式。
161+
- "2023-10-31T14:49:39.597Z" 为有效的表达方式.
162+
- "2023-10-31T22:49:39.597+08:00" 为有效的表达方式.
163+
- 对于时间戳,空字符串将转换为当前时间。
164+
165+
#### steps
166+
167+
- step1: 空字符串转换为当前时间
168+
- step2: 标准格式转换为时间戳
169+
- step3: timestamp转换为 API String,并被正确解析回时间戳数据类型
170+
- step4: TimeStamp_String(Format_String)格式的示例

0 commit comments

Comments
 (0)