[java] Eclipse compilation error: The hierarchy of the type 'Class name' is inconsistent

Right click on the project folder and select "Java Build Path". Under "Java Build Path" you should be able to see libraries. Eclipse will show errors in any of those libraries. Fixing those issue will help to resolve the issue.