XsltFunctions.StartsWith(String, String) 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
starts-with根据 W3C 规范实现 XPath 函数。
此 API 支持产品基础结构,不能在代码中直接使用。
public:
static bool StartsWith(System::String ^ s1, System::String ^ s2);
public static bool StartsWith(string s1, string s2);
static member StartsWith : string * string -> bool
Public Shared Function StartsWith (s1 As String, s2 As String) As Boolean
参数
- s1
- String
字符串,其开头与 s2.
- s2
- String
要与开头进行比较的 s1字符串。
返回
true 如果第一个参数字符串以第二个参数字符串开头,则为 ;否则,为 false.