The Artima Developer Community
Sponsored Link

Java Answers Forum
a question about clone()

2 replies on 1 page. Most recent reply: Oct 11, 2005 5:48 AM by Jeff Thomson

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 2 replies on 1 page
xie yeji

Posts: 1
Nickname: xiexieni
Registered: Oct, 2005

a question about clone() Posted: Oct 5, 2005 1:57 AM
Reply to this message Reply
Advertisement
please tell me why the method clone() is declared protect?the method is defined in the class object,and it is the base class of all the class.I think it same to declare the method as protect and public.


Subodh Rawat

Posts: 9
Nickname: zeon
Registered: May, 2005

Re: a question about clone() Posted: Oct 10, 2005 2:36 PM
Reply to this message Reply
This comments might help you :

* Public variables, are variables that are visible to all classes.

* Private variables, are variables that are visible only to the class to which they belong.

* Protected variables, are variables that are visible only to the class to which they belong, and any subclasses.


-Zeon

Jeff Thomson

Posts: 14
Nickname: thomson
Registered: Sep, 2005

Re: a question about clone() Posted: Oct 11, 2005 5:48 AM
Reply to this message Reply
http://mindprod.com/jgloss/clone.html

----------------
Jeff Thomson
http://www.devsquare.com
DevSquare - Online Application Development

Flat View: This topic has 2 replies on 1 page
Topic: DisplayJAI detecting Exceptions Previous Topic   Next Topic Topic: Logging in JSP

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use