Simple its not within a static context. Its most probably a has-a instance variable or in a instance method. The important thing here is you can get a list<dog>.get(0) means a dog object at index 0 from the list and then assign it to dog d.
[ SCJP 6.0 - 90% ] , JSP, Servlets and Learning EJB.
Try out the programs using a TextEditor. Textpad - Java 6 api