Louis Moloney

Ranch Hand
+ Follow
since Feb 06, 2007
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 Louis Moloney

you can use non-static variables in a static method.

but if you are calling member variables or methods from within a static method they MUST be static.

e.g.
in main you call getStr() , this will not work because the method is not static. make getStr static and it will work.
i dont think that this is true.

I have looked at my exam voucher and it states a specific exam (see cut and paste below):

Product ID: GB-CX-310-081

I think there is a lot of confusion about this.
can anyone give a definative answer to this.
is that correct ? can i sit any exam with my voucher ?
i have 2 qs about scwcd:

1. if you have a scwcd 1.4 voucher can you sit the scwcd 1.5 exam ?

2. i have prepared for the 1.4 exam, is this enough to pass 1.5 exam with a good mark ?
tag scope , once tag is closed its not available anymore
I think your alittle confused between session cookies and persistent cookies.

when you add a cookie to a response this will persist between opening and closing of the browser.

when you close a browser its session cookies (not cookies) will disappear from the browser. But the session will be alive on the web server as to such time as it times out.
I wanted to see if I had 2 webapps
/app1
/app2

both of which have a Servlet (MyServlet.class) in webapp/WEB-INF/classes that was compiled from the same source code (MyServlet.java).

I am using boths apps (eg app1/getMyServlet , app2/getMyServlet).
What i wanted to know is does the container instantiate 2 instances of MyServlet or 1 ?

and if 2 made are they serviced by the correct instance for the webapp.
Christophe Verre and Promod Mahajan have understood this best

ps

Srinivasan I replied this morning 1st thing when i saw the posts
[ August 14, 2007: Message edited by: Louis Moloney ]
hi guys i have a query

if i have 2 separate web apps , mapped to 2 separate urls eg

lousite.com/appone

lousite.com/apptwo

and both of these call the same Servlet class when hit (except the servlet exists in each webapp/WEB_INF/classes dir).

How many servlets are loaded in the container?

is the servlet loaded twice once from each webapp? and does the correct servlet service the correct web app then?

[ August 13, 2007: Message edited by: Louis Moloney ]

[ August 13, 2007: Message edited by: Louis Moloney ]
[ August 13, 2007: Message edited by: Louis Moloney ]
you need to tell the page about the tag lib

stick somthing like this at top of page

<%@ taglib uri="http://java.sun.com/jstl/core" prefix="c" %>
m1 threw an exception but m1 also caught the exception. Therefore no exception was returned to main.

when you see a method that says throws Exception it means that method may or may not throw an Exception.
byte will never box to Integer as the Number subclasses are peers
ie Integer does not subclass Byte
eg

[ July 06, 2007: Message edited by: Louis Moloney ]
thanks for the input guys.

i think im gonna get the agile one and the david black one. work is paying after all
14 years ago
hi

Currently at work I use java/struts but its been decided to have a look at ruby on rails , with a view to doing a small web based project in it.

can anyone recommend a good book to learn from? i need a book that will be web orientated , as thats the dev domain it will be used for.
14 years ago
Collections in java 1.5 are type safe.

you are using stuff like this:
List list = new List();

which anything can be put in

now you can do stuff like List<String> list = new ArrayList<String>();
which will allow you to add Strings and only strings.

the warnings you are getting is java telling you that you are using the
old way which is not type safe.
hey guys,

i noticed some of you are under the impression that you can't add to a type collection when using ? wildcard. you can if using super but not extends.

you cannot add to this: List<? extends Number>

you CAN add to this: List<? super Number>