Win a copy of Head First Android this week in the Android forum!

Fintan Conway

Ranch Hand
+ Follow
since Apr 03, 2002
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Fintan Conway

OpenJPA command line enhancer

gives the following error:

It seems to find my class name from persistence.xml.

I have tried running the command from the directory where the java file resides (hence the dot in the classpath) and from the package root, but it refuses to find my class

What am I missing here?

Many thanks,

Fintan
Hi,

I have tried using ordinary Tomcat server with JSF 2.3 (I am using Eclipse).  Unfortunately, I am having as much problems getting JSF to work on Eclipse with Tomcat.  I have tried to get CDI working in Eclipse but to avall.  I have tried the options set out in this link Installing CDI in Tomcat, but cannot get CDI working.

If I stick to using TomEE and openJPA I am getting the following exception:

javax.el.ELException: <openjpa-3.1.2-r66d2a72 fatal user error> org.apache.openjpa.persistence.ArgumentException: No metadata was found for type "class com.waycontech.jsf.add.persistence.Student$$OwbNormalScopeProxy0". The class does not appear in the list of persistent types: [com.waycontech.jsf.add.persistence.Student].



It seems there is an inner class added to my Entity class which openJPA tries to persist instead of the class itself???

If I try to use Tomcat, I am having a problem using JSF.
If I try to use TomEE, I am having a problem with openJPA.

Any help would be appreciated,

Fintan
7 months ago
Hello,

I have a simple JSF 2.3 application and I am trying to use JPA to persist my data to the database.

I am using TomEE 8.0.6.

I am not using Spring.  I am not using EJB.

Unfortunately, I am getting a "Transaction required" exception when I try to persist data to the database



My configuration files
/src/META-INF/persistence.xml


/WebContent/WEB-INF/resources.xml


My Java files




My JSF page
/WebContent/addStudentForm.xhtml


When I call studentController.addStudent(student) the error gets thrown on the line entityManager.persist(student);

I know the DB connection is working because the following page calls studentController.loadStudents() and displays a list of the students.

/WebContent/addStudentList.xhtml


Any ideas on how to get the transactions working?

Many thanks
Hi,

I am a jQuery newbie, and am trying the example for popup from the site JQuery demo popup.

Here is my complete code :


but the popup text appears on the page, and nothing happens when I click on the link.

Am I missing a css file or a javascript file? Is there something even more basic that I am missing?

I am not even sure that I need the jquery-ui.css file.

Thanks for your help,

Fintan

Stefan Evans wrote:
Ok... fine...: go look at include directive vs include tag


Thanks for this.

Where does the RequestDispatcher fit into this scenario?

Can it be replaced by <@ include "header.jsp">? or by <jsp:include "header.jsp" />?

Or is it a different beast altogether?

Thanks again,

Fintan
10 years ago
JSP
Hi,

Simple question (hopefully). Is there a difference between using the include directive and RequestDispatcher.include().

E.g.

vs


Thanks
10 years ago
JSP

Christophe Verré wrote:This is not a JSP problem that you have here, but an Eclipse problem. Make sure your web application is configured to use your class files. I'm moving your thread to the Eclipse forum.



Hi,

How do I do the above?

Many thanks
I have been to https://jstl.dev.java.net/ to try and download the JSTL library. It redirects to http://java.net/projects/jstl/ which does not allow me to download the JSTL library.

Is there anywhere that I can download the JSTL library. Oracle site seems to be one big circle jerk when looking to download.

Many thanks
10 years ago
JSP

John de Michele wrote:Fintan:

Have you googled 'JMF javadoc'? I found information right away.

John.


Hi John,

I have tried this. Unfortunately there is no information on how to programmatically play an MP3 file, using either JMF or the MP3 plugin. I could find no javadocs for the mp3 plugin.

Could you post links to where you found sample code / javadocs for coding to play MP3 files please?

Many thanks,

Fintan
11 years ago

Wouter Oet wrote:Have you tried the JMF MP3 plugin?


Hi Wouter,

I have downloaded this and installed it. However I cannot find any documentation on how to use it within my code. Do you have any links/suggestions on how to code using this mp3plugin.jar?

Many thanks
11 years ago
Hi all,

I have an application that plays an MP3 song.

I have package the app into a jar, and included the MP3 song in the jar.

I would like the jarred app to pick up the MP3 song from the jar and play it from there, rather than having to include the MP3 file separately with the application. Is this possible?

I have found lots of ways to play "sampled audio" songs (wav, etc.) like this, but I cannot get it to work with an MP3 file.

I have also tried the following using the Java Media Framework (JMF), i.e. javax.media.* packages.


Any help would be greatly appreciated
11 years ago
Hi Peter,

Would you say that the practices in your book would make a programmer / programming team more Agile?

How would these practices fit into an RUP development methodology?

Is Code Craft something entirely different from these "S/W development methodologies"?

Thanks,

Fintan
Hi Guys,

Do you have a short and snappy way to explain/sell Agile Development to management in ~30 seconds. I was caught off-guard with this question once and did the usual techie thing of explaining some of the ways of doing Agile development rather than focussing on benefits that would ease this guys problems. I would like to have a ready reply if this situation ever arises again.

Thanks,

Fintan

PS I think this may have been answered here before, but when I looked for it there were only 4 topics in "Agile & other processes", so apologies if I am repeating an already answered question :roll:

Originally posted by Frank Carver:
test class 1:


Hi,

I do not want to be picky Frank - just to point out something which relates to the original question. In the code above before each test is run the setUp() method adds records for 1 and 2. Therefore when testAddNew() is run, 1 and 2 exist, the test adds 3 and does its stuff. tearDown() then deletes everything (1 and 2 added by setUp() and 3 added by testAddNew()).

Before testAddDuplicate() runs, setUp() is run again and adds 1 and 2. Then testAddDuplicate() adds 3 once. IMHO in order to test whether duplicates are added you should have an extra line for add(3);. Then if duplicates are not allowed the assertEquals(3, whatever.count()) will validate that only three records were added when you attempted to add 4.

Hope this helps the original poster,

Fintan
15 years ago

Originally posted by Jeanne Boyarsky:

The single method called getInputData is supposed to take a Struts ActionForm as input and return a business object representing the selection.
So I named it public void test_getInputData. I realize there isn't any information here. So I tried to think of a good name like the examples above. Everything I came up with is a synonym of the method name though.


Hi Jeanne,

I would be inclined to go for something like :
getStrutsInputData_ValidData
getStrutsInputData_DefaultData
getStrutsInputData_EmptyData
getStrutsInputData_NoObjectForData
etc.

Regards,

Fintan
15 years ago