summaryrefslogtreecommitdiff
path: root/tools/aapt2/java/JavaClassGenerator_test.cpp
diff options
context:
space:
mode:
authorDiego Perez <diegoperez@google.com>2017-03-29 17:20:01 +0100
committerDiego Perez <diegoperez@google.com>2017-03-30 12:07:28 +0100
commitd88c717b4e124e435e54bf1542774aa100773c3e (patch)
tree0f1767e4da20fc28f29c4c32784cc43d217dd855 /tools/aapt2/java/JavaClassGenerator_test.cpp
parent1af2928767af7ffd95ce61946b95a7b5ef877bd5 (diff)
Make layoutlib more lenient with recoverable errors
In many cases, throwing an exception will stop the inflation or rendering of a layout. Sometimes, we could recover from some of the failures and render a layout that is "usable". I've done a first pass trying to follow the following rules: - Try simple recoveries by choosing sensible defaults. Not trying complex recoveries. - Only recover if the exception is not part of the class behaviour. Avoided removing declared exceptions or exceptions that are expected by the framework. - I've kept assertions in place so, in most cases, the behaviour will be almost identical to the previous one with assertions enabled. Test: Checked with existing tests Change-Id: I0001fdd3c808cf405c4eb8d734b9bbe63493e05c
Diffstat (limited to 'tools/aapt2/java/JavaClassGenerator_test.cpp')
0 files changed, 0 insertions, 0 deletions