Questions tagged as 'objetos'

1
answer

Transform object into array while maintaining index

Good evening Friends who can help me? I have this Array of objects, I needed to make this Object in list more while keeping the index as it is UsingMapitchangestheindex: I then needed to access each item to perform calculations, but the...
asked by 04.07.2018 / 20:40
2
answers

Instantiated object does not appear in function [duplicate]

Hello, I'm creating a Java project using Eclipse with the windowbuilder. Inside this project I own the JFrame with the objects, jbuttons, jtextfields, jformattedtextfields, etc ... I have all these objects in my project. It occurs that when I...
asked by 01.06.2018 / 17:37
1
answer

When I'm installing a class I need to perform a 'delete' after using the object even though the class has a destructor?

If I instantiate a class and render an object from it, I have to deallocate the memory of that object at the end of its use, right? But if the class that gave rise to my object has a destructor, will it be necessary to perform a delete on the ob...
asked by 10.09.2017 / 19:35
2
answers

Count and compare number of keys and values between objects

I am using JavaScript objects to transcribe the interface of an app, however, I would like to create a tool for collaborative transcription but I do not know how to proceed. In a simplistic way, the object has indexes, items or sub-indexes wi...
asked by 22.03.2017 / 17:16
2
answers

Returning an object. Any code smell here?

I thought of the following public method: public RespostaDeArme armar(); The class RespostaDeArme would look like this: public class RespostaDeArme { private final ResultadoDeArme resultado; private final Set<Integer>...
asked by 16.02.2017 / 19:07
1
answer

Array receiving two objects

I have two objects and I wanted to create an array this way = > [{"loj_codigo":2,"loj_fantasia":"teste 1"},{"loj_codigo":1,"loj_fantasia":"teste 2";}]} I'm getting the following objects = > Object {1: "1", 2: "2"} Object {1: "teste...
asked by 13.07.2016 / 04:00
1
answer

Static method with object as parameter

I am creating a very simple system for registering students. I made a Aluno class as follows: public class Aluno { private String nome; private String matricula; private String curso; private int periodo; private Str...
asked by 24.05.2016 / 17:02
1
answer

Uses existing walls in a second level parentNode

I have the following object as an example: var teste = { config : { dir: "myDir", type:"myType" }, fn : { foo : function(){ console.log(this); //retorna o objeto fn }, bar :...
asked by 23.06.2015 / 18:23
1
answer

How to detect collisions using Slick2D?

I would like to know how I can detect collisions between objects using slick, do you have any useful examples? I'm playing a simple game where 2 squares are moving on the screen and if the character I'm moving through the keyboard is hit by s...
asked by 29.01.2014 / 21:43
0
answers

Mount tree of objects

I need to mount a tree of php objects, where I have for example: id | parent_id | nome | telefone | email from the last id I search and mount the whole tree of that idPai (int) 0 => object(App\Model\Entity\User) { 'id' =&g...
asked by 03.08.2018 / 14:02