Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(575)

Side by Side Diff: src/pkg/exp/locale/collate/colltab.go

Issue 7058051: code review 7058051: exp/locale/collate: preparation for adding Search API. ... (Closed)
Patch Set: diff -r 8906cf341c9b https://go.googlecode.com/hg Created 11 years, 2 months ago
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/pkg/exp/locale/collate/collate.go ('k') | src/pkg/exp/locale/collate/export.go » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2013 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file.
4
5 package collate
6
7 // A type that implements Weigher can be used as a source for Collator and Searc her.
rsc 2013/01/18 21:55:56 s/type that implements //
mpvl 2013/01/23 13:11:19 Done.
8 type Weigher interface {
9 // Start finds the start of the segment that includes position p.
10 Start(p int, b []byte) int
11
12 // StartString finds the start of the segment that includes position p.
13 StartString(p int, s string) int
14
15 // AppendNext appends Elems to buf corresponding to the longest match
16 // of a single character or contraction from the start of s.
17 // It returns the new buf and the number of bytes consumed.
18 AppendNext(buf []Elem, s []byte) (ce []Elem, n int)
19
20 // AppendNextString appends Elems to buf corresponding to the longest ma tch
21 // of a single character or contraction from the start of s.
22 // It returns the new buf and the number of bytes consumed.
23 AppendNextString(buf []Elem, s string) (ce []Elem, n int)
24
25 // Domain returns a slice of all single characters and contractions for which
26 // collation elements are defined in this table.
27 Domain() []string
28 }
OLDNEW
« no previous file with comments | « src/pkg/exp/locale/collate/collate.go ('k') | src/pkg/exp/locale/collate/export.go » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b