class Parser

Defined at line 60 of file ../../third_party/android/platform/system/tools/aidl/parser.h

Public Methods

void Parser (const Parser & )

non-copyable, non-assignable

Defined at line 63 of file ../../third_party/android/platform/system/tools/aidl/parser.h

Parser & operator= (const Parser & )

Defined at line 64 of file ../../third_party/android/platform/system/tools/aidl/parser.h

void AddError ()

Defined at line 73 of file ../../third_party/android/platform/system/tools/aidl/parser.h

bool HasError ()

Defined at line 74 of file ../../third_party/android/platform/system/tools/aidl/parser.h

const std::string & FileName ()

Defined at line 76 of file ../../third_party/android/platform/system/tools/aidl/parser.h

void ~Parser ()
const AidlDocument * Parse (const std::string & filename, const android::aidl::IoDelegate & io_delegate, AidlTypenames & typenames, bool is_preprocessed)

Parse contents of file |filename|. Should only be called once.

void * Scanner ()

Defined at line 77 of file ../../third_party/android/platform/system/tools/aidl/parser.h

AidlDocument * GetDocument ()

Defined at line 79 of file ../../third_party/android/platform/system/tools/aidl/parser.h

void SetTypeParameters (AidlTypeSpecifier * type, std::vector<std::unique_ptr<AidlTypeSpecifier>> * type_args)

This restricts the grammar to something more reasonable. One alternative

would be to support multiple sets of type specifiers in our AST, but then a

lot of later code would have to deal with this more complicated type. So,

in order to keep the AST simpler, restricting the grammar here.

Takes ownership of type_args, modifies type.

void CheckValidTypeName (const AidlToken & token, const AidlLocation & loc)

fully-qualified type names are allowed only in preprocessed files

const std::string & Package ()

Defined at line 94 of file ../../third_party/android/platform/system/tools/aidl/parser.h

void SetPackage (const std::string & package)
void MakeDocument (const AidlLocation & location, const Comments & comments, std::vector<std::string> imports, std::vector<std::unique_ptr<AidlDefinedType>> defined_types)