Just another weblog

  • Subscribe

  • Recent Posts

  • Pages

  • Archives

  • Top Clicks

    • None
  • Advertisements

JAVA Class Access Specifiers

Posted by damuchinni on March 7, 2009

JAVA Class Access Specifiers

Access means visibility. In Java we can use two access specifiers (public,default) for class.

Default Access

If you are not specified any access specifier that will be considered as default access. Default access is a package level access. A class with default access can be seen by other classes in the same package.

Public Access

If a class specified as public, then all classes in the java universe can access that class. The classes in the same package can use the public class with out import, but the classes declare in other packages must need to import prior to accessing.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: