answersLogoWhite

0


Best Answer

Instantiate means to create an actual instance of a Class. That is, the creation of an Object of that Class. This allocates memory on the heap for that object. Instantiate creates a unique object of that class, complete with its own copy of any class variables. Thing of a Class as a design spec, which, when instantiated, creates an actual thing of that type. For instance, imagine a set of blueprints detailing how a Ford Focus auto is to be manufactured. This is a Class. When those blueprints are manufactured (instantiated, in Java-speak), the result is a physically unique car. A class can be instantiated hundreds or thousands of times, but each instantiation creates a new and unique object, in the same way the Ford Focus blueprints can result in many individual cars.

In essence, it happens whenever you call:

new <ClassName>();

User Avatar

Reese Lebsack

Lvl 10
1y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

11y ago

Instantiate means to create an actual instance of a Class. That is, the creation of an Object of that Class. This allocates memory on the heap for that object. Instantiate creates a unique object of that class, complete with its own copy of any class variables. Thing of a Class as a design spec, which, when instantiated, creates an actual thing of that type. For instance, imagine a set of blueprints detailing how a Ford Focus auto is to be manufactured. This is a Class. When those blueprints are manufactured (instantiated, in Java-speak), the result is a physically unique car. A class can be instantiated hundreds or thousands of times, but each instantiation creates a new and unique object, in the same way the Ford Focus blueprints can result in many individual cars.

In essence, it happens whenever you call:

new <ClassName>();

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is the meaning of instantiate in java?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Can you instantiate an interface?

According to a beginner's book on Java, an interface can't have constructors. Also, the interface itself can't contain the method implementation.


When you go for private constructor in java?

When you do not want any other class to be able to instantiate your current class


How do you instantiate self created class in java?

The exact same way you instantiate a class from any of the various Java libraries: by using the 'new' keyword. i.e MyClass A = new MyClass(); this forces the MyClass definition to run its Constructor method, and return an instance of object of type MyClass.


Why constructor in Java doesn't have any return type?

The constructor of a Java class is not an ordinary method. Its purpose is not to return any value. The purpose of the constructor is to instantiate the class which it does. Since, the purpose of a constructor is only to instantiate and initialize its class and not anything else, it does not have a return type. All it does is creates an object of that class.


This key word causes an object to be created in memory?

To instantiate a object, we use the new keyword in Java, which creates an object in memory.


What is a good explanation of instantiate?

The term 'instantiate' can be used in many different ways. The word 'instantiate' is a term meaning to provide an example. One way an individual might use the term is 'The mom instantiated how to tie her shoe.'


Can you use business logic in constructor with example in java?

No. Logic should never go in a constructor; constructors should only be used to instantiate and initialize object data.


What is the meaning of the word GUI in java?

Graphical User Interface http://en.wikipedia.org/wiki/Graphical_user_interface (there is no special meaning in Java, "GUI" is universally used)


Can you instantiate an abstract class?

No. You must create a subclass of the abstract class in order to be able to instantiate it.


What is literal in java programming?

Literal in java are L, F, null, true, false These act as keyword(have special meaning in java) but these does'nt comes under the category of Java Keyword.


Is it possible to define a java static method inside a main method?

Because, the main method is the starting point of the java program and if we need an object of that class even before the main can be invoked, it is not possible. Hence it is declared static so that the JVM Can acess the main method without having to instantiate that particular class


What is the meaning of a method in Java programming?

a method is a variable