Note that there are some explanatory texts on larger screens.

plurals
  1. POHow to solve "The hierarchy of the type is inconsistent" error in Java Eclipse?
    primarykey
    data
    text
    <p>I was trying to create an Android Application in Java Eclipse with the use of the <a href="http://wiki.processing.org/w/Android" rel="nofollow">Processing for Android</a> but when I was about to compile it, I got this error message "<strong>The hierarchy of the type MainAcitvity is inconsistent</strong>". Here is my code:</p> <pre><code>public class MainActivity extends PApplet { public static void main(String args[]) { PApplet.main(new String[] { "--present", "com.RDP.MainActivity" }); } Vector path = new Vector(); public void setup(){ size(550,550, P3D); smooth(); } public void draw(){ background(255); LineSimplifier1 pt; noFill(); strokeWeight(1); beginShape(); for (int i=0; i &lt; path.size(); i++) { pt = (LineSimplifier1)path.elementAt(i);vertex(pt.x,pt.y); } endShape(); strokeWeight(5); beginShape(POINTS); for (int i=0; i &lt; path.size(); i++) { pt = (LineSimplifier1)path.elementAt(i);vertex(pt.x,pt.y); } endShape(); } public void mousePressed(){ path = new Vector(); } public void mouseDragged(){ path.add(new LineSimplifier1(mouseX, mouseY)); } public void mousePressed1(){ if (path.size() &gt; 1) { LineSimplifier1 [] tmp = new LineSimplifier1[path.size()-1]; for (int i =0; i &lt; path.size()-1; i++) { tmp[i] = (LineSimplifier1)path.elementAt(i+1); } path = new Vector(); path.addAll(Arrays.asList(AndroidRDPActivity.simplifyLine2D(5,tmp))); } } } </code></pre> <p>Another error is, <strong>"The type java.awt.event.MouseListener cannot be resolved. It is indirectly referenced from required .class files"</strong>. Please help me solve this problem. Thanks.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload