answersLogoWhite

0

Yes. In fact this is precisely why the copy constructor and assignment operator exist.

User Avatar

Wiki User

12y ago

What else can I help you with?

Related Questions

How do use the word assign in a sentence?

for example I will assign you to be the class presiden. assign means to hire


Is it possible to make the object of abstract class?

no u cant abstract class u can just inherit from


Can class be the child of another class?

Of course. ALL classes in Java are the child of another class. Even ones which don't appear to be, actually are a child of the master Object class.


Is it possible for your Alice program to have more than one instance in a class?

It is possible to have more than one instance of the same class, because the class is simply the blue print for the actual object.


Every class in derives from what class?

From the Object class.From the Object class.From the Object class.From the Object class.


Why do teachers assign seats for kids?

Because a student might be talking to another student and they might intrupt the class and then the other students with lot learn.


Java variable for favorite movie?

If you only want to store the title, make it of type String. If you want to store several pieces of information, create a class and call it (For example) Movie, assign it fields for the different things you want to store about the movie, then create an object based on that class.If you only want to store the title, make it of type String. If you want to store several pieces of information, create a class and call it (For example) Movie, assign it fields for the different things you want to store about the movie, then create an object based on that class.If you only want to store the title, make it of type String. If you want to store several pieces of information, create a class and call it (For example) Movie, assign it fields for the different things you want to store about the movie, then create an object based on that class.If you only want to store the title, make it of type String. If you want to store several pieces of information, create a class and call it (For example) Movie, assign it fields for the different things you want to store about the movie, then create an object based on that class.


What is class and objects?

class is template of object and object is instance of a class


What is object class in java?

object class is a super class for all other class...


What is the Object class parent?

Object is the topmost class in the Java Class hierarchy. There is no Class above Object. All classes in Java are implicitly derived from Object.


What class is the super class for ALL Java classes?

The Object class, in the java.lang package, sits at the top of the class hierarchy tree. Every class is a descendant, direct or indirect, of the Object class. Every class you use or write inherits the instance methods of Object. You need not use any of these methods, but, if you choose to do so, you may need to override them with code that is specific to your class


Which keyword is used to declare a class?

There is no keyword for it. You can use a variable of 1 class in another only id the other class is derived from the 1st class.Although you can use the variable of an object of a class in another class using object.variable