Top "Instance" questions

In object-oriented programming an instance is an occurrence or a copy of an object, whether currently executing or not.

How can I call a static method on a variable class?

I'm trying to make some kind of function that loads and instantiates a class from a given variable. Something like …

php oop class function instance
How to use Ruby's self keyword

From what I understand about self, it refers to the current instance of the class. Isn't this the default behaviour …

ruby instance self
Dynamically invoking any function by passing function name as string

How do I automate the process of getting an instance created and its function executed dynamically? Thanks Edit: Need an …

c# reflection function instance
Non-Singleton Services in AngularJS

AngularJS clearly states in its documentation that Services are Singletons: AngularJS services are singletons Counterintuitively, module.factory also returns a …

service angularjs singleton instance factory
How many instances created for singleton bean referring to a session bean/prototype bean

I have a doubt about the number of instances that will be created in the scenario mentioned below, when Spring …

spring instance
Java: newInstance of class that has no default constructor

I'm trying to build an automatic testing framework (based on jUnit, but that's no important) for my students' homework. They …

java reflection constructor new-operator instance
no suitable constructor exists to convert from "test *" to "test", constructor,

I'm new to c++ and I'm having difficulties with constructor and classes. So, here is my header file: #pragma once #…

c++ object pointers constructor instance
Changing fill color of MovieClip Actionscript 3

i want to ask, how to change only fill color of an instance on the stage - i can do …

actionscript-3 colors instance fill
Getting an instance name inside class __init__()

While building a new class object in python, I want to be able to create a default value based on …

python class variables object instance
Creating a Generic<T> type instance with a variable containing the Type

Is it possible to achieve the following code? I know it doesn't work, but I'm wondering if there is a …

c# generics types instance