зеркало из https://github.com/mozilla/gecko-dev.git
7595348845
Currently, when we generate JNI wrapper for an inner class, the resulting C++ class will not actually be a nested class of the enclosing class. As a result, the class can be confusing to use. For example, wrapping Java class GeckoThread.State results in two unrelated C++ classes, GeckoThread and State, and it'd be confusing to use State by itself. This patch adds support for inner classes. We start by scanning only for top-level classes, and when processing each top-level class, we recursively scan for inner classes through JarClassIterator.getInnerClasses() and CodeGenerator.generateClasses(). For each Java inner classes, the resulting C++ class will be a nested class. For example, wrapping GeckoThread.State will produce widget::GeckoThread and widget::GeckoThread::State. |
||
---|---|---|
.. | ||
AlphabeticAnnotatableEntityComparator.java | ||
GeneratableElementIterator.java | ||
Utils.java |