Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

genbrk(1) [centos man page]

GENBRK(1)							 ICU 50.1.2 Manual							 GENBRK(1)

NAME
genbrk - Compiles ICU break iteration rules source files into binary data files SYNOPSIS
genbrk [ -h, -?, --help ] [ -V, --version ] [ -c, --copyright ] [ -v, --verbose ] [ -d, --destdir destination ] [ -i, --icudatadir direc- tory ] -r, --rules rule-file -o, --out output-file DESCRIPTION
genbrk reads the break (boundary) rule source code from rule-file and creates a break iteration data file. Normally this data file has the .brk extension. The details of the rule syntax can be found in ICU's User Guide. OPTIONS
-h, -?, --help Print help about usage and exit. -V, --version Print the version of genbrk and exit. -c, --copyright Embeds the standard ICU copyright into the output-file. -v, --verbose Display extra informative messages during execution. -d, --destdir destination Set the destination directory of the output-file to destination. -i, --icudatadir directory Look for any necessary ICU data files in directory. For example, the file pnames.icu must be located when ICU's data is not built as a shared library. The default ICU data directory is specified by the environment variable ICU_DATA. Most configurations of ICU do not require this argument. -r, --rules rule-file The source file to read. -o, --out output-file The output data file to write. CAVEATS
When the rule-file contains a byte order mark (BOM) at the beginning of the file, which is the Unicode character U+FEFF, then the rule-file is interpreted as Unicode. Without the BOM, the file is interpreted in the current operating system default codepage. In order to elimi- nate any ambiguity of the encoding for how the rule-file was written, it is recommended that you write this file in UTF-8 with the BOM. ENVIRONMENT
ICU_DATA Specifies the directory containing ICU data. Defaults to /usr/share/icu/50.1.2/. Some tools in ICU depend on the presence of the trailing slash. It is thus important to make sure that it is present if ICU_DATA is set. AUTHORS
George Rhoten Andy Heninger VERSION
1.0 COPYRIGHT
Copyright (C) 2005 International Business Machines Corporation and others SEE ALSO
http://www.icu-project.org/userguide/boundaryAnalysis.html ICU MANPAGE
2 December 2005 GENBRK(1)

Check Out this Related Man Page

YAZ-ICU(1)							     Commands								YAZ-ICU(1)

NAME
yaz-icu - YAZ ICU utility SYNOPSIS
yaz-icu [-c config] [-p opt] [-s] [-x] [infile] DESCRIPTION
yaz-icu is utility which demonstrates the ICU chain module of yaz. (yaz/icu.h). The utility can be used in two ways. It may read some text using an XML configuration for configuring ICU and show text analysis. This mode is triggered by option -c which specififies the configuration to be used. The input file is read from standard input or from a file if infile is specified. The utility may also show ICU information. This is triggered by option -p. OPTIONS
-c config Specifies the file containing ICU chain configuration which is XML based. -p type Specifies extra information to be printed about the ICU system. If type is c then ICU converters are printed. If type is l available locales are printed. If type is t available transliterators are printed. -s Specifies that output should include sort key as well. Note that sort key differs between ICU versions. -x Specifies that output should be XML based rather than "text" based. ICU CHAIN CONFIGURATION
The ICU chain configuration speicifies one or more rules to convert text data into tokens. The configuration format is XML based. The toplevel element must be named icu_chain. The icu_chain element has one required attribute locale which specifies the ICU locale to be used in the conversion steps. The icu_chain element must include elements where each element specifies a conversion step. The conversion is performed in the order in which the conversion steps are specified. Each conversion element takes one attribute: rule which serves as argument to the conversion step. The following conversion elements are available: casemap Converts case and rule specifies how: l Lowercase using ICU function u_strToLower. u Upper case using ICU function u_strToUpper. t To title using UCU function u_strToTitle. f Fold case using ICU function u_strFoldCase. display This is a meta step which specifies that a term/token is to be displayed. This term is retrieved in an application using function icu_chain_token_display (yaz/icu.h). transform Specifies an ICU transform rule using a transliterator Identifier. The rule attribute is the transliterator Identifier. See ICU Transforms[1] for more information. transliterate Specifies a rule-based transliterator. The rule attribute is the custom transformation rule to be used. See ICU Transforms[1] for more information. tokenize Breaks / tokenizes a string into components using ICU functions ubrk_open, ubrk_setText, .. . The rule is one of: l Line. ICU: UBRK_LINE. s Sentence. ICU: UBRK_SENTENCE. w Word. ICU: UBRK_WORD. c Character. ICU: UBRK_CHARACTER. t Title. ICU: UBRK_TITLE. EXAMPLES
The following command analyzes text in file text using ICU chain configuration chain.xml: cat text | yaz-icu -c chain.xml The chain.xml might look as follows: <icu_chain locale="en"> <transform rule="[:Control:] Any-Remove"/> <tokenize rule="w"/> <transform rule="[[:WhiteSpace:][:Punctuation:]] Remove"/> <transliterate rule="xy > z"/> <display/> <casemap rule="l"/> </icu_chain> SEE ALSO
yaz(7) ICU Home[2] ICU Transforms[1] NOTES
1. ICU Transforms http://userguide.icu-project.org/transforms/general 2. ICU Home http://www.icu-project.org/ YAZ 4.2.30 04/16/2012 YAZ-ICU(1)
Man Page