Questions tagged as 'java'

0
answers

Hibernate does not create table in database

The event model is an entity that must be created in the database, but hibernate is not creating. persistence.xml <persistence xmlns="http://java.sun.com/xml/ns/persistence" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schem...
asked by 08.03.2018 / 22:32
1
answer

Use the same jFormattedTextField for CPF and CNPJ mask

I would like to know if it is possible in a same JFormattedTextField , toggle mask for CPF and CNPJ. When I use the mask of JFormattedTextField the value is already static, and if you put it to the CPF, it will not fit the CNPJ a...
asked by 15.07.2016 / 15:26
0
answers

Spring @Scope ("session") not working with webAppContextSetup

In my spring test when i use standaloneSetup (controller) the @Scope ("session") works fine. But when I change to webAppContextSetup (this.wac) the scope stop working. My question is, why? Controller: @Controller @RequestMapping("/pe...
asked by 22.03.2018 / 16:54
0
answers

Criteria throwing Java heap space due to the size of the Restrictions.in () clause

I am trying to run a query using Criteria but it is returning an Exception from "Java heap". It should probably be the amount of data I'm passing in the "in" clauses Here is a code that represents my query: Criteria c = session.createCriter...
asked by 22.03.2018 / 16:38
0
answers

How to implement DataSource in Tomcat

I am finalizing a project that uses a REST server in Java, and is implemented in Tomcat, and I encounter a problem, the time it takes the service to implement a new connection (3000ms to 5000ms) of the bank, leading to a slow application. I s...
asked by 06.03.2018 / 13:06
0
answers

How to get the value of the cid: from an image in the body of the email

Good morning, I need to get the value of cid: from the images contained in the body of the email at the time of reading to be able to replace the value of cid: by the base64 of the image, but I can not get that value, does anyone have any tip...
asked by 07.03.2018 / 14:43
0
answers

Execute Javascript with a button click using HtmlUnit

Hello, I'm trying to create a bot with HtmlUnit to get some products from a site automatically, I'm getting the products listed, but the site has several branches and for me to change to the branch I want, I need to change the value of one se...
asked by 07.03.2018 / 13:31
0
answers

Sending data byte [] socket

I have a problem a few days that I can not solve. I have a socket connection and I'm testing signature in the messages, I have a Mensagem object that contains String mensagem , String assinatura and PublicKey chavePubli...
asked by 07.03.2018 / 13:47
1
answer

Criteria to filter a string array list

I'm developing a Java Web application and came across a question. I have a relationship n: n between AgendaTriados and Indicacao thus forming the triados_indicacao. And when saved to the database, it saves a string array of the names of the indi...
asked by 05.03.2018 / 21:51
0
answers

Add Header Soap using ws-security

blz. See if you can help. I need to make a consumption of ws soap using ws-security, but the implementation is quite different from what I researched so see below: <soapenv:Header> <wsse:Security xmlns:wsse="http://docs.oasis-open.o...
asked by 05.03.2018 / 18:02