Posts by adelmo00 • 1,904 points
56 posts
-
1
votes2
answers156
viewsA: Select in the database using "like"
On line 12 you pass String which will be the search term concatenated with the wildcard % of like public void returInfoClient(userClient) { Connection mConn = (new…
-
1
votes1
answer512
viewsA: Angularjs project base with Codeigniter
There is no rule that defines which folder the files should be in. What you can do and use a set of good practices, you can create or use an existing one yourself. There are a few questions in the…
-
2
votes2
answers1825
views -
1
votes1
answer943
viewsQ: Wildfly - External access configuration
I’m setting up to unlock Wildfly’s doors and I found these two ways. I couldn’t find the difference between the two, if there is one. What is the difference between the two settings:…
-
1
votes3
answers2409
viewsA: What is the best way to send my Spring Boot project to the server?
According to the documentation, you must add the following plugin to your project to generate a executable jar. If you use Maven <build> <plugins> <plugin>…
-
1
votes1
answer55
viewsA: Failure to build Spring MVC application when configuring AOP bean
The problem lies in that line: java.lang.NoClassDefFoundError: org/aspectj/weaver/reflect/ReflectionWorld$ReflectionWorldException You are missing a role in your aspectj project. To make the fix you…
-
6
votes0
answers75
viewsQ: Thread in WAIT state
I am monitoring a system that was made in Java and at certain times during the day the vast majority of Threads, about 95%, enter the WAIT state and are waiting for about 50 seconds on average, and…
-
3
votes1
answer171
viewsA: Is it possible to send all Java Exceptions by email?
Using Spring MVC Spring MVC provides a way to handle exceptions, the annotation @Exceptionhandler . For each controller we can define a method that is called when a certain exception is thrown.…
-
2
votes1
answer823
viewsA: Wildfly 10 + Spring Security + JSF + CDI Does Not Inject Dependency
You are using Spring Security and CDI, both have a different dependency injection context so CDI-managed DAO will not be available for Spring Security context. In a project to get around this…
-
1
votes2
answers452
viewsA: How to run a Timer class (always) on deployment?
Use Eventlistener may solve your problem, but it is not ideal as it was done to perform certain action after an event in the system. When it comes to Spring you can use the annotation @Scheduled. To…
-
2
votes1
answer429
viewsA: Inject CDI is not working with producer on a project . jar
The CDI needs a container to work properly. As you are running tests with junit, there is no container for the CDI. To solve this, you can use the jGlue or the Arquillian. If using jGlue just add…
-
2
votes2
answers3824
views -
1
votes1
answer124
viewsQ: php - No update in Boolean field
I am trying to update the user data, but the active field is not updated. I have tried several changes and also change the variable value $active of boolean for int, but without success. Another…
-
2
votes1
answer580
viewsA: How to send an object between controllers via Redirect
You can use the Redirectattributes to pass the objects through redirect. @RequestMapping(value="/suaUrl", method=GET) public String seuMetodo(RedirectAttributes redirectAttributes) { ...…
-
0
votes4
answers578
viewsA: Problems with Input Angularjs
There is a problem with Angular bind when the type of input is number. From what I researched there is no exact answer to why of the problem. You can get around this by changing the type of input…
-
2
votes2
answers6814
viewsA: Get current date/time Angularjs
The Angular has several Filters to format the data. Filters can be added to expressions using the pipe character |, followed by a filter. In your case, you need to use the filter date On your page…
-
1
votes2
answers517
viewsA: pickadate Angular - Translation
By default, Angular supports en_US locale. For other formatting you need to add . js specific to the country, so just download the file containing the translations of Datepicker. Here’s an example I…
-
0
votes1
answer147
viewsA: Angularjs reset to default option with ngOption
You declared the variable $scope.agents as an Array? I copied your code to Plunker and the only change I made was declaring the variable as an Array. Controller: angular.module('app',…
-
1
votes1
answer151
viewsA: link CSS in a Spring MVC project
In its Spring MVC configuration class extending the class Webmvcconfigureradapter, the method addResourceHandlers should be overwritten and left this way: @Override public void…
-
2
votes3
answers1999
viewsA: How to work with Table of Contents on Hymeleaf?
When using the th:each Thymeleaf offers a mechanism for you to control the iteration, the status variable. It is declared after the iteration variable. To status variable contains some information…
-
1
votes1
answer99
viewsA: How can I turn a bootstrap(html,css,javasript ) template into a . Zul (Views of the Zk framework)
According to the documentation you can download the jar file from Github or put the dependency on pom.xml. If you download from Github, you should put the file zk-bootstrap.jar inside the briefcase…
-
3
votes1
answer4566
viewsA: How do I resolve the "No Persistence Provider for Entitymanager named" error?
According to class documentation Persistence the method createEntityManagerFactory receives a String that must be the name of your Unit persistence. By the configuration made in your persistence.xml…
-
1
votes1
answer69
views -
0
votes1
answer460
viewsQ: Message appears in modal and page at the same time
I created a "message center" in Angularjs that injects messages on the screen. The message always appears when an error occurs in REST operations or success. This is done by an Interceptor that…
-
2
votes1
answer172
viewsA: Prime faces does not run the theme "SAM"
The error is in your Web.xml. In this part: <!-- Configurações do tema do PrimeFaces --> <context-param> <param-name>META-INF.maven.org.primefaces.themes.sam</param-name>…
-
10
votes2
answers6083
viewsA: Search Products via API or Web Crawler
The large Ecommerce used here in Brazil (American, Walmart, submarine, extra) provide some API to search for product information? The only API I found to search for products in Brazil was Buscapé,…
-
5
votes2
answers1706
viewsQ: Capture user name logged into machine via Web Application
There are two applications, one in Java and one in ASP and both manage to integrate with Active Directory without me typing user and network password. The application made using ASP, automatically…
-
2
votes4
answers3972
viewsA: java.lang.Noclassdeffounderror: org/slf4j/Loggerfactory
The error happened because the class is missing Loggerfactory in Classpath. To fix just add the sl4j library in Classpath, which you can find here. You can put the files: slf4j-api-1.7.13.jar and…
-
3
votes2
answers450
viewsA: Static blocks, heritage and constructors in Java
According to documentation from Oracle. In chapter 12 it says: Before a Class is initialized, its direct Superclass must be initialized, but the Interfaces implemented by the Class are not…
-
1
votes2
answers345
viewsA: How to translate the Mysql query that has a sum to Hibernate?
Hibernate can run Native SQL. Follow an example: String sql = "select sum(TOTAL_MERCADORIA_BRL) from PROCESSO group by PERIODO like 'DEZ-15'"; SQLQuery query =…
-
6
votes1
answer2480
viewsA: Differences between Java application servers
Jboss(now Wildfly) and Glassfish are Oracle-approved application servers to support JEE(Java Enterprise Edition). Tomcat is a Servlet container and partially supports the JEE specifications in the…
-
9
votes3
answers10207
views -
7
votes2
answers4066
viewsA: What are MIME types?
MIME stands for Multi-purpose Internet Mail Extensions. MIME types form a standard file type classification on the Internet. Internet programs such as web servers and browsers all have a list of…
-
3
votes2
answers1501
viewsA: Put files inside a. zip file
I found a tutorial in English and did his translation and test. To insert files into a ZIP file you must use the NIO library, present in Java 7 or higher. Map<String, String> zip_properties =…
-
1
votes2
answers445
viewsQ: Dependency Injection - Two objects implementing the same interface
I have two objects from the Amazons3uploadservice classes and Databaseuploadservice and both implement the Uploadservice interface. The uploading class has the two objects injected by the Spring…
-
1
votes1
answer66
viewsA: Modifying Material Angularjs Start by creating new module/controller
The line that loads Chart.js and chartController.js is commented <!-- <script src="./src/charts/Charts.js"></script> <script…
-
4
votes1
answer1576
viewsA: How to access the Serial port of a computer in Java?
There is the jSSC library that provides communication with the serial port https://code.google.com/p/java-simple-serial-connector/ Add the dependency to your pom.xml, if you don’t use Maven download…
-
0
votes1
answer121
viewsA: Error deploying a Maven project
Already built the project again? If you’re using Eclipse Go to Run -> Run Configurations -> Two clicks in Maven Build. Select your project and in "Goals" put clean Compile install. You can…
-
1
votes1
answer359
viewsA: What programming should be done to use Spring Security with Jboss with annotations?
The project uses Spring Security, JPA and JAX-RS. I haven’t put in any MVC framework yet. I have tested the authentication and it is working properly on Wildfly 8.2. Pom.xml was generated using the…
-
5
votes1
answer73
viewsA: Is it possible to know which JEE Container is being used during Dispatcher Servlet startup?
You can create a class to boot the Webapp that implements the interface WebApplicationInitializer. This interface has a single method that receives a ServletContext and by ServletContext you can get…
-
0
votes2
answers1221
viewsA: Spring Security with Java EE
Note the following line: nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [javax.sql.DataSource] found for dependency The error…
-
0
votes1
answer2187
viewsQ: Angularjs - Unknown Provider
I am trying to create a Service in Angularjs but the error is occurring: Error: [$injector:unpr] Unknown Provider: $scopeProvider <- $Scope <- Orderservice I tried everything to fix, I stopped…
-
0
votes1
answer113
viewsQ: Simplejaxwsserviceexporter - Baseddress
I created a web service with JAX-WS and used Spring to put it online and also to decrease the use of XML. Problem is that when I declare the Simplejaxwsserviceexporter in the Spring configuration…
-
2
votes1
answer3184
viewsQ: getOutputStream() has already been called for this Response
I created two identical error pages for two systems running within the same Tomcat. One of the pages works normally and the other occurs the following error. Within the development and homologation…
-
3
votes3
answers2826
viewsA: Add image to . jar
I always put all the images I’ll use inside a new package, so when I generate one. I don’t have to worry about them because they’ll be inside. I created a new package called Assets, and inside it I…
-
5
votes1
answer892
viewsQ: How to create Cover in a Report using iReport
I am using iReport 5.5.2 and have tried in many ways to add a cover to the report, which is necessary but unsuccessful. I tried adding the isTitleNewPage attribute to the iReport Title band, but it…
-
1
votes1
answer42
viewsA: Find a variable in JSP
There is the "Search in Projects" option that you find from the "Edit" menu. It has several parameters that you enter to perform the search, such as: Word to be researched in projects File…
-
5
votes2
answers8876
viewsQ: Accents and Special Characters in Ajax jQuery
I have a query that is made with Ajax request via jQuery. In the fields when I type a character like "ç" and send the request to the server, it is arriving with the character in another format. Ex:…
-
0
votes1
answer938
viewsQ: Bank Access Attempt Log (Oracle 11G)
We have an Oracle 11G here in the company. Last week some joker tried to access for more than 10 times with incorrect user or passwords. I searched and I’m searching for some way to save access logs…
-
0
votes1
answer253
viewsQ: Disable link in jQuery paging menu
I have a paging plugin made in jQuery. What I can’t do is when I’m on the last page, the link that gives access to the next page is disabled and the user can’t click anymore. Similarly the button…