Rebol 编程/find
外观
< Rebol 编程
FIND series value /part range /only /case /any /with wild /skip size /match /tail /last /reverse
在系列中查找值并返回该值开始处的系列。
FIND 是一个动作值。
- series -- (类型:系列对象端口位集)
- value -- (类型:任何类型)
- /part -- 将搜索限制为给定长度或位置。
- range -- (类型:数字系列端口)
- /only -- 将系列值视为单个值。
- /case -- 字符区分大小写。
- /any -- 启用 * 和 ? 通配符。
- /with -- 允许自定义通配符。
- wild -- 指定 * 和 ? 的备选方案 (类型:字符串)
- /skip -- 将系列视为固定大小的记录
- size -- (类型:整数)
- /match -- 执行比较并返回匹配的尾部。
- /tail -- 返回字符串的末尾。
- /last -- 从字符串末尾反向。
- /reverse -- 从当前位置反向。
find: native[
{Finds a value in a series and returns the series at the start of it.}
series [series! object! port! bitset!]
value [any-type!]
/part "Limits the search to a given length or position."
range [number! series! port!]
/only "Treats a series value as a single value."
/case "Characters are case-sensitive."
/any "Enables the * and ? wildcards."
/with "Allows custom wildcards."
wild [string!] "Specifies alternates for * and ?"
/skip "Treat the series as records of fixed size"
size [integer!]
/match {Performs comparison and returns the tail of the match.}
/tail "Returns the end of the string."
/last "Backwards from end of string."
/reverse "Backwards from the current position."
]