/*
**********************************************************************
-* Copyright (C) 1999-2004, International Business Machines
+* Copyright (C) 1999-2006, International Business Machines
* Corporation and others. All Rights Reserved.
**********************************************************************
* Date Name Description
return;
}
- TransliteratorParser parser;
+ TransliteratorParser parser(status);
parser.parse(rules, direction, parseError, status);
if (U_FAILURE(status)) {
return;
}
- if (parser.idBlock.length() != 0 ||
- parser.compoundFilter != NULL) {
+ if (parser.idBlockVector.size() != 0 ||
+ parser.compoundFilter != NULL ||
+ parser.dataVector.size() == 0) {
status = U_INVALID_RBT_SYNTAX; // ::ID blocks disallowed in RBT
return;
}
- fData = parser.orphanData();
+ fData = (TransliterationRuleData*)parser.dataVector.orphanElementAt(0);
setMaximumContextLength(fData->ruleSet.getMaximumContextLength());
}