Neos\Eel\FlowQuery\FizzleParser::match_AttributeFilter PHP Method

match_AttributeFilter() public method

public match_AttributeFilter ( $stack = [] )
    function match_AttributeFilter($stack = array())
    {
        $matchrule = "AttributeFilter";
        $result = $this->construct($matchrule, $matchrule, null);
        $_146 = NULL;
        do {
            if (substr($this->string, $this->pos, 1) == '[') {
                $this->pos += 1;
                $result["text"] .= '[';
            } else {
                $_146 = FALSE;
                break;
            }
            $matcher = 'match_' . 'S';
            $key = $matcher;
            $pos = $this->pos;
            $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
            if ($subres !== FALSE) {
                $this->store($result, $subres);
            } else {
                $_146 = FALSE;
                break;
            }
            $_142 = NULL;
            do {
                $_140 = NULL;
                do {
                    $res_55 = $result;
                    $pos_55 = $this->pos;
                    $_72 = NULL;
                    do {
                        $stack[] = $result;
                        $result = $this->construct($matchrule, "Operator");
                        $_61 = NULL;
                        do {
                            $_59 = NULL;
                            do {
                                $res_56 = $result;
                                $pos_56 = $this->pos;
                                if (($subres = $this->literal('instanceof')) !== FALSE) {
                                    $result["text"] .= $subres;
                                    $_59 = TRUE;
                                    break;
                                }
                                $result = $res_56;
                                $this->pos = $pos_56;
                                if (($subres = $this->literal('!instanceof')) !== FALSE) {
                                    $result["text"] .= $subres;
                                    $_59 = TRUE;
                                    break;
                                }
                                $result = $res_56;
                                $this->pos = $pos_56;
                                $_59 = FALSE;
                                break;
                            } while (0);
                            if ($_59 === FALSE) {
                                $_61 = FALSE;
                                break;
                            }
                            $_61 = TRUE;
                            break;
                        } while (0);
                        if ($_61 === TRUE) {
                            $subres = $result;
                            $result = array_pop($stack);
                            $this->store($result, $subres, 'Operator');
                        }
                        if ($_61 === FALSE) {
                            $result = array_pop($stack);
                            $_72 = FALSE;
                            break;
                        }
                        $matcher = 'match_' . 'S';
                        $key = $matcher;
                        $pos = $this->pos;
                        $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                        if ($subres !== FALSE) {
                            $this->store($result, $subres);
                        } else {
                            $_72 = FALSE;
                            break;
                        }
                        $_69 = NULL;
                        do {
                            $_67 = NULL;
                            do {
                                $res_64 = $result;
                                $pos_64 = $this->pos;
                                $matcher = 'match_' . 'StringLiteral';
                                $key = $matcher;
                                $pos = $this->pos;
                                $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                if ($subres !== FALSE) {
                                    $this->store($result, $subres, "Operand");
                                    $_67 = TRUE;
                                    break;
                                }
                                $result = $res_64;
                                $this->pos = $pos_64;
                                $matcher = 'match_' . 'UnquotedOperand';
                                $key = $matcher;
                                $pos = $this->pos;
                                $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                if ($subres !== FALSE) {
                                    $this->store($result, $subres, "Operand");
                                    $_67 = TRUE;
                                    break;
                                }
                                $result = $res_64;
                                $this->pos = $pos_64;
                                $_67 = FALSE;
                                break;
                            } while (0);
                            if ($_67 === FALSE) {
                                $_69 = FALSE;
                                break;
                            }
                            $_69 = TRUE;
                            break;
                        } while (0);
                        if ($_69 === FALSE) {
                            $_72 = FALSE;
                            break;
                        }
                        $matcher = 'match_' . 'S';
                        $key = $matcher;
                        $pos = $this->pos;
                        $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                        if ($subres !== FALSE) {
                            $this->store($result, $subres);
                        } else {
                            $_72 = FALSE;
                            break;
                        }
                        $_72 = TRUE;
                        break;
                    } while (0);
                    if ($_72 === TRUE) {
                        $_140 = TRUE;
                        break;
                    }
                    $result = $res_55;
                    $this->pos = $pos_55;
                    $_138 = NULL;
                    do {
                        $matcher = 'match_' . 'Identifier';
                        $key = $matcher;
                        $pos = $this->pos;
                        $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                        if ($subres !== FALSE) {
                            $this->store($result, $subres, "Identifier");
                        } else {
                            $_138 = FALSE;
                            break;
                        }
                        $matcher = 'match_' . 'S';
                        $key = $matcher;
                        $pos = $this->pos;
                        $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                        if ($subres !== FALSE) {
                            $this->store($result, $subres);
                        } else {
                            $_138 = FALSE;
                            break;
                        }
                        $res_137 = $result;
                        $pos_137 = $this->pos;
                        $_136 = NULL;
                        do {
                            $stack[] = $result;
                            $result = $this->construct($matchrule, "Operator");
                            $_117 = NULL;
                            do {
                                $_115 = NULL;
                                do {
                                    $res_76 = $result;
                                    $pos_76 = $this->pos;
                                    if (($subres = $this->literal('instanceof')) !== FALSE) {
                                        $result["text"] .= $subres;
                                        $_115 = TRUE;
                                        break;
                                    }
                                    $result = $res_76;
                                    $this->pos = $pos_76;
                                    $_113 = NULL;
                                    do {
                                        $res_78 = $result;
                                        $pos_78 = $this->pos;
                                        if (($subres = $this->literal('!instanceof')) !== FALSE) {
                                            $result["text"] .= $subres;
                                            $_113 = TRUE;
                                            break;
                                        }
                                        $result = $res_78;
                                        $this->pos = $pos_78;
                                        $_111 = NULL;
                                        do {
                                            $res_80 = $result;
                                            $pos_80 = $this->pos;
                                            $matcher = 'match_' . 'PrefixMatch';
                                            $key = $matcher;
                                            $pos = $this->pos;
                                            $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                            if ($subres !== FALSE) {
                                                $this->store($result, $subres);
                                                $_111 = TRUE;
                                                break;
                                            }
                                            $result = $res_80;
                                            $this->pos = $pos_80;
                                            $_109 = NULL;
                                            do {
                                                $res_82 = $result;
                                                $pos_82 = $this->pos;
                                                $matcher = 'match_' . 'SuffixMatch';
                                                $key = $matcher;
                                                $pos = $this->pos;
                                                $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                                if ($subres !== FALSE) {
                                                    $this->store($result, $subres);
                                                    $_109 = TRUE;
                                                    break;
                                                }
                                                $result = $res_82;
                                                $this->pos = $pos_82;
                                                $_107 = NULL;
                                                do {
                                                    $res_84 = $result;
                                                    $pos_84 = $this->pos;
                                                    $matcher = 'match_' . 'SubstringMatch';
                                                    $key = $matcher;
                                                    $pos = $this->pos;
                                                    $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                                    if ($subres !== FALSE) {
                                                        $this->store($result, $subres);
                                                        $_107 = TRUE;
                                                        break;
                                                    }
                                                    $result = $res_84;
                                                    $this->pos = $pos_84;
                                                    $_105 = NULL;
                                                    do {
                                                        $res_86 = $result;
                                                        $pos_86 = $this->pos;
                                                        $matcher = 'match_' . 'ExactMatch';
                                                        $key = $matcher;
                                                        $pos = $this->pos;
                                                        $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                                        if ($subres !== FALSE) {
                                                            $this->store($result, $subres);
                                                            $_105 = TRUE;
                                                            break;
                                                        }
                                                        $result = $res_86;
                                                        $this->pos = $pos_86;
                                                        $_103 = NULL;
                                                        do {
                                                            $res_88 = $result;
                                                            $pos_88 = $this->pos;
                                                            $matcher = 'match_' . 'NotEqualMatch';
                                                            $key = $matcher;
                                                            $pos = $this->pos;
                                                            $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                                            if ($subres !== FALSE) {
                                                                $this->store($result, $subres);
                                                                $_103 = TRUE;
                                                                break;
                                                            }
                                                            $result = $res_88;
                                                            $this->pos = $pos_88;
                                                            $_101 = NULL;
                                                            do {
                                                                $res_90 = $result;
                                                                $pos_90 = $this->pos;
                                                                $matcher = 'match_' . 'LessThanOrEqualMatch';
                                                                $key = $matcher;
                                                                $pos = $this->pos;
                                                                $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                                                if ($subres !== FALSE) {
                                                                    $this->store($result, $subres);
                                                                    $_101 = TRUE;
                                                                    break;
                                                                }
                                                                $result = $res_90;
                                                                $this->pos = $pos_90;
                                                                $_99 = NULL;
                                                                do {
                                                                    $res_92 = $result;
                                                                    $pos_92 = $this->pos;
                                                                    $matcher = 'match_' . 'LessThanMatch';
                                                                    $key = $matcher;
                                                                    $pos = $this->pos;
                                                                    $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                                                    if ($subres !== FALSE) {
                                                                        $this->store($result, $subres);
                                                                        $_99 = TRUE;
                                                                        break;
                                                                    }
                                                                    $result = $res_92;
                                                                    $this->pos = $pos_92;
                                                                    $_97 = NULL;
                                                                    do {
                                                                        $res_94 = $result;
                                                                        $pos_94 = $this->pos;
                                                                        $matcher = 'match_' . 'GreaterThanOrEqualMatch';
                                                                        $key = $matcher;
                                                                        $pos = $this->pos;
                                                                        $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                                                        if ($subres !== FALSE) {
                                                                            $this->store($result, $subres);
                                                                            $_97 = TRUE;
                                                                            break;
                                                                        }
                                                                        $result = $res_94;
                                                                        $this->pos = $pos_94;
                                                                        $matcher = 'match_' . 'GreaterThanMatch';
                                                                        $key = $matcher;
                                                                        $pos = $this->pos;
                                                                        $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                                                        if ($subres !== FALSE) {
                                                                            $this->store($result, $subres);
                                                                            $_97 = TRUE;
                                                                            break;
                                                                        }
                                                                        $result = $res_94;
                                                                        $this->pos = $pos_94;
                                                                        $_97 = FALSE;
                                                                        break;
                                                                    } while (0);
                                                                    if ($_97 === TRUE) {
                                                                        $_99 = TRUE;
                                                                        break;
                                                                    }
                                                                    $result = $res_92;
                                                                    $this->pos = $pos_92;
                                                                    $_99 = FALSE;
                                                                    break;
                                                                } while (0);
                                                                if ($_99 === TRUE) {
                                                                    $_101 = TRUE;
                                                                    break;
                                                                }
                                                                $result = $res_90;
                                                                $this->pos = $pos_90;
                                                                $_101 = FALSE;
                                                                break;
                                                            } while (0);
                                                            if ($_101 === TRUE) {
                                                                $_103 = TRUE;
                                                                break;
                                                            }
                                                            $result = $res_88;
                                                            $this->pos = $pos_88;
                                                            $_103 = FALSE;
                                                            break;
                                                        } while (0);
                                                        if ($_103 === TRUE) {
                                                            $_105 = TRUE;
                                                            break;
                                                        }
                                                        $result = $res_86;
                                                        $this->pos = $pos_86;
                                                        $_105 = FALSE;
                                                        break;
                                                    } while (0);
                                                    if ($_105 === TRUE) {
                                                        $_107 = TRUE;
                                                        break;
                                                    }
                                                    $result = $res_84;
                                                    $this->pos = $pos_84;
                                                    $_107 = FALSE;
                                                    break;
                                                } while (0);
                                                if ($_107 === TRUE) {
                                                    $_109 = TRUE;
                                                    break;
                                                }
                                                $result = $res_82;
                                                $this->pos = $pos_82;
                                                $_109 = FALSE;
                                                break;
                                            } while (0);
                                            if ($_109 === TRUE) {
                                                $_111 = TRUE;
                                                break;
                                            }
                                            $result = $res_80;
                                            $this->pos = $pos_80;
                                            $_111 = FALSE;
                                            break;
                                        } while (0);
                                        if ($_111 === TRUE) {
                                            $_113 = TRUE;
                                            break;
                                        }
                                        $result = $res_78;
                                        $this->pos = $pos_78;
                                        $_113 = FALSE;
                                        break;
                                    } while (0);
                                    if ($_113 === TRUE) {
                                        $_115 = TRUE;
                                        break;
                                    }
                                    $result = $res_76;
                                    $this->pos = $pos_76;
                                    $_115 = FALSE;
                                    break;
                                } while (0);
                                if ($_115 === FALSE) {
                                    $_117 = FALSE;
                                    break;
                                }
                                $_117 = TRUE;
                                break;
                            } while (0);
                            if ($_117 === TRUE) {
                                $subres = $result;
                                $result = array_pop($stack);
                                $this->store($result, $subres, 'Operator');
                            }
                            if ($_117 === FALSE) {
                                $result = array_pop($stack);
                                $_136 = FALSE;
                                break;
                            }
                            $matcher = 'match_' . 'S';
                            $key = $matcher;
                            $pos = $this->pos;
                            $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                            if ($subres !== FALSE) {
                                $this->store($result, $subres);
                            } else {
                                $_136 = FALSE;
                                break;
                            }
                            $_133 = NULL;
                            do {
                                $_131 = NULL;
                                do {
                                    $res_120 = $result;
                                    $pos_120 = $this->pos;
                                    $matcher = 'match_' . 'StringLiteral';
                                    $key = $matcher;
                                    $pos = $this->pos;
                                    $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                    if ($subres !== FALSE) {
                                        $this->store($result, $subres, "Operand");
                                        $_131 = TRUE;
                                        break;
                                    }
                                    $result = $res_120;
                                    $this->pos = $pos_120;
                                    $_129 = NULL;
                                    do {
                                        $res_122 = $result;
                                        $pos_122 = $this->pos;
                                        $matcher = 'match_' . 'NumberLiteral';
                                        $key = $matcher;
                                        $pos = $this->pos;
                                        $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                        if ($subres !== FALSE) {
                                            $this->store($result, $subres, "Operand");
                                            $_129 = TRUE;
                                            break;
                                        }
                                        $result = $res_122;
                                        $this->pos = $pos_122;
                                        $_127 = NULL;
                                        do {
                                            $res_124 = $result;
                                            $pos_124 = $this->pos;
                                            $matcher = 'match_' . 'BooleanLiteral';
                                            $key = $matcher;
                                            $pos = $this->pos;
                                            $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                            if ($subres !== FALSE) {
                                                $this->store($result, $subres, "Operand");
                                                $_127 = TRUE;
                                                break;
                                            }
                                            $result = $res_124;
                                            $this->pos = $pos_124;
                                            $matcher = 'match_' . 'UnquotedOperand';
                                            $key = $matcher;
                                            $pos = $this->pos;
                                            $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                                            if ($subres !== FALSE) {
                                                $this->store($result, $subres, "Operand");
                                                $_127 = TRUE;
                                                break;
                                            }
                                            $result = $res_124;
                                            $this->pos = $pos_124;
                                            $_127 = FALSE;
                                            break;
                                        } while (0);
                                        if ($_127 === TRUE) {
                                            $_129 = TRUE;
                                            break;
                                        }
                                        $result = $res_122;
                                        $this->pos = $pos_122;
                                        $_129 = FALSE;
                                        break;
                                    } while (0);
                                    if ($_129 === TRUE) {
                                        $_131 = TRUE;
                                        break;
                                    }
                                    $result = $res_120;
                                    $this->pos = $pos_120;
                                    $_131 = FALSE;
                                    break;
                                } while (0);
                                if ($_131 === FALSE) {
                                    $_133 = FALSE;
                                    break;
                                }
                                $_133 = TRUE;
                                break;
                            } while (0);
                            if ($_133 === FALSE) {
                                $_136 = FALSE;
                                break;
                            }
                            $matcher = 'match_' . 'S';
                            $key = $matcher;
                            $pos = $this->pos;
                            $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
                            if ($subres !== FALSE) {
                                $this->store($result, $subres);
                            } else {
                                $_136 = FALSE;
                                break;
                            }
                            $_136 = TRUE;
                            break;
                        } while (0);
                        if ($_136 === FALSE) {
                            $result = $res_137;
                            $this->pos = $pos_137;
                            unset($res_137);
                            unset($pos_137);
                        }
                        $_138 = TRUE;
                        break;
                    } while (0);
                    if ($_138 === TRUE) {
                        $_140 = TRUE;
                        break;
                    }
                    $result = $res_55;
                    $this->pos = $pos_55;
                    $_140 = FALSE;
                    break;
                } while (0);
                if ($_140 === FALSE) {
                    $_142 = FALSE;
                    break;
                }
                $_142 = TRUE;
                break;
            } while (0);
            if ($_142 === FALSE) {
                $_146 = FALSE;
                break;
            }
            $matcher = 'match_' . 'S';
            $key = $matcher;
            $pos = $this->pos;
            $subres = $this->packhas($key, $pos) ? $this->packread($key, $pos) : $this->packwrite($key, $pos, $this->{$matcher}(array_merge($stack, array($result))));
            if ($subres !== FALSE) {
                $this->store($result, $subres);
            } else {
                $_146 = FALSE;
                break;
            }
            if (substr($this->string, $this->pos, 1) == ']') {
                $this->pos += 1;
                $result["text"] .= ']';
            } else {
                $_146 = FALSE;
                break;
            }
            $_146 = TRUE;
            break;
        } while (0);
        if ($_146 === TRUE) {
            return $this->finalise($result);
        }
        if ($_146 === FALSE) {
            return FALSE;
        }
    }