Posts by Isaías de Lima Coelho • 350 points
23 posts
-
-3
votes1
answer366
viewsQ: firebase/app dependency not found
When using the command ng serve it returns the following message . ERROR in The target entry-point "@angular/fire" has Missing dependencies: - firebase/app already excludes the node_modules and the…
-
0
votes1
answer735
viewsA: How to map a table without ID, using Hibernate annnotaions?
To create a Many to Many mapping you can map your entities in this way, without any need to transform your associative table into a java object. @Entity @Table(name="notebook") public class Notebook…
-
0
votes1
answer102
viewsA: How to turn Double into Binario Java
I did the following test and it worked well String i = Long.toBinaryString(Double.doubleToRawLongBits(1.1D)); System.out.println(i); returned…
-
0
votes1
answer173
viewsA: How to subtract a date and time from another date and time in Ionic 4?
you can use the library Moment.js: var data1 = moment('29/04/2019 00:00', "DD/MM/YYYY hh:mm"); var data2 = moment('30/04/2019 02:00', "DD/MM/YYYY hh:mm"); var diferenca = data1.diff(data2, 'hours');…
ionicanswered Isaías de Lima Coelho 350 -
0
votes1
answer49
viewsA: Problems declaring a foreign key using Ibernate
I did this example showing how you should do to associate the entities in question. public class Teste { public static void main(String[] args) { Calendario calendario = new Calendario();…
-
1
votes1
answer30
viewsA: Knowing if a time period (hour) makes sense
What I would do is define that a shift should be at most X hours, and validate whether the amount of time subtraction is greater than the duty limit. //Retorna true se válido function…
javascriptanswered Isaías de Lima Coelho 350 -
1
votes2
answers224
viewsA: How to load 10 records from a Java list?
/ Java code to show the use of limit() function import java.util.stream.Stream; import java.util.ArrayList; import java.util.List; class gfg{ // Function to limit the stream upto given range, i.e, 3…
javaanswered Isaías de Lima Coelho 350 -
1
votes1
answer157
viewsA: Access all rows of a JAVAFX table
This table consists of a list of some item, So : List<Item> lista ; In the method that is called by your button you will do the following : itens.forEach(item ->…
-
1
votes1
answer138
viewsA: Formatting datatime in Ionic
You can use the library Moment js. moment('2019-04-26T11:43:17Z').format('DD/MM/YYYY HH:mm')
-
1
votes1
answer244
viewsA: How to block login access after 3 wrong firebase attempts
You cannot change firebase login attempts. Blocked user may try again after few minutes, but this is not managed by you. Firebase SDK will limit the user who tries : several incorrect password…
-
1
votes2
answers41
viewsA: How to position DIV in text
There is a CSS property, display: inline-block;
-
1
votes1
answer491
viewsA: Fetch information from package.json
I managed to recover the version number by doing the following, but I do not know if it is a good practice: import { Component, OnInit } from '@angular/core'; @Component({ selector: 'app-footer',…
-
0
votes1
answer491
viewsQ: Fetch information from package.json
I tried to do this using require, but it didn’t work and there was this error : ERROR in src/app/footer/footer.component.ts(8,21): error TS2580: Cannot find name 'require'. Do you need to install…
-
1
votes1
answer61
viewsA: Synchronization Java Web Method
Syncronized works in 3 different ways: public synchronized void foo() { } This version of foo() is an instance method, meaning different threads can invoke foo() simultaneously as long as the calls…
-
1
votes1
answer147
viewsA: How to declare a Multidimensional Array key - Javascript
If what you want is an Object that holds a Value and has a Key, I believe you can use one Map . var myMap = new Map(); myMap.set('azul', seuArray);…
-
0
votes1
answer77
viewsA: How to subselect/subquery using Criteria
I managed to solve by changing a little the strategy and using another Class, the solution was like this : DetachedCriteria subSelect = DetachedCriteria.forClass(Envolvido.class, "env");…
-
0
votes1
answer77
viewsQ: How to subselect/subquery using Criteria
Can someone help me find the problem of this consultation : CriteriaBuilder builder = em.getCriteriaBuilder(); CriteriaQuery<Solicitacao> query = builder.createQuery(Solicitacao.class);…
-
1
votes2
answers216
viewsA: Join and merge activity diagram
A Merge is represented graphically by a rhombus with two or more inputs and only one output, for example: When paying the parking the flow would be : Note that regardless of the payment choice the…
-
1
votes1
answer296
viewsQ: Turn Date into String and Format to DD/MM/YYYY using Typing
To send a request to the server, I need to format the parameter dataNascization so that it goes in DD/MM/YYYY format. Right now I’m sending him like this : Request URL:…
-
2
votes1
answer86
viewsQ: Generate String from list contents
I have a class called CoreFiltroSearch that has a list of ICoreFiltro calling for filtros. Follows the class and interface: public class CoreFiltroSearch { private List<ICoreFiltro> filtros =…
-
2
votes2
answers106
viewsQ: Standardization in building Rest api with Vraptor
Well I have a question about standardization in the creation of Rest endpoints. According to Vraptor documentation I can set the request path using the annotation > @Path("/paciente-api") here at…
-
0
votes0
answers61
viewsQ: Memory Leak error in connection drivers when trying to launch Tomcat
I have a Java/Vraptor4 application on a Tomcat9.0 , when I am climbing up Tomcat the following error is released: abr 09, 2019 10:50:13 AM org.apache.catalina.startup.VersionLoggerListener log…
-
0
votes1
answer25
viewsQ: Endpoints using Vraptor
I have a problem here but I do not know if it gives p/ solve . I have a method that has many parameters so I made a kind of filter, and it was like this : @Get("") public void findByFilter(Filtro…