Lines Matching refs:token

91 		Token token(TOKEN_STRING, fPos, versionString.Length());
92 _ParseVersionValue(token, &_version, revisionIsOptional);
116 Token token(TOKEN_STRING, fPos, expressionString.Length());
141 Token token(TOKEN_STRING, fPos, expressionString.Length());
164 // or '\n' and return it as a token afterwards.
305 BString error = BString("unknown token '") << *fPos << "' encountered";
311 BPackageInfo::Parser::_RewindTo(const Token& token)
313 fPos = token.pos;
456 BPackageInfo::Parser::_ParseResolvable(const Token& token,
459 if (token.type != TOKEN_STRING) {
461 token.pos);
465 if (!_IsValidResolvableName(token.text, &errorPos)) {
467 token.pos + errorPos);
495 _value.SetTo(token.text, version, compatibleVersion);
500 BPackageInfo::Parser::_ParseResolvableExpression(const Token& token,
503 if (token.type != TOKEN_STRING) {
505 token.pos);
509 if (!_IsValidResolvableName(token.text, &errorPos)) {
511 token.pos + errorPos);
530 token.pos);
533 *_basePackage = token.text;
550 _value.SetTo(token.text, resolvableOperator, version);
568 Token token = _NextToken();
569 if (token.type == TOKEN_CLOSE_BRACE)
572 if (token.type == TOKEN_ITEM_SEPARATOR)
575 elementParser(token);
601 virtual void operator()(const Token& token)
603 if (token.type != TOKEN_STRING)
604 throw ParseError("expected string", token.pos);
608 if (!_IsValidResolvableName(token.text, &errorPos)) {
610 token.pos + errorPos);
614 BString element(token.text);
619 stringValidator->Validate(element, token.pos);
642 virtual void operator()(const Token& token)
644 if (token.type != TOKEN_STRING)
645 throw ParseError("expected word (a flag)", token.pos);
647 if (token.text.ICompare("approve_license") == 0)
649 else if (token.text.ICompare("system_package") == 0)
654 token.pos);
681 virtual void operator()(const Token& token)
684 parser._ParseResolvable(token, expression);
712 virtual void operator()(const Token& token)
715 parser._ParseResolvableExpression(token, expression, basePackage);
740 virtual void operator()(const Token& token)
742 if (token.type != TOKEN_STRING) {
744 token.pos);
778 if (!infos->AddItem(new BGlobalWritableFileInfo(token.text,
805 virtual void operator()(const Token& token)
807 if (token.type != TOKEN_STRING) {
809 token.pos);
838 ? !infos->AddItem(new BUserSettingsFileInfo(token.text, true))
839 : !infos->AddItem(new BUserSettingsFileInfo(token.text,
864 virtual void operator()(const Token& token)
866 if (token.type != TOKEN_STRING
867 || !BUser::IsValidUserName(token.text)) {
868 throw ParseError("expected a user name", token.pos);
949 if (!users->AddItem(new BUser(token.text, realName, home, shell,