[JBoss-user] How to read a file as a Resource
What i am tryin to do is to read a XML file that is in the CLASSPATH. I have a XML file in my classpath and I need to read it. That is a resources for me. This file has some information that i need. The code is: Object o = new Object(); System.out.println(O is: + o); Class c = o.getClass(); System.out.println(Class is: + c); InputStream in = c.getResourceAsStream(resource); System.out.println(Resource is: + in); And the in is null. But i am sure that it is in the classpath. Becouse i have some classes in the same directory and it can be read. __ Message sent with Misiva Visit us at http://www.pragma.com.co/misiva ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re:Re: [JBoss-user] How to use getResourceAsStream() from a EJB
What i am tryin to do is to read a XML file that is in the CLASSPATH. The XML file is what I call resource. This file has some information that i need. - Message: 6 From: Guy Rouillier [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Re: [JBoss-user] How to use getResourceAsStream() from a EJB Date: Fri, 11 May 2001 13:14:54 -0400 Reply-To: [EMAIL PROTECTED] Show us the definition of resource. - Original Message - From: Pedro E. G=F3mez [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, May 10, 2001 9:56 PM Subject: [JBoss-user] How to use getResourceAsStream() from a EJB I need to read a resource that i have in the classpath, The code is: Object o =3D new Object(); System.out.println(O es: + o); Class c =3D o.getClass(); System.out.println(Class es: + c); System.out.println(Resource is: + c.getResourceAsStream(resource)); But it does not work The resource is null. The output is: [CatalogoEJB] O es:java.lang.Object@7f94b1 [CatalogoEJB] Class es:class java.lang.Object [CatalogoEJB] Resource is:null __ Message sent with Misiva Visit us at www.pragma.com.co/misiva __ Message sent with Misiva Visit us at http://www.pragma.com.co/misiva ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] How to execute a JSP in a EJB
Hello! I am developing an application which has to send an email to some users. The email is in HTML format, but what I have to do is to create the mail using some information from a Data Base and a HTML template. The administrator can change the template every day. What I want to do is to have a JSP page, and then, execute that page and send it to the users Can I execute a JSP and put the code in a String for sending it to the users? Thanks. __ Message sent with Misiva Visit us at http://www.pragma.com.co/misiva ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] JBoss Vs Jonas and Enhydra
Hello Some one can tell me what are the diferences between those products and why JBoss is better? Thanks. __ Message sent with Misiva Visit us at http://www.pragma.com.co/misiva ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] How to use getResourceAsStream() from a EJB
I need to read a resource that i have in the classpath, The code is: Object o = new Object(); System.out.println(O es: + o); Class c = o.getClass(); System.out.println(Class es: + c); System.out.println(Resource is: + c.getResourceAsStream(resource)); But it does not work The resource is null. The output is: [CatalogoEJB] O es:java.lang.Object@7f94b1 [CatalogoEJB] Class es:class java.lang.Object [CatalogoEJB] Resource is:null __ Message sent with Misiva Visit us at http://www.pragma.com.co/misiva ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user