Node cannot be resolved to a type

I’ve seen similar behaviour in the past and know of two possible reasons: Your build path has somehow changed, leaving out your Node class, or the project providing it has compile errors, or similar. Given your description of the problem, this probably isn’t relevant in your case. Some Eclipse screwup. For me, this was always … Read more

How to use regex in String.contains() method in Java

String.contains String.contains works with String, period. It doesn’t work with regex. It will check whether the exact String specified appear in the current String or not. Note that String.contains does not check for word boundary; it simply checks for substring. Regex solution Regex is more powerful than String.contains, since you can enforce word boundary on … Read more

What does super.paintComponent(g) do?

What does it do? It prints the component as if you hadn’t overridden the paintComponent method. If you have a background color set for instance, this is typically painted by the class you’re extending. When do we need to use it? You use it if you don’t paint on the entire component. The parts that … Read more

How to set JAVA_HOME in Linux for all users

find /usr/lib/jvm/java-1.x.x-openjdk vim /etc/profilePrepend sudo if logged in as not-privileged user, ie. sudo vim Press ‘i’ to get in insert mode add:export JAVA_HOME=”path that you found” export PATH=$JAVA_HOME/bin:$PATH logout and login again, reboot, or use source /etc/profile to apply changes immediately in your current shell

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)