Lines Matching refs:rule
27 #include "rule.h"
34 Ruleset::Ruleset(AddressField field, scoped_ptr<Rule> rule)
40 rule_(rule.Pass()),
91 scoped_ptr<Rule> rule) {
93 assert(rule != NULL);
94 language_codes_[language_code] = rule.release();
103 const Rule& Ruleset::GetLanguageCodeRule(
105 std::map<std::string, const Rule*>::const_iterator it =
143 std::make_pair(Rule::KEY, new Trie<const Ruleset*>));
145 std::make_pair(Rule::NAME, new Trie<const Ruleset*>));
147 std::make_pair(Rule::LATIN_NAME, new Trie<const Ruleset*>));
157 Rule::IdentityField identity_field,
207 const Rule& rule = ruleset->GetLanguageCodeRule(language_code);
220 identity_field_tries->find(Rule::KEY);
226 identity_field_it = identity_field_tries->find(Rule::NAME);
232 identity_field_it = identity_field_tries->find(Rule::LATIN_NAME);
238 if (!rule.GetKey().empty()) {
240 canonicalizer_->CanonicalizeString(rule.GetKey()), ruleset);
243 if (!rule.GetName().empty()) {
245 canonicalizer_->CanonicalizeString(rule.GetName()), ruleset);
248 if (!rule.GetLatinName().empty()) {
250 canonicalizer_->CanonicalizeString(rule.GetLatinName()), ruleset);