How is android manifest validated in android studio?

By : Kode

How does android studio validate AndroidManifest.xml and any activity xml? I have read this post and this and know that there isn't an actual schema for android manifest. But how does android studio or any tool that validates AndroidManifest.xml knows, what tags and elements are legal?

By : Kode


there isn't an actual schema for android manifest

I don't think this is correct. According to this answer:

The schemas don't exist as an xml file. Schemas are dependent upon what UI classes your program uses.

While there isn't a schema defined directly in an XML file, the valid tags and attributes can be defined elsewhere, such as in the Java code which parses and inflates an XML layout.

This video can help you solving your question :)
By: admin