Questions tagged as 'java'

2
answers

Playing AudioClip with .wav in another JAVA package

I use this code to play sounds in my application, but it only plays audio if it is in the project folder, not inside a package. And if I export my project by creating a .jar it does not include the media files. I've tried changing the path by ad...
asked by 01.03.2017 / 21:30
1
answer

How to pass to the function which imageview was selected and save in Firebase

I have a User Registration Activity where it must fill in some fields (name, gender, age, etc.) and two ImageView where the user can put pictures of him by clicking ImageView and selecting them in the gallery. I have the method selectedPhoto...
asked by 29.08.2017 / 14:05
1
answer

Select count Java

I want to make a select with the count function and bring all the records of a table, but when displaying the amount in the textfield, it displays a different result. I'll put the code for you to analyze: Error Displayed MycodepublicvoidT...
asked by 15.04.2017 / 03:46
1
answer

@OneToMany Bidirectional

Good afternoon, folks. I'm developing a financial web application and I'm having trouble making the relationship between Lancamento and ItemLancamento . I'll post what I've done so far, this is giving error when adding item. CLAS...
asked by 14.04.2017 / 22:31
1
answer

list to store objects [closed]

Well, I'm creating a manufacturer list and I have a question regarding which collection to use. I want to add multiple manufacturers to my list, in case I use the ArrayList of the LIST interface? or something in the SET interface that does no...
asked by 15.03.2017 / 14:17
1
answer

load value in empty front form without starting with 0 [java] Thymeleaf + spring

My entity is integer and loads the front with value 0, I think it is a simple thing but I do not understand much.     
asked by 15.03.2017 / 13:01
1
answer

View PDF JSF primeFaces

Personal I'm creating a pdf file so it's beauty. Now I would like to display this PDF in a formulário.Xhtml Here is the code I use to create the pdf if someone can help me: CreatePdfBean class package br.com.view; import java.io...
asked by 16.03.2017 / 15:45
1
answer

How to write to an .json file

I have some files .json in assets . I'mcurrentlyjustreadingthesefiles.ReadingpublicStringloadJSONFromAsset(StringAjson){Stringjson=null;try{InputStreamis=context.getAssets().open(Ajson);intsize=is.available();byte[]buffer=newbyt...
asked by 19.02.2017 / 06:26
1
answer

Error while displaying a list with an ArrayAdapter

I can not get this list displayed. I'm using a Custon ArrayAdapter, but it's not rolling. Thanks. Debugging, it says "Frame not availeble". Could someone give me a light? public class MainActivity extends AppCompatActivity { @Override protec...
asked by 18.02.2017 / 20:54
1
answer

JPA-HIBERNATE: I understand the conjunctures and disjunctions? That's right?

I took some JPA handouts and read some tutorials on the internet, but I'm still a bit lost with regard to disjunction and conjunction in JPA. From what I understand the conjunction serves to group conditions with the "AND" of the sql, since t...
asked by 19.02.2017 / 23:02