Questions tagged as 'constructor'

1
answer

Call to functions nested in STRUCT within a CLASS

I have this implementation of a class that handles linked lists. The issue is that I'm using primitive functions in the struct I use within the class, however I do not know much about it, and I do not know how to invoke the functions. Here...
asked by 11.05.2017 / 01:30
1
answer

Implement constructor manually

I have to modify the following program in order to compile it with GCC 4.9.2. The problem is because GCC can not implement some noexcept move constructors like "= default". I have to implement the constructor manually (on foot) and I do not k...
asked by 01.11.2017 / 06:46
0
answers

Send the subclass as an argument in the super constructor

If a class in your constructor calls super(/*argumentos*/); , how do I send it to itself? (Likewise as a parameter, what else could be sent? And I know that the subclass, the superclass can not call super(); (at least not in my exam...
asked by 30.06.2017 / 21:44
2
answers

Is it mandatory to call the constructor of the base class from the constructor of a class inherited from it?

My problem is the following, when inheriting from a class (Base, whether abstract or not) which has one or more constructors defined explicitly I am forced to call some of them in any constructor that defines the derived class because if I do no...
asked by 24.02.2018 / 02:16
3
answers

Error in JAVA creation of arrayList incompatible types: String can not be converted to branch ----

What does the error mean and how can I solve it? It is a database of a bank in which I have to use a type "branch" but I can not use it add that type To My arrayList ArrayList Array_Asesores = new ArrayList(); Here is the code porfavorrr .....
asked by 07.12.2017 / 16:07
2
answers

Call a callback to a fragment from an adapter

I hope you can help me, I have been looking for a solution for weeks and I only need this to finish a project. I want to call a method (UpdateItemcount) but I can not do it from my adapter. I have tried in several ways but it involves changing t...
asked by 30.10.2018 / 05:58
1
answer

Inheritance Uncaught ArgumentCountError: Too few arguments to function

I have problems with the child class constructors. In this case I have an abstract ACCOUNTS class. From it inherits CURRENT ACCOUNT and in turn it inherits ACCOUNTNOWABILITY . When wanting instances CURRENT ACCOUNT AND ACCOUNT CONVERTIBILIT...
asked by 06.09.2018 / 16:39
1
answer

Constructor with POO constants. Java

I have a question about a little code I've seen. In an exercise, creating an Appliances class, you are asked to create a series of attributes (price, color, consumption, weight) and that by default, the color will be white, the energy consumptio...
asked by 13.01.2018 / 20:05
1
answer

Error using file_get_contents in PHP7

When I upgrade from php 5.6 to php 7 I get this error:    Warning: file_get_contents (): http: // wrapper is disabled in the server configuration by allow_url_fopen = 0 php / admirss.php on line 26       Warning: file_get_contents ( link ):...
asked by 26.11.2017 / 11:56
1
answer

Why do not you show me the stats of the constructor?

package Stats; public class Players { private String name; private int RIT; private int TIR; private int PAS; private int REG; private int DEF; private int FIS; private int MED; public Players (String name, i...
asked by 10.11.2018 / 22:52