what is object slice?

Answer Posted / vivek

When a derived class object is assigned to a base class,
only the base class's part of content in the derived object
are copied to the base class, leaving behind the derived
class specific contents. This is referred as Object Slicing.

Is This Answer Correct ?    12 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How do you define a parameter?

769


What is a jagged array in java?

761


What is prefix of a string?

779


Why for each loop is used?

724


What is reflexive association?

1327


How can we make copy of a java object?

758


What is polymorphism and what are the types of it?

688


What do you mean by synchronized non access modifier?

743


What is classname class in java?

741


What is the difference between length and length () in java?

710


What does system out println () do?

765


What are filterstreams?

818


Why scanner is used in java?

755


What does I ++ mean?

803


What does the @override annotation do?

735