0

I've installed latest version of Java Eclipse and JDK under Debian 9.0. When I create a JFrame, some errors occur, for example:

Access restriction: The constructor EmptyBorder(int, int, int, int) is not accessible due to restriction on required library /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/rt.jar

Any ideas on how to fix the problem?

NSchorr
  • 875
  • 10
  • 13
Hydronit
  • 29
  • 1
  • 5
  • disable errors for forbidden references in compiler settings : http://www.digizol.com/2008/09/eclipse-access-restriction-on-library.html and please post some code – spi Dec 14 '17 at 14:15
  • I think it should be Eclipse not Ecplipse :D – ice1000 Dec 14 '17 at 14:34
  • whatd arble youd talkdingd abdoutd? ^^ – spi Dec 14 '17 at 16:16
  • there are not code available, I just create a JFrame, and i could see only errors, not code! – Hydronit Dec 27 '17 at 10:15
  • java.lang.NullPointerException at org.eclipse.wb.internal.core.editor.multi.SourcePage.updateSourceActions(SourcePage.java:140) – Hydronit Dec 27 '17 at 11:22

1 Answers1

0

Check the build path in Eclipse for that project.

This is similar to this question which has fix instructions: JDK Access Restriction Fix

NSchorr
  • 875
  • 10
  • 13