wood burning stoves*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes enum public/protected/default/private Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "enum public/protected/default/private" Watch "enum public/protected/default/private" New topic
Author

enum public/protected/default/private

Saibabaa Pragada
Ranch Hand

Joined: Oct 24, 2010
Posts: 162
Hi, I just wanted to know & looking for the reasons why we cannot define enum with public, protected and private access specifiers. enum works only for default(no access specifier).
Prasad Kharkar
Ranch Hand

Joined: Mar 07, 2010
Posts: 438



compile and execute the program


a tip for you : try to learn through coding and do much things on your own


happy to help


SCJP 6 [86%] June 30th, 2010
OCPWCD [84%] March 26th, 2013
If you find any post useful, click the "plus one" sign on the right
Abimaran Kugathasan
Ranch Hand

Joined: Nov 04, 2009
Posts: 2066

Saibabaa Pragada wrote:Hi, I just wanted to know & looking for the reasons why we cannot define enum with public, protected and private access specifiers. enum works only for default(no access specifier).


What do you mean? Enum constants or Enum class?


|BSc in Electronic Eng| |SCJP 6.0 91%| |SCWCD 5 92%|
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: enum public/protected/default/private
 
Similar Threads
K&B SCJP 5: topic page 62 second example
Enum doubt
private and protected enums
enum constructors
Are Instance variables private by default?