Most voted "instantiate-object" questions
65 questions
Sort by count of
-
0
votes0
answers166
viewsCreate an object instance by Activator.Createinstancefrom C#
I need to instantiate the Paismapper class with the following scenario. DLL running: Projeto.ERP.Desktop In Formuláriopal I execute the method…
-
0
votes1
answer38
viewsreceive an object in a method of the same type as the method class
I’m passing a java code to python and came across it(cutting a few parts) public class TreeNode { public TreeNode(TreeNode pai) { how do I receive the father of the type Treenode in python? class…
-
0
votes2
answers207
viewsError when instantiating two or more PDO in different classes
I will start with the error displayed: Fatal error: Uncaught Pdoexception: You cannot serialize or unserialize PDO instances in [no active file] on line 0 In the project I have the class Carts and…
-
0
votes2
answers94
viewsAccessible class across C#
I would like a class that is not static to be available for the entire application. At first I thought about turning this class into static, but for obscure reasons that are beside the point, I…
-
0
votes1
answer303
viewsInstantiate a class that inherits an interface class
I have a class that inherits many interface classes, and I want to instantiate it to use only one method, how do I do? It is possible to do without passing all the necessary parameters? public class…
-
0
votes0
answers27
viewsDWR - Null classes
Expensive I’m having trouble injecting the classes by calling some methods using DWR with Hibernate. Code: @Controller @Transactional public class ManterArvoreClassificacaoController { @Autowired…
java ajax framework dependency-injection instantiate-objectasked 6 years, 5 months ago Kennedy Anderson 90 -
0
votes1
answer34
viewsI can’t run a class
So guys, I’m trying to run an app to upload an image to my server. Without saving this data to the database, the upload usually occurs, but when trying to include the image link in the database, php…
-
0
votes1
answer483
viewsInheritance, polymorphism and access to methods
I have 3 classes and 1 enum: public class Pessoa { private TipoPessoa tipo; public TipoPessoa getTipo() { return tipo; } public void setTipo(TipoPessoa tipo) { this.tipo = tipo; } } public class…
-
0
votes2
answers2509
viewsUnable to access a discarded object
I am instantiating a form from a double click on a Datagridview from another form, where through this return the information from that line to the form. It is working properly but when I close this…
-
0
votes1
answer87
viewsError: Undefined object reference for an object instance of an Object.System.Formatexception
I’m having a problem when it comes to excluding a client. In the bank is deleted, but instead the message appears: "SUCCESSFULLY EXCLUDED!", message appears: "Could not delete". Details: Undefined…
-
0
votes1
answer22
viewsHow to create a new instance instead of pointing to the same instance when defining variable?
When defining a variable of type Carbon i cannot copy the object (create new instance with the same properties), just point to the same instance, forcing me to create new objects manually. Example:…
-
-1
votes1
answer1402
viewsManipulating class within another class and saving in array
I created a class Pessoa and in it an attribute endereco, only I made a class Endereco to register more than one endereco per person. In that other class Endereco has id and nome da rua, and I can’t…
-
-1
votes1
answer45
viewsjava.lang.Nullpointerexception error even with instantiated and initialized object
Good afternoon, In the code below I have already entered the Supplier class within the main Product and even so continues the error below, Can someone help me fix and explain why it’s wrong so…
java classes nullpointerexception instantiate-object initializationasked 4 years, 8 months ago Deivson Bezerra 149 -
-2
votes1
answer425
viewsHow does the new Java operator work?
I don’t understand how new works below: public Main(){ System.out.println(""); } public static void main(String[] args){ new Main(); }
-
-2
votes1
answer69
viewsInstantiate class within constructor
If I instantiate several classes in a constructor, for example: public function __construct() { parent::__construct(); $this->loginModel = new \Application\Models\Login; $this->followModel =…