Questions tagged as 'java'

1
answer

Uploading photo in java form

I need to have my form send and save a photo in the database and then show me how to do it? I declare what kind of variable in the Client entity? String or byte? I know the primefaces has a component but I do not know how to do it. Can any...
asked by 27.09.2016 / 21:12
1
answer

Help with JSF login menu in JavaWeb

Talk, people, beauty? Hi, I am trying to create a Java project with Hibernate, TDD, MVC, JSF, Primefaces and more that I can not remember. Next, when I log in to my project I make the menu appear but when I click on a function, it disappears. Th...
asked by 26.09.2016 / 20:28
1
answer

DataTable with RowExpansion Editable not from Update - PrimeFaces

I have a DataTable that expands the line to an editable%, in the expansion it is possible to add items, by the "+ Item" button, everything is working correctly, but I can not update the table, added an item, it is already available for ed...
asked by 26.09.2016 / 14:31
1
answer

What is java.util.ConcurrentModificationException? [duplicate]

What causes this exception? How can we prevent this exception? How to fix it? Example: I have an ArrayList where I keep several movies in a table (Jtable) where I remove the movies so I do not have them and I have a method to remove a mo...
asked by 21.09.2016 / 17:16
2
answers

Java File Write Difference

I would like to know the difference in these two methods of writing to files. Path path = Paths.get("E:/documentos/texte.txt"); Charset utf8 = StandardCharsets.UTF_8; try(BufferedWriter escrever = Files.newBufferedWriter(path, utf8)) { e...
asked by 21.11.2016 / 19:03
2
answers

How should the communication between Model and View using MVC be?

I'm trying to implement some small projects using the MVC standard: Within the project framework, I've created the following packages: View: User interaction screens. Controller: I have a class with methods related to user requests, save,...
asked by 23.11.2016 / 03:09
1
answer

Error with HtmlUnit / WebClient / WildFly10

I'm trying to use htmlunit but it's happening: *** Environment / Server: WildFly10 When you run the following command: WebClient webClient = new WebClient(BrowserVersion.FIREFOX_45); The error happens: 17:34:19,139 WA...
asked by 03.10.2016 / 22:48
1
answer

Capture webcam image and save every 1 second?

I'm doing a project where the default webcam takes photos every 1 second using opencv. In my code, to the click of the capture button you select the folder where you want and it captures a photo. I need to loop him so he can capture photos and s...
asked by 05.10.2016 / 13:51
1
answer

Passing parameter in Bundle

My application uses internationalization of messages, etc. I would like to know how to pass parameters when passing a key that will fetch a value from the .properties file. Ex: My crud screens will always display a success message when a new...
asked by 04.10.2016 / 23:38
1
answer

Creating music player application with JLayer

I'm trying to create a Java application that receives a song through JFileChooser and adds that song to a list ( ArrayList<File> ). But when you access the array.getindex(0).getPath() file, the system drops NullPo...
asked by 11.11.2016 / 20:49