aspose file tools
The moose likes Beginning Java and the fly likes Very simple question, cant remember answer... Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Beginning Java
Reply Bookmark "Very simple question, cant remember answer..." Watch "Very simple question, cant remember answer..." New topic
Author

Very simple question, cant remember answer...

SAFROLE YUTANI
Ranch Hand

Joined: Jul 06, 2001
Posts: 257
When you define a member of a class like this...
String s;
...what type of scope does the member assume? Private, public, or protected?
SAF
Gregg Bolinger
Ranch Hand

Joined: Jul 11, 2001
Posts: 15230

I believe it assumes public scope to the class and inner classes.
------------------
Happy Coding,
Gregg Bolinger
Jason Menard
Sheriff

Joined: Nov 09, 2000
Posts: 6450
Package scope, right?


Jason's Blog
Colin Kenworthy
Ranch Hand

Joined: Aug 06, 2001
Posts: 88
Yes, it has package scope: http://java.sun.com/docs/books/tutorial/java/javaOO/accesscontrol.html
Package is the default if you do not specify an access modifier.
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: Very simple question, cant remember answer...
 
Similar Threads
Let's find who's got the most post & who's the oldest(?) registered member of Ranch!
interface
Stack overflow error !
How to get HttpSessionListener to respond?
Where did you hear of the ranch ?