• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/ap/gpl/timemachine/libxml2-2.7.2/

Lines Matching defs:sub

86     XML_REGEXP_SUBREG,  /* used for () sub regexps */
6389 * of sub-expressions pointers *
7135 xmlExpCheckCard(xmlExpNodePtr exp, xmlExpNodePtr sub) {
7138 if (sub->c_max == -1) {
7141 } else if ((exp->c_max >= 0) && (exp->c_max < sub->c_max)) {
7145 if ((IS_NILLABLE(sub)) && (!IS_NILLABLE(exp)))
7152 xmlExpNodePtr sub);
7157 * @sub: the subexpression
7161 * Check if exp is a multiple of sub, i.e. if there is a finite number n
7162 * so that sub{n} subsume exp
7169 xmlExpDivide(xmlExpCtxtPtr ctxt, xmlExpNodePtr exp, xmlExpNodePtr sub,
7177 if (IS_NILLABLE(exp) && (!IS_NILLABLE(sub))) return(0);
7180 sub->ref++;
7182 sub, NULL, NULL, i, i);
7222 * @sub: the subexpression
7230 xmlExpExpDeriveInt(xmlExpCtxtPtr ctxt, xmlExpNodePtr exp, xmlExpNodePtr sub) {
7239 if ((exp == sub) && (exp->c_max >= 0)) {
7241 printf("Equal(exp, sub) and finite -> Empty\n");
7246 * decompose sub sequence first
7248 if (sub->type == XML_EXP_EMPTY) {
7250 printf("Empty(sub) -> Empty\n");
7255 if (sub->type == XML_EXP_SEQ) {
7257 printf("Seq(sub) -> decompose\n");
7259 tmp = xmlExpExpDeriveInt(ctxt, exp, sub->exp_left);
7264 ret = xmlExpExpDeriveInt(ctxt, tmp, sub->exp_right);
7268 if (sub->type == XML_EXP_OR) {
7270 printf("Or(sub) -> decompose\n");
7272 tmp = xmlExpExpDeriveInt(ctxt, exp, sub->exp_left);
7277 ret = xmlExpExpDeriveInt(ctxt, exp, sub->exp_right);
7284 if (!xmlExpCheckCard(exp, sub)) {
7286 printf("CheckCard(exp, sub) failed -> Forbid\n");
7292 if (sub == emptyExp)
7304 if (sub->type == XML_EXP_ATOM) {
7306 if (exp->exp_str == sub->exp_str) {
7317 if ((sub->type == XML_EXP_COUNT) &&
7318 (sub->exp_max == 1) &&
7319 (sub->exp_left->type == XML_EXP_ATOM)) {
7321 if (exp->exp_str == sub->exp_left->exp_str) {
7338 if (xmlExpCheckCard(exp->exp_left, sub)) {
7343 ret = xmlExpExpDeriveInt(ctxt, exp->exp_left, sub);
7365 if (sub->type == XML_EXP_COUNT) {
7369 printf("Seq: sub is a count\n");
7371 ret = xmlExpExpDeriveInt(ctxt, exp->exp_left, sub->exp_left);
7378 if (sub->exp_max < 0)
7381 max = sub->exp_max -1;
7382 if (sub->exp_min > 0)
7383 min = sub->exp_min -1;
7392 sub->exp_left->ref++;
7394 sub->exp_left, NULL, NULL, min, max);
7411 ret = xmlExpExpDeriveInt(ctxt, exp->exp_left, sub);
7414 tmp = xmlExpExpDeriveInt(ctxt, exp->exp_right, sub);
7423 if (sub->type == XML_EXP_COUNT) {
7427 tmp = xmlExpExpDeriveInt(ctxt, exp->exp_left, sub->exp_left);
7436 mult = xmlExpDivide(ctxt, sub->exp_left, exp->exp_left,
7444 if (sub->exp_max == -1) {
7447 if (exp->exp_min <= sub->exp_min * mult)
7450 min = exp->exp_min - sub->exp_min * mult;
7463 if (exp->exp_min > sub->exp_min * mult) {
7465 min = exp->exp_min - sub->exp_min * mult;
7471 if (exp->exp_max < sub->exp_max * mult) {
7478 if (sub->exp_max * mult > exp->exp_min)
7481 min = exp->exp_min - sub->exp_max * mult;
7482 max = exp->exp_max - sub->exp_max * mult;
7495 } else if (sub->exp_max == -1) {
7497 if (exp->exp_min <= sub->exp_min) {
7508 min = exp->exp_min - sub->exp_min;
7510 } else if (exp->exp_min > sub->exp_min) {
7525 if (exp->exp_min > sub->exp_min) {
7527 min = exp->exp_min - sub->exp_min;
7533 if (exp->exp_max < sub->exp_max) {
7540 if (sub->exp_max > exp->exp_min)
7543 min = exp->exp_min - sub->exp_max;
7544 max = exp->exp_max - sub->exp_max;
7560 tmp = xmlExpExpDeriveInt(ctxt, exp->exp_left, sub);
7595 if (IS_NILLABLE(sub)) {
7618 len = xmlExpGetStartInt(ctxt, sub, tab, ctxt->tabSize, 0);
7629 len = xmlExpGetStartInt(ctxt, sub, tab, ctxt->tabSize, 0);
7638 tmp2 = xmlExpStringDeriveInt(ctxt, sub, tab[i]);
7673 * @sub: the subexpression
7675 * Evaluates the expression resulting from @exp consuming a sub expression @sub
7684 xmlExpExpDerive(xmlExpCtxtPtr ctxt, xmlExpNodePtr exp, xmlExpNodePtr sub) {
7685 if ((exp == NULL) || (ctxt == NULL) || (sub == NULL))
7691 if (IS_NILLABLE(sub) && (!IS_NILLABLE(exp))) {
7697 if (xmlExpCheckCard(exp, sub) == 0) {
7699 printf("sub generate longuer sequances than exp : can't subsume\n");
7703 return(xmlExpExpDeriveInt(ctxt, exp, sub));
7710 * @sub: the subexpression
7712 * Check whether @exp accepts all the languages accexpted by @sub
7718 xmlExpSubsume(xmlExpCtxtPtr ctxt, xmlExpNodePtr exp, xmlExpNodePtr sub) {
7721 if ((exp == NULL) || (ctxt == NULL) || (sub == NULL))
7725 * TODO: speedup by checking the language of sub is a subset of the
7731 if (IS_NILLABLE(sub) && (!IS_NILLABLE(exp))) {
7737 if (xmlExpCheckCard(exp, sub) == 0) {
7739 printf("sub generate longuer sequances than exp : can't subsume\n");
7743 tmp = xmlExpExpDeriveInt(ctxt, exp, sub);