當前位置: 首頁>>代碼示例>>Golang>>正文


Golang unicode.SpecialCase類代碼示例

本文整理匯總了Golang中unicode.SpecialCase的典型用法代碼示例。如果您正苦於以下問題:Golang SpecialCase類的具體用法?Golang SpecialCase怎麽用?Golang SpecialCase使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


在下文中一共展示了SpecialCase類的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Golang代碼示例。

示例1: ToTitleSpecial

// ToTitleSpecial returns a copy of the string s with all Unicode letters mapped to their
// title case, giving priority to the special casing rules.
func ToTitleSpecial(_case unicode.SpecialCase, s string) string {
	return Map(func(r rune) rune { return _case.ToTitle(r) }, s)
}
開發者ID:aubonbeurre,項目名稱:gcc,代碼行數:5,代碼來源:strings.go

示例2: ToLowerSpecial

// ToLowerSpecial returns a copy of the string s with all Unicode letters mapped to their
// lower case, giving priority to the special casing rules.
func ToLowerSpecial(_case unicode.SpecialCase, s string) string {
	return Map(func(r int) int { return _case.ToLower(r) }, s)
}
開發者ID:go-nosql,項目名稱:golang,代碼行數:5,代碼來源:strings.go

示例3: ToLowerSpecial

// ToLowerSpecial returns a copy of the byte array s with all Unicode letters mapped to their
// lower case, giving priority to the special casing rules.
func ToLowerSpecial(_case unicode.SpecialCase, s []byte) []byte {
	return Map(func(r int) int { return _case.ToLower(r) }, s)
}
開發者ID:IntegerCompany,項目名稱:linaro-android-gcc,代碼行數:5,代碼來源:bytes.go

示例4: ToLowerSpecial

// ToLowerSpecial returns a copy of the byte slice s with all Unicode letters mapped to their
// lower case, giving priority to the special casing rules.
func ToLowerSpecial(c unicode.SpecialCase, s []byte) []byte {
	return Map(func(r rune) rune { return c.ToLower(r) }, s)
}
開發者ID:achanda,項目名稱:go,代碼行數:5,代碼來源:bytes.go

示例5: ToLowerSpecial

// ToLowerSpecial returns a copy of the string s with all Unicode letters mapped to their
// lower case, giving priority to the special casing rules.
func ToLowerSpecial(c unicode.SpecialCase, s string) string {
	return Map(func(r rune) rune { return c.ToLower(r) }, s)
}
開發者ID:achanda,項目名稱:go,代碼行數:5,代碼來源:strings.go


注:本文中的unicode.SpecialCase類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。