Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to tell the java compiler to allow public as package name?

Tags:

java

javac

gwt

In GWT code I use a java sub package called public that contains html/css/etc.. files.

I notice that the java compiler output doesn't contain this sub package and its content.

I want this because of testing purposes. Any idea how to tell the java compiler to include this sub package and its content?

like image 952
edbras Avatar asked Oct 21 '25 05:10

edbras


2 Answers

You can't... It's a reserved word....

Sorry.

http://www.jwrider.com/riderist/java/javaidrs.htm

EDIT

and

http://download.oracle.com/javase/tutorial/java/nutsandbolts/_keywords.html

Thanks @Joachim

like image 158
Jeffrey Kevin Pry Avatar answered Oct 23 '25 20:10

Jeffrey Kevin Pry


Yep, "public" is a reserved word and you can't use it. You can probably use "Public", though. (Not that I recommend it.)

like image 26
Hot Licks Avatar answered Oct 23 '25 18:10

Hot Licks



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!