Add an AST checker

- Currently ast checker, check only parents
- Now, parent checking is more precise since it use the checkValidity
method that checks also type of parent node.

Bug: 14101350

Change-Id: I5ba04a40cb5d14e7272df3e1768126b5b3f58a98